|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.aspectj.tools.ajc.CompilationResult
Utility class that makes the results of a compiler run available.
Instances of this class are returned by the Ajc.compile() and doIncrementalCompile() methods (and the AjcTestCase.ajc() wrapper).
This class provides a useful toString() method that is very helpful when debugging or creating messages for assert statements.
Note that the stdOut and stdErr captured from the compiler run do not contain any rendered messages - these are in the messages lists instead. Therefore for many compiler runs, they will be empty.
Constructor Summary | |
protected |
CompilationResult(java.lang.String[] args,
java.lang.String stdOut,
java.lang.String stdErr,
java.util.List infoMessages,
java.util.List errorMessages,
java.util.List warningMessages,
java.util.List failMessages)
Build a compilation result - called by the Ajc.compile and Ajc.doIncrementalCompile methods. |
Method Summary | |
java.lang.String[] |
getArgs()
The arguments that were passed to the compiler. |
java.util.List |
getErrorMessages()
The error messages produced by the compiler. |
java.util.List |
getFailMessages()
The fail or abort messages produced by the compiler. |
java.util.List |
getInfoMessages()
The informational messages produced by the compiler. |
java.lang.String |
getStandardError()
The standard error written by the compiler, excluding any messages. |
java.lang.String |
getStandardOutput()
The standard output written by the compiler, excluding any messages. |
java.util.List |
getWarningMessages()
The warning messages produced by the compiler. |
boolean |
hasErrorMessages()
True if the compiler issued one or more error messages. |
boolean |
hasFailMessages()
True if the compiler issued one or more fail or abort messages. |
boolean |
hasInfoMessages()
True if the compiler issued one or more informational messages. |
boolean |
hasMessages()
True if the compiler issued any messages of any kind. |
boolean |
hasWarningMessages()
True if the compiler issued one or more warning messages. |
java.lang.String |
toString()
Returns string containing message count summary, list of messages by type, and the actual ajc compilation command that was issued. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
protected CompilationResult(java.lang.String[] args, java.lang.String stdOut, java.lang.String stdErr, java.util.List infoMessages, java.util.List errorMessages, java.util.List warningMessages, java.util.List failMessages)
Method Detail |
public java.lang.String[] getArgs()
public java.lang.String getStandardOutput()
public java.lang.String getStandardError()
public boolean hasMessages()
public boolean hasInfoMessages()
public boolean hasErrorMessages()
public boolean hasWarningMessages()
public boolean hasFailMessages()
public java.util.List getInfoMessages()
IMessage
objects created during the
compile - so that you can programmatically test source locations
etc. etc.. It may often be easier to use the assertMessages
helper methods defined in the AjcTestCase class to test for messages
though.
AjcTestCase
public java.util.List getErrorMessages()
IMessage
objects created during the
compile - so that you can programmatically test source locations
etc. etc.. It may often be easier to use the assertMessages
helper methods defined in the AjcTestCase class to test for messages
though.
AjcTestCase
public java.util.List getWarningMessages()
IMessage
objects created during the
compile - so that you can programmatically test source locations
etc. etc.. It may often be easier to use the assertMessages
helper methods defined in the AjcTestCase class to test for messages
though.
AjcTestCase
public java.util.List getFailMessages()
IMessage
objects created during the
compile - so that you can programmatically test source locations
etc. etc.. It may often be easier to use the assertMessages
helper methods defined in the AjcTestCase class to test for messages
though.
AjcTestCase
public java.lang.String toString()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |