|
Eclipse CDT Pre-release 3.0 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface INodeFactory
Factory for creating AST nodes. This interface contains factory methods
for nodes that are available for both C and C++.
Extending interfaces should use covariant return types where appropriate to
allow the construction of language-specific versions of certain nodes.
Most methods accept child nodes as parameters when constructing a new node.
For convenience it is always allowed to pass null for any of these parameters.
In this case the newly constructed node may be initialized using its
set() and add() methods instead.
Nodes created by this factory are not frozen, i.e. for any node created by this
factory the following holds node.isFrozen() == false .
None of the factory methods should return null.
| Method Detail |
|---|
IASTName newName()
IASTName newName(char[] name)
IASTTranslationUnit newTranslationUnit()
IASTLiteralExpression newLiteralExpression(int kind,
String rep)
IASTUnaryExpression newUnaryExpression(int operator,
IASTExpression operand)
IASTIdExpression newIdExpression(IASTName name)
IASTArraySubscriptExpression newArraySubscriptExpression(IASTExpression arrayExpr,
IASTExpression subscript)
IASTFunctionCallExpression newFunctionCallExpression(IASTExpression idExpr,
IASTExpression argList)
IASTExpressionList newExpressionList()
IASTCastExpression newCastExpression(int operator,
IASTTypeId typeId,
IASTExpression operand)
IASTBinaryExpression newBinaryExpression(int op,
IASTExpression expr1,
IASTExpression expr2)
IASTConditionalExpression newConditionalExpession(IASTExpression expr1,
IASTExpression expr2,
IASTExpression expr3)
IASTTypeIdInitializerExpression newTypeIdInitializerExpression(IASTTypeId typeId,
IASTInitializer initializer)
IASTLabelStatement newLabelStatement(IASTName name,
IASTStatement nestedStatement)
IASTCaseStatement newCaseStatement(IASTExpression expr)
IASTDefaultStatement newDefaultStatement()
IASTExpressionStatement newExpressionStatement(IASTExpression expression)
IASTNullStatement newNullStatement()
IASTCompoundStatement newCompoundStatement()
IASTSwitchStatement newSwitchStatement(IASTExpression controller,
IASTStatement body)
IASTIfStatement newIfStatement(IASTExpression condition,
IASTStatement then,
IASTStatement elseClause)
IASTWhileStatement newWhileStatement(IASTExpression condition,
IASTStatement body)
IASTDoStatement newDoStatement(IASTStatement body,
IASTExpression condition)
IASTForStatement newForStatement(IASTStatement init,
IASTExpression condition,
IASTExpression iterationExpression,
IASTStatement body)
IASTGotoStatement newGotoStatement(IASTName name)
IASTContinueStatement newContinueStatement()
IASTBreakStatement newBreakStatement()
IASTReturnStatement newReturnStatement(IASTExpression retValue)
IASTDeclarationStatement newDeclarationStatement(IASTDeclaration declaration)
IASTTypeIdExpression newTypeIdExpression(int operator,
IASTTypeId typeId)
IASTTypeId newTypeId(IASTDeclSpecifier declSpecifier,
IASTDeclarator declarator)
IASTDeclarator newDeclarator(IASTName name)
IASTSimpleDeclaration newSimpleDeclaration(IASTDeclSpecifier declSpecifier)
IASTInitializerExpression newInitializerExpression(IASTExpression expression)
IASTInitializerList newInitializerList()
IASTFunctionDefinition newFunctionDefinition(IASTDeclSpecifier declSpecifier,
IASTFunctionDeclarator declarator,
IASTStatement bodyStatement)
IASTStandardFunctionDeclarator newFunctionDeclarator(IASTName name)
IASTASMDeclaration newASMDeclaration(String assembly)
IASTProblemDeclaration newProblemDeclaration(IASTProblem problem)
IASTProblemStatement newProblemStatement(IASTProblem problem)
IASTProblemExpression newProblemExpression(IASTProblem problem)
IASTProblem newProblem(int id,
char[] arg,
boolean error)
IASTEnumerationSpecifier newEnumerationSpecifier(IASTName name)
IASTEnumerationSpecifier.IASTEnumerator newEnumerator(IASTName name,
IASTExpression value)
IASTElaboratedTypeSpecifier newElaboratedTypeSpecifier(int kind,
IASTName name)
IASTArrayModifier newArrayModifier(IASTExpression expr)
IASTArrayDeclarator newArrayDeclarator(IASTName name)
IASTParameterDeclaration newParameterDeclaration(IASTDeclSpecifier declSpec,
IASTDeclarator declarator)
IASTFieldDeclarator newFieldDeclarator(IASTName name,
IASTExpression bitFieldSize)
IASTSimpleDeclSpecifier newSimpleDeclSpecifier()
IGNUASTCompoundStatementExpression newGNUCompoundStatementExpression(IASTCompoundStatement compoundStatement)
IASTPointer newPointer()
IASTFieldReference newFieldReference(IASTName name,
IASTExpression owner)
IASTNamedTypeSpecifier newTypedefNameSpecifier(IASTName name)
IASTCompositeTypeSpecifier newCompositeTypeSpecifier(int key,
IASTName name)
|
Eclipse CDT Pre-release 3.0 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||