org.jmodelica.modelica.compiler.AnnotationNode Class Reference

Describes a node in the tree formed by an annotation. More...

Inherited by org.jmodelica.modelica.compiler.AnnotationNode.AnnotationNode.CMAnnotationNode, org.jmodelica.modelica.compiler.AnnotationNode.AnnotationNode.ExpAnnotationNode, org.jmodelica.modelica.compiler.AnnotationNode.AnnotationNode.FCAnnotationNode, and org.jmodelica.modelica.compiler.AnnotationNode.AnnotationNode.NullAnnotationNode.

List of all members.

Classes

class  AnnotationIterator
 Iterates over the annotation nodes representing the nodes in the list.
class  CMAnnotationNode
 Represents an annotation that is represented in the source tree by a ClassModification.
class  EAnnotationNode
 Represents an annotation that is represented in the source tree by an Exp.
class  ExpAnnotationNode
class  FCAnnotationNode
 Represents an annotation that is represented in the source tree by a FunctionCall.
class  NAAnnotationNode
 Represents an annotation that is represented in the source tree by a NamedArgument.
class  NullAnnotationNode
 Represents a non-existing annotation.
class  VMAnnotationNode
 Represents an annotation that is represented in the source tree by a ValueModification.

Public Member Functions

AnnotationNode forPath (String path)
 Finds an annotation node at the given path below this one.
boolean isValue ()
 Check if this annotation node represents a value node.
boolean exists ()
 Checks if this annotation node represents an existing annotation.
String name ()
 Get the name associated with this annotation node, if any.
Iterator< AnnotationNodeiterator ()
 Iterate over this node's child annotation nodes.
String string ()
 Returns the value for a node that represents a string value.
String path ()
 Returns the value for a node that represents a string value, interpreted as a path of an URI (with protocol file or modelica).
ArrayList< String > stringList ()
 Returns the value for a node that represents a list of strings.
ArrayList< String > asStringList ()
 Returns the value for a node that represents a list of strings, or a single string value.
double real ()
 Returns the value for a node that represents a real value.
double[] realVector ()
 Returns the value for a node that represents a vector of real values.
double[][] realMatrix ()
 Returns the value for a node that represents a matrix of real values.
boolean bool ()
 Returns the value for a node that represents a boolean value.

Static Public Attributes

static final AnnotationNode NO_ANNOTATION = new NullAnnotationNode()
 Represents an annotation that does not exist.

Protected Member Functions

AnnotationNode forPath (String[] path, int i)
 Internal definition of forPath(String).
abstract ASTNode ast ()
 Returns the ast node that this annotation node is connected to.


Detailed Description

Describes a node in the tree formed by an annotation.

class :0


Member Function Documentation

ArrayList<String> org.jmodelica.modelica.compiler.AnnotationNode.asStringList (  ) 

Returns the value for a node that represents a list of strings, or a single string value.

abstract ASTNode org.jmodelica.modelica.compiler.AnnotationNode.ast (  )  [protected, pure virtual]

Returns the ast node that this annotation node is connected to.

boolean org.jmodelica.modelica.compiler.AnnotationNode.bool (  ) 

Returns the value for a node that represents a boolean value.

boolean org.jmodelica.modelica.compiler.AnnotationNode.exists (  ) 

Checks if this annotation node represents an existing annotation.

AnnotationNode org.jmodelica.modelica.compiler.AnnotationNode.forPath ( String[]  path,
int  i 
) [protected]

Internal definition of forPath(String).

Parameters:
path the path elements to find
i the first index in path to use

AnnotationNode org.jmodelica.modelica.compiler.AnnotationNode.forPath ( String  path  ) 

Finds an annotation node at the given path below this one.

boolean org.jmodelica.modelica.compiler.AnnotationNode.isValue (  ) 

Check if this annotation node represents a value node.

Iterator<AnnotationNode> org.jmodelica.modelica.compiler.AnnotationNode.iterator (  ) 

Iterate over this node's child annotation nodes.

String org.jmodelica.modelica.compiler.AnnotationNode.name (  ) 

Get the name associated with this annotation node, if any.

In general, any node reachable with a call to forPath() will have a name.

Returns:
the name or null, if no name is available

String org.jmodelica.modelica.compiler.AnnotationNode.path (  ) 

Returns the value for a node that represents a string value, interpreted as a path of an URI (with protocol file or modelica).

A simple path is also supported, and is interpreted relative to the top containing package, or if that does not exist, relative to the directory containing the current file.

double org.jmodelica.modelica.compiler.AnnotationNode.real (  ) 

Returns the value for a node that represents a real value.

double [][] org.jmodelica.modelica.compiler.AnnotationNode.realMatrix (  ) 

Returns the value for a node that represents a matrix of real values.

double [] org.jmodelica.modelica.compiler.AnnotationNode.realVector (  ) 

Returns the value for a node that represents a vector of real values.

String org.jmodelica.modelica.compiler.AnnotationNode.string (  ) 

Returns the value for a node that represents a string value.

ArrayList<String> org.jmodelica.modelica.compiler.AnnotationNode.stringList (  ) 

Returns the value for a node that represents a list of strings.


Member Data Documentation

Represents an annotation that does not exist.


The documentation for this class was generated from the following file:

Generated on Fri Oct 7 14:49:17 2011 for JModelica.org by  doxygen 1.5.8