public final class CmsPublishJobInfoBean extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static int |
C_PUBLISH_FLAG
The flag used to indicate a direct publish job.
|
| Modifier | Constructor and Description |
|---|---|
protected |
CmsPublishJobInfoBean(CmsObject cms,
CmsPublishList publishList,
I_CmsReport report)
The Default constructor.
|
|
CmsPublishJobInfoBean(CmsUUID historyId,
CmsUUID projectId,
java.lang.String projectName,
CmsUUID userId,
java.lang.String localeName,
int flags,
int resourceCount,
long enqueueTime,
long startTime,
long finishTime)
Constructor used to initialize a job info bean from the database.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
enqueue()
Signalizes that the publish job has been enqueued.
|
protected void |
finish()
Signalizes the end of the publish job.
|
protected CmsObject |
getCmsObject()
Returns the cms object, will be set to
null after publishing. |
long |
getEnqueueTime()
Returns the time this object has been created.
|
long |
getFinishTime()
Returns the time the publish job ends.
|
int |
getFlags()
Returns the flags of this publish job.
|
java.util.Locale |
getLocale()
Returns the locale for this publish job.
|
CmsUUID |
getProjectId()
Returns the project id for this publish job.
|
java.lang.String |
getProjectName()
Returns the originally stored project name.
|
CmsUUID |
getPublishHistoryId()
Returns the publish history id.
|
CmsPublishList |
getPublishList()
Returns the list of resources to publish.
|
I_CmsReport |
getPublishReport()
Returns the report for this publish job.
|
I_CmsReport |
getReport()
Returns the report for this publish job.
|
int |
getSize()
Returns the number of resources in the publish list.
|
long |
getStartTime()
Returns the time the publish job did actually start.
|
CmsUUID |
getThreadUUID()
Returns the UUID of the running publish thread.
|
CmsUUID |
getUserId()
Returns the user for this publish job.
|
protected boolean |
isDirectPublish()
Returns
true if this is a "direct publish" operation. |
protected boolean |
isFinished()
Returns if the publish job is already finished.
|
protected boolean |
isStarted()
Returns if the publish job is already started.
|
I_CmsReport |
removePublishReport()
Removes the assigned publish report.
|
void |
revive(CmsObject adminCms,
CmsPublishList publishList)
Revives this publish job.
|
protected void |
start(CmsUUID threadUUID)
Signalizes the start of the publish job.
|
java.lang.String |
toString() |
public static final int C_PUBLISH_FLAG
public CmsPublishJobInfoBean(CmsUUID historyId, CmsUUID projectId, java.lang.String projectName, CmsUUID userId, java.lang.String localeName, int flags, int resourceCount, long enqueueTime, long startTime, long finishTime)
historyId - publish history idprojectId - the id of the projectprojectName - the name of the projectuserId - the id of the userlocaleName - the string representation of a localeflags - flags of the publish jobresourceCount - number of published resourcesenqueueTime - time when the job was enqueuedstartTime - time when the job was startedfinishTime - time when the job was finishedprotected CmsPublishJobInfoBean(CmsObject cms, CmsPublishList publishList, I_CmsReport report) throws CmsException
cms - the cms context to use for publishingpublishList - the list of resources to publishreport - the report to write toCmsException - if something goes wrongpublic long getEnqueueTime()
public long getFinishTime()
public int getFlags()
public java.util.Locale getLocale()
public CmsUUID getProjectId()
public java.lang.String getProjectName()
public CmsUUID getPublishHistoryId()
public CmsPublishList getPublishList()
public I_CmsReport getPublishReport()
This is not the original report, it is wrapper that also writes to a temporary file.
It will be null before starting and after finishing.
CmsPublishJobEnqueued.getReport()public I_CmsReport getReport()
public int getSize()
public long getStartTime()
public CmsUUID getThreadUUID()
public CmsUUID getUserId()
public I_CmsReport removePublishReport()
public void revive(CmsObject adminCms, CmsPublishList publishList) throws CmsException
adminCms - an admin cms objectpublishList - a publish listCmsException - if something goes wrongpublic java.lang.String toString()
toString in class java.lang.ObjectObject.toString()protected void enqueue()
Actually sets the enqueue time only if it is not set already (re-enqueue during startup).
protected void finish()
Actually only sets the finish time and closes the publish report stream.
protected CmsObject getCmsObject()
null after publishing.protected boolean isDirectPublish()
true if this is a "direct publish" operation.true if this is a "direct publish" operationprotected boolean isFinished()
true if the publish job is already finishedprotected boolean isStarted()
true if the publish job is already started