|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectentities.Expression
entities.Call
The Call class represents a function or method call statement
Field Summary |
Fields inherited from class entities.Expression |
fCast, fFile, fLBracketPosition, fOperator, fParentScope, fPosition, fPreviousExpression, fRBracketPosition, fToTrace, fTypeOfCast, SEPARATORS |
Constructor Summary | |
Call(ScopeManager parentScope)
|
Method Summary | |
void |
computeType(ScopeInfo scopeInfo,
java.lang.String indentation)
This method computes recursively the types on the parameter and field expressions. |
void |
fillName(java.lang.StringBuffer fullName,
java.lang.String previousType)
Compute the complete name to be associated to a SimpleVariable or to a Call expression. |
Expression |
getField()
|
Parameter |
getFormalParameter(int i)
|
java.util.Vector |
getFormalParameters()
|
Function |
getFunction()
|
Method |
getMethod()
|
java.lang.String |
getName()
|
Expression |
getParameter(int i)
|
java.util.Vector |
getParameters()
|
java.lang.String |
getScopedName()
|
java.lang.String |
getString()
|
java.lang.String |
getType()
For expressions that have a field corresponding to the type, it returns the type or null |
boolean |
isOnField()
|
void |
print(java.lang.String indentation)
Print all information contained in the Call expression |
java.lang.String |
resolveType()
|
void |
setField(Expression field)
The parameter "field" represents the expression found after "." or "->" |
void |
setName(java.lang.String name)
|
void |
setParameters(java.util.Vector parameters)
The parameter "parameters" is used to represent the actual parameters |
void |
setPreviousExpression(Expression expr)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Call(ScopeManager parentScope)
Method Detail |
public java.lang.String getName()
getName
in interface ScopeManager
getName
in class Expression
public java.util.Vector getParameters()
public Expression getParameter(int i)
public java.util.Vector getFormalParameters()
public Parameter getFormalParameter(int i)
public Method getMethod()
public Function getFunction()
public java.lang.String getType()
Expression
getType
in class Expression
public Expression getField()
Ex: a()->f(); a()->g; where function a() returns a pointer to A
On the Call object representing the function a() returns the Call and the SimpleVariable objects corresponding to the method f() and the field g respectively.
public java.lang.String getScopedName()
Ex: A a; a.f();
On the Call object representing the method f() returns the String "A::f"
public java.lang.String getString()
getString
in class Expression
public boolean isOnField()
Ex: class B {void g() {...}}; class A { B b; void f() {b.g()}};
On the Call object representing the method g() returns true because "b" is a field of the class A.
public void print(java.lang.String indentation)
print
in interface ScopeManager
print
in class Expression
public void fillName(java.lang.StringBuffer fullName, java.lang.String previousType)
fillName
in class Expression
public void setParameters(java.util.Vector parameters)
public void setField(Expression field)
Ex: a()->f(); a()->f; where function a() returns a pointer to A
In the first case "field" is the expression of type Call associated with the method f() and in the second the expression of type SimpleVariable associated with f
public void setPreviousExpression(Expression expr)
setPreviousExpression
in class Expression
expr
- represent the expression found before the "." or "->"Expression.fPreviousExpression
public void setName(java.lang.String name)
public java.lang.String resolveType()
resolveType
in class Expression
Ex: class A { public: int h(); }; A a; a.h; On the expression a.h() returns "int".
public void computeType(ScopeInfo scopeInfo, java.lang.String indentation)
computeType
in class Expression
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |