org.apache.sling.commons.compiler
Interface CompilationUnit

All Known Subinterfaces:
CompilationUnitWithSource

public interface CompilationUnit

This interface describes a compilation unit - usually a java class.

Since:
2.0

Method Summary
 long getLastModified()
          Return the last modified for the compilation unit.
 String getMainClassName()
          Returns the name of the top level public type.
 Reader getSource()
          Return an input stream for the contents.
 

Method Detail

getSource

Reader getSource()
                 throws IOException
Return an input stream for the contents. The compiler will close this stream in all cases!

Throws:
IOException

getMainClassName

String getMainClassName()
Returns the name of the top level public type. This name includes the package.

Returns:
the name of the top level public type.

getLastModified

long getLastModified()
Return the last modified for the compilation unit.

Returns:
The last modified information or -1 if the information can't be detected.


Copyright © 2011-2013 Adobe Systems Incorporated. All Rights Reserved.