|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sourceforge.cruisecontrol.Log
Handles the Log element, and subelements, of the CruiseControl configuration file. Also represents the Build Log used by the CruiseControl build process.
Field Summary | |
static int |
BEFORE_LENGTH
|
Constructor Summary | |
Log()
Log instances created this way must have their projectName set. |
Method Summary | |
void |
add(BuildLogger logger)
Adds a BuildLogger that will be called to manipulate the project log just prior to writing the log. |
void |
add(Manipulator manipulator)
Adds a Manipulator that will handle old log-files |
void |
addContent(org.jdom.Content newContent)
|
protected void |
callManipulators()
Calls all Manipulators to already existing logfiles. |
static java.lang.String |
formatLogFileName(java.util.Date date)
|
static java.lang.String |
formatLogFileName(java.util.Date date,
java.lang.String label)
|
org.jdom.Element |
getContent()
|
java.lang.String |
getLogDir()
|
BuildLogger[] |
getLoggers()
|
java.lang.String |
getLogXmlEncoding()
|
java.lang.String |
getProjectName()
|
static java.util.Date |
parseDateFromLogFileName(java.lang.String filename)
|
static java.lang.String |
parseLabelFromLogFileName(java.lang.String filename)
|
void |
reset()
Resets the build log. |
void |
setDir(java.lang.String logDir)
|
void |
setEncoding(java.lang.String logXmlEncoding)
|
void |
setLogDir(java.lang.String logDir)
Deprecated. use setDir(String) |
void |
setLogXmlEncoding(java.lang.String logXmlEncoding)
Deprecated. use setEncoding(String) |
void |
validate()
Validate the log. |
boolean |
wasBuildSuccessful()
|
static boolean |
wasSuccessfulBuild(java.lang.String filename)
|
void |
writeLogFile(java.util.Date now)
Writes the current build log to the appropriate directory and filename. |
protected void |
writeLogFile(java.io.File file,
org.jdom.Element element)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int BEFORE_LENGTH
Constructor Detail |
public Log()
Method Detail |
public void validate() throws CruiseControlException
java.lang.IllegalStateException
- if projectName wasn't set
CruiseControlException
public void add(BuildLogger logger)
public void add(Manipulator manipulator)
public BuildLogger[] getLoggers()
public java.lang.String getLogXmlEncoding()
public java.lang.String getProjectName()
public void setLogDir(java.lang.String logDir) throws CruiseControlException
setDir(String)
logDir
-
CruiseControlException
public void setDir(java.lang.String logDir) throws CruiseControlException
CruiseControlException
public void setLogXmlEncoding(java.lang.String logXmlEncoding)
setEncoding(String)
logXmlEncoding
- public void setEncoding(java.lang.String logXmlEncoding)
public java.lang.String getLogDir()
public void writeLogFile(java.util.Date now) throws CruiseControlException
CruiseControlException
protected void writeLogFile(java.io.File file, org.jdom.Element element) throws CruiseControlException
CruiseControlException
protected void callManipulators()
public static java.lang.String formatLogFileName(java.util.Date date)
public static java.lang.String formatLogFileName(java.util.Date date, java.lang.String label)
public void addContent(org.jdom.Content newContent)
public org.jdom.Element getContent()
public boolean wasBuildSuccessful()
public void reset()
public static boolean wasSuccessfulBuild(java.lang.String filename)
public static java.util.Date parseDateFromLogFileName(java.lang.String filename) throws java.text.ParseException
java.text.ParseException
public static java.lang.String parseLabelFromLogFileName(java.lang.String filename)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |