|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectibi.broker.api.data.dslog.DsLog
public class DsLog
When a scheduled report distribution job is run on the Distribution Server, the log of all activity relating to this process is encapsulated by way of theDsLog
andDsLogElement
classes. The DsLog class holds the general information pertaining to the log record of a job that is run by the Distribution Server. For each job, there is a correspondingDsLog
object. But for eachDsLog
object there can be any number of correspondingDsLogElement
objects. Please not that DsLog should be used only to retrieve data, because manually setting any log elements may interfere with the workings of the Distribution Server. The code snippet below shows the use of theDsLog
class. It is taken from the samples packaged with the product. + ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + Copyright (c) 2004 Information Builders, Inc. All Rights Reserved. + + + + Information Builders offers sample API programs as a heuristic device. + + They are not intended, as is, for production use. Licensed users are + + welcome to alter and extend these samples and deploy them in other + + environments, or alternate configurations, as they see fit. + + Information Builders will support the documented functionality of + + its API classes and methods. However, Information Builders is not + + responsible for functionality or behavior of products built with + + its API unless the documented behavior of its discrete classes and + + methods is different than the actual results. + + + + Redistributions of IBI source code and documentation must be within + + the scope of the Information Builders Software License Agreement. + + + + ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ . . // Retrieve log LogManager manager = casterConnection.getLogManager(); DsLog log = manager.getLogByJobId(jobId); // Print result System.out.println("JobId = " + log.getJobId()); System.out.println("ScheduleDescription = " + log.getScheduleDescription()); System.out.println("ScheduleId = " + log.getScheduleId()); System.out.println("Owner = " + log.getOwner()); System.out.println("StartTime = " + log.getStartTime().getTime().toLocaleString()); System.out.println("EndTime = " + log.getEndTime().getTime().toLocaleString()); System.out.println("ErrorType = " + log.getErrorType()); DsLogElement[] elementList = log.getLogElementList(); for(int i = 0; i < elementList.length; i++) { System.out.println("ExecId = " + elementList[i].getExecId() + " Message = " + elementList[i].getMessage() + " MessageCode = " + elementList[i].getMessageCode() + " TaskDescription = " + elementList[i].getTaskDescription()); } }
Field Summary | |
---|---|
static java.lang.String |
ERROR_FATAL
One of the three types of errors ( errorType ) produced during the
process of logging a scheduled report distribution run. |
static java.lang.String |
ERROR_NO
One of the three types of errors ( errorType ) produced during the
process of logging a scheduled report distribution run. |
static java.lang.String |
ERROR_WARNING
One of the three types of errors ( errorType ) produced during the
process of logging a scheduled report distribution run. |
Constructor Summary | |
---|---|
DsLog()
|
Method Summary | |
---|---|
java.util.Calendar |
getEndTime()
Obtains the Calendar time when the schedule job run ends. |
java.lang.String |
getErrorType()
Obtains a String constant indicating the type of error that may have occurred during the scheduled report distribution job run. |
java.lang.String |
getJobId()
Obtains a unique identifier to the log or record of the Distribution Server job. |
DsLogElement[] |
getLogElementList()
Obtains the Array of( DsLogElement[] )
objects that are associated with this instance of
the DsLog class. |
java.lang.String |
getOwner()
Obtains the username of the schedule owner. |
java.lang.String |
getScheduleDescription()
Obtains the text describing the Schedule that is being run and
logged on the Distribution Server. |
java.lang.String |
getScheduleId()
Obtains the unique identifier to the Schedule that is being run
and logged on the Distribution Server. |
java.util.Calendar |
getStartTime()
Obtains the Calendar time when the schedule job run begins. |
void |
setEndTime(java.util.Calendar endTime)
Assigns the Calendar time when the schedule job run ends. |
void |
setErrorType(java.lang.String error)
Assigns a String constant specifies the type of error that may have occurred during the scheduled report distribution job run. |
void |
setJobId(java.lang.String jobId)
The Distribution Server uses this method to assign a unique identifier to the log or record of a ReportCaster job. |
void |
setLogElementList(DsLogElement[] logElementList)
Assigns the Array of( DsLogElement[] )
objects that are associated with this instance of
the DsLog class. |
void |
setOwner(java.lang.String owner)
Assigns the username of the schedule owner. |
void |
setScheduleDescription(java.lang.String scheduleDescription)
Assigns the text describing the Schedule that is being run and
logged on the Distribution Server. |
void |
setScheduleId(java.lang.String scheduleId)
Assigns the unique identifier to the schedule that is being run and logged on the Distribution Server. |
void |
setStartTime(java.util.Calendar startTime)
Assigns the Calendar time when the schedule job run begins. |
void |
validate(java.lang.String parentName)
This method is used by the Distribution Server to validate certain field values before saving them to the repository, and should not be called under any circumstances by a ReportCaster API user. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String ERROR_WARNING
errorType
) produced during the
process of logging a scheduled report distribution run. This error type is used to
represent a warning error.
public static final java.lang.String ERROR_FATAL
errorType
) produced during the
process of logging a scheduled report distribution run. This error type is used to
represent a fatal error.
public static final java.lang.String ERROR_NO
errorType
) produced during the
process of logging a scheduled report distribution run. This error type is used to
represent that no error occurred.
Constructor Detail |
---|
public DsLog()
Method Detail |
---|
public void setJobId(java.lang.String jobId)
Job.getId()
). As with all
set methods in this class, it's use should be reserved to the Distribution Server.
jobId
- The unique identifier to the job.getJobId()
public java.lang.String getJobId()
Job.getId()
.
setJobId(java.lang.String)
public void setScheduleDescription(java.lang.String scheduleDescription)
Schedule
that is being run and
logged on the Distribution Server. This is the same descriptive String text that
is obtained by calling the Schedule.getDescription()
method. As with all
set methods in this class, it's use should be reserved to the Distribution Server.
scheduleDescription
- The description of the schedule
as a String.getScheduleDescription()
public java.lang.String getScheduleDescription()
Schedule
that is being run and
logged on the Distribution Server. This is the same descriptive String text that
is returned by calling the Schedule.getDescription()
method.
setScheduleDescription(java.lang.String)
public void setScheduleId(java.lang.String scheduleId)
Schedule.getId()
method. As with all
set methods in this class, it's use should be reserved to the Distribution Server.
scheduleId
- The unique schedule identifier.getScheduleId()
public java.lang.String getScheduleId()
Schedule
that is being run
and logged on the Distribution Server. This identifier is the same as that
returned by calling the Schedule.getId()
method.
setScheduleId(java.lang.String)
public void setOwner(java.lang.String owner)
owner
- The username of schedule owner.getOwner()
public java.lang.String getOwner()
setOwner(java.lang.String)
public void setStartTime(java.util.Calendar startTime)
GregorianCalander
. As with all
set methods in this class, it's use should be reserved to the Distribution Server.
startTime
- The time the job run for the schedule begins.getStartTime()
public java.util.Calendar getStartTime()
GregorianCalander
.
Calendar
object.public void setEndTime(java.util.Calendar endTime)
GregorianCalander
.
endTime
- The time the job run for the schedule ends.getEndTime()
public java.util.Calendar getEndTime()
GregorianCalander
.
Calendar
public void setErrorType(java.lang.String error)
error
- String constant error type.getErrorType()
public java.lang.String getErrorType()
setErrorType(java.lang.String)
public void setLogElementList(DsLogElement[] logElementList)
DsLogElement[]
)
objects that are associated with this instance of
the DsLog
class. As with all set methods in this class, it's used
should be reserved for the Distribution Server.
logElementList
- A reference to the log element array.getLogElementList()
public DsLogElement[] getLogElementList()
DsLogElement[]
)
objects that are associated with this instance of
the DsLog
class.
setLogElementList(ibi.broker.api.data.dslog.DsLogElement[])
public void validate(java.lang.String parentName) throws CasterException
parentName
- represented parent of this object.
CasterException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |