org.apache.sling.commons.compiler
Interface CompilationUnit


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.
 java.lang.String getMainClassName()
          Returns the name of the top level public type.
 java.io.Reader getSource()
          Return an input stream for the contents.
 

Method Detail

getSource

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

Throws:
java.io.IOException

getMainClassName

java.lang.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 © 2007-2012 The Apache Software Foundation. All Rights Reserved.