public class ClassifierName extends ClassifierExpression
Name
, but it extends ClassifierExpression
, helping keep the syntax of
classifier manipulation separate from Java's method definition syntax.Name
Modifier and Type | Field and Description |
---|---|
boolean |
isField
Is used to distinguish
Classifier s that are defined as fields. |
Name |
referent
(¬ø) The name as it appears in the source code.
|
argument, cacheIn, comment, name, parenthesized, returnType, singleExampleCache
byteOffset, line, nodeID, symbolTable
Constructor and Description |
---|
ClassifierName(Name n)
Full constructor.
|
ClassifierName(String n)
Takes a fully specified name (eg java.lang.String) as input.
|
ClassifierName(String n,
int line,
int byteOffset)
Takes a fully specified name (eg java.lang.String) as input.
|
Modifier and Type | Method and Description |
---|---|
Object |
clone()
Creates a new object with the same primitive data, and recursively creates new member data
objects as well.
|
boolean |
equals(Object o)
Indicates whether some other object is "equal to" this one.
|
int |
hashCode()
Returns a hash code value for java hash structures.
|
ASTNodeIterator |
iterator()
Returns an iterator used to successively access the children of this node.
|
void |
runPass(Pass pass)
Ensures that the correct
run() method is called for this type of node. |
StringBuffer |
shallow()
Creates a
StringBuffer containing a shallow representation of this
ClassifierExpression . |
void |
write(StringBuffer buffer)
Writes a string representation of this
ASTNode to the specified buffer. |
getLine, getName, setCacheIn
public Name referent
name
defined in ClassifierExpression
will be used by
SemanticAnalysis
for other purposes.SemanticAnalysis
,
ClassifierExpression.name
public boolean isField
Classifier
s that are defined as fields. Used during
TranslateToJava
.public ClassifierName(Name n)
n
- A name.public ClassifierName(String n)
n
- A fully specified name.public ClassifierName(String n, int line, int byteOffset)
n
- A fully specified name.public int hashCode()
public boolean equals(Object o)
public ASTNodeIterator iterator()
public Object clone()
public void runPass(Pass pass)
run()
method is called for this type of node.public void write(StringBuffer buffer)
ASTNode
to the specified buffer. The
representation written is parsable by the LBJava compiler, but not very readable.public StringBuffer shallow()
StringBuffer
containing a shallow representation of this
ClassifierExpression
.shallow
in interface CodeGenerator
shallow
in class ClassifierExpression
StringBuffer
containing a shallow text representation of the given
node.Copyright © 2016. All rights reserved.