|
||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.lang.Thread
org.opencms.report.A_CmsReportThread
public abstract class A_CmsReportThread
Provides a common Thread class for the reports.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class java.lang.Thread |
---|
java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler |
Field Summary |
---|
Fields inherited from class java.lang.Thread |
---|
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
Constructor Summary | |
---|---|
protected |
A_CmsReportThread(CmsObject cms,
java.lang.String name)
Constructs a new report Thread with the given name. |
Method Summary | |
---|---|
void |
addError(java.lang.Object obj)
Adds an error object to the list of errors that occurred during the report. |
protected CmsObject |
getCms()
Returns the OpenCms context object this Thread is initialized with. |
java.lang.Throwable |
getError()
Returns the error exception in case there was an error during the execution of this Thread, null otherwise. |
java.util.List |
getErrors()
Returns a list of all errors that occurred during the report. |
protected I_CmsReport |
getReport()
Returns the report where the output of this Thread is written to. |
abstract java.lang.String |
getReportUpdate()
Returns the part of the report that is ready for output. |
long |
getRuntime()
Returns the time this report has been running. |
CmsUUID |
getUUID()
Returns the OpenCms UUID of this report thread. |
boolean |
hasError()
Returns if the report generated an error output. |
protected void |
initHtmlReport(java.util.Locale locale)
Initialize a HTML report for this Thread. |
protected void |
initOldHtmlReport(java.util.Locale locale)
Initialize a HTML report for this Thread. |
boolean |
isDoomed()
Returns true if this thread is already "doomed" to be deleted. |
Methods inherited from class java.lang.Thread |
---|
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, run, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.opencms.report.I_CmsReportThread |
---|
start |
Constructor Detail |
---|
protected A_CmsReportThread(CmsObject cms, java.lang.String name)
cms
- the current OpenCms context objectname
- the name of the ThreadMethod Detail |
---|
public void addError(java.lang.Object obj)
obj
- the error objectpublic java.lang.Throwable getError()
public java.util.List getErrors()
public abstract java.lang.String getReportUpdate()
public long getRuntime()
public CmsUUID getUUID()
getUUID
in interface I_CmsReportThread
public boolean hasError()
public boolean isDoomed()
A OpenCms deamon Thread (the "Grim Reaper") will collect all doomed Threads, i.e. threads that are not longer active for some time.
protected CmsObject getCms()
protected I_CmsReport getReport()
protected void initHtmlReport(java.util.Locale locale)
locale
- the locale for the report output messagesprotected void initOldHtmlReport(java.util.Locale locale)
This method is reserved for older report threads that still use XML templates to generate their output.
locale
- the locale for the report output messages
|
||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |