Class MemJavaFileObject

java.lang.Object
javax.tools.SimpleJavaFileObject
org.codehaus.groovy.tools.javac.MemJavaFileObject
All Implemented Interfaces:
javax.tools.FileObject, javax.tools.JavaFileObject

public class MemJavaFileObject
extends javax.tools.SimpleJavaFileObject
Represents a Java source file in memory to compile
Since:
3.0.0
  • Nested Class Summary

    Nested classes/interfaces inherited from interface javax.tools.JavaFileObject

    javax.tools.JavaFileObject.Kind
  • Field Summary

    Fields inherited from class javax.tools.SimpleJavaFileObject

    kind, uri
  • Constructor Summary

    Constructors
    Constructor Description
    MemJavaFileObject​(ClassNode classNode, java.lang.String src)
    Construct a MemJavaFileObject instance with given groovy class node and stub source code
  • Method Summary

    Modifier and Type Method Description
    boolean equals​(java.lang.Object o)  
    java.lang.CharSequence getCharContent​(boolean ignoreEncodingErrors)  
    int hashCode()  
    java.lang.String toString()  

    Methods inherited from class javax.tools.SimpleJavaFileObject

    delete, getAccessLevel, getKind, getLastModified, getName, getNestingKind, isNameCompatible, openInputStream, openOutputStream, openReader, openWriter, toUri

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • MemJavaFileObject

      public MemJavaFileObject​(ClassNode classNode, java.lang.String src)
      Construct a MemJavaFileObject instance with given groovy class node and stub source code
      Parameters:
      classNode - the groovy class node
      src - the stub source code
  • Method Details

    • getCharContent

      public java.lang.CharSequence getCharContent​(boolean ignoreEncodingErrors)
      Specified by:
      getCharContent in interface javax.tools.FileObject
      Overrides:
      getCharContent in class javax.tools.SimpleJavaFileObject
    • equals

      public boolean equals​(java.lang.Object o)
      Overrides:
      equals in class java.lang.Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class java.lang.Object
    • toString

      public java.lang.String toString()
      Overrides:
      toString in class javax.tools.SimpleJavaFileObject