Package org.codehaus.janino
Class Java.Atom
- java.lang.Object
-
- org.codehaus.janino.Java.Located
-
- org.codehaus.janino.Java.Atom
-
- All Implemented Interfaces:
Java.Locatable
- Direct Known Subclasses:
Java.ConstructorInvocation
,Java.Package
,Java.Rvalue
,Java.Type
- Enclosing class:
- Java
public abstract static class Java.Atom extends Java.Located
-
-
Field Summary
-
Fields inherited from class org.codehaus.janino.Java.Located
NOWHERE
-
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract void
accept(Visitor.AtomVisitor visitor)
Java.Lvalue
toLvalue()
Java.Lvalue
toLvalueOrCompileException()
Java.Rvalue
toRvalue()
Java.Rvalue
toRvalueOrCompileException()
abstract String
toString()
Java.Type
toType()
Java.Type
toTypeOrCompileException()
-
Methods inherited from class org.codehaus.janino.Java.Located
getLocation, throwCompileException
-
-
-
-
Constructor Detail
-
Atom
public Atom(Location location)
-
-
Method Detail
-
toType
public Java.Type toType()
- Returns:
- This atom, converted to
Java.Type
, ornull
if this atom is not a type
-
toRvalue
public Java.Rvalue toRvalue()
- Returns:
- This atom, converted to
Java.Rvalue
, ornull
if this atom is not an rvalue
-
toLvalue
public Java.Lvalue toLvalue()
- Returns:
- This atom, converted to
Java.Lvalue
, ornull
if this atom is not an lvalue
-
toTypeOrCompileException
public final Java.Type toTypeOrCompileException() throws CompileException
- Returns:
- This atom, converted to
Java.Type
- Throws:
CompileException
- This atom is not aJava.Type
-
toRvalueOrCompileException
public final Java.Rvalue toRvalueOrCompileException() throws CompileException
- Returns:
- This atom, converted to an
Java.Rvalue
- Throws:
CompileException
- This atom is not anJava.Rvalue
-
toLvalueOrCompileException
public final Java.Lvalue toLvalueOrCompileException() throws CompileException
- Returns:
- This atom, converted to an
Java.Lvalue
- Throws:
CompileException
- This atom is not aJava.Lvalue
-
accept
public abstract void accept(Visitor.AtomVisitor visitor)
-
-