org.tentackle.annotations
Class AnalyzeInfo.Parameter

java.lang.Object
  extended by org.tentackle.annotations.AnalyzeInfo.Parameter
Enclosing class:
AnalyzeInfo

public static class AnalyzeInfo.Parameter
extends Object

Abstraction of a method parameter.


Constructor Summary
AnalyzeInfo.Parameter(ProcessingEnvironment processingEnv, VariableElement var)
          Constructor used in apt run.
AnalyzeInfo.Parameter(String name, String type)
          Constructor for wurblets adding paramaters like "this".
AnalyzeInfo.Parameter(StringTokenizer stok)
          Constructor used when reading from infofile.
 
Method Summary
 Modifier[] getModifiers()
          Gets the modifiers
 String getModifiersAsString()
          Gets all modifiers as a single string.
 String getName()
          Gets the formal parameter name
 String getType()
          Gets the parameter type
 boolean isInstanceOfContextDb()
          Returns whether the parameter is an instance of a ContextDb.
 boolean isInstanceOfDb()
          Returns whether the parameter is an instance of a Db.
 boolean isInstanceOfDbObject()
          Returns whether the parameter is an instance of a DbObject.
 boolean isModifierSet(Modifier modifier)
          Checks if a given modifier is set.
 String toString()
          Returns a string representation of the object.
 void write(PrintWriter writer)
          Writes this parameter to the infofile.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AnalyzeInfo.Parameter

public AnalyzeInfo.Parameter(ProcessingEnvironment processingEnv,
                             VariableElement var)
Constructor used in apt run.

Parameters:
processingEnv - the annotations processor's environment
var - the variable element

AnalyzeInfo.Parameter

public AnalyzeInfo.Parameter(StringTokenizer stok)
Constructor used when reading from infofile.

Parameters:
stok - the string tokenizer (of the infofile)

AnalyzeInfo.Parameter

public AnalyzeInfo.Parameter(String name,
                             String type)
Constructor for wurblets adding paramaters like "this".

Parameters:
name - the formal parameter name
type - the parameter type
Method Detail

getName

public String getName()
Gets the formal parameter name

Returns:
the parameter name

getType

public String getType()
Gets the parameter type

Returns:
the parameter type

getModifiers

public Modifier[] getModifiers()
Gets the modifiers

Returns:
the array of modifiers

isInstanceOfDb

public boolean isInstanceOfDb()
Returns whether the parameter is an instance of a Db.

Returns:
true if instanceof Db

isInstanceOfContextDb

public boolean isInstanceOfContextDb()
Returns whether the parameter is an instance of a ContextDb.

Returns:
true if instanceof ContextDb

isInstanceOfDbObject

public boolean isInstanceOfDbObject()
Returns whether the parameter is an instance of a DbObject.

Returns:
true if instanceof DbObject

getModifiersAsString

public String getModifiersAsString()
Gets all modifiers as a single string.

Returns:
all modifiers as string

isModifierSet

public boolean isModifierSet(Modifier modifier)
Checks if a given modifier is set.

Parameters:
modifier - the modifier to test
Returns:
true modifier set

write

public void write(PrintWriter writer)
           throws IOException
Writes this parameter to the infofile.

Parameters:
writer - the writer bound to the infofile
Throws:
IOException

toString

public String toString()
Description copied from class: java.lang.Object
Returns a string representation of the object. In general, the toString method returns a string that "textually represents" this object. The result should be a concise but informative representation that is easy for a person to read. It is recommended that all subclasses override this method.

The toString method for class Object returns a string consisting of the name of the class of which the object is an instance, the at-sign character `@', and the unsigned hexadecimal representation of the hash code of the object. In other words, this method returns a string equal to the value of:

 getClass().getName() + '@' + Integer.toHexString(hashCode())
 

Overrides:
toString in class Object
Returns:
a string representation of the object.


Copyright © 2001-2008 Harald Krake, Bergstr. 48, 78098 Triberg, Germany, harald@krake.de