Packages

class AstCreator extends AstCreatorBase with AstForTypesCreator with AstForFunctionsCreator with AstForPrimitivesCreator with AstForStatementsCreator with AstForExpressionsCreator with AstNodeBuilder with AstCreatorHelper with MacroHandler with x2cpg.AstNodeBuilder[IASTNode, AstCreator]

Translates the Eclipse CDT AST into a CPG AST.

Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. AstCreator
  2. AstNodeBuilder
  3. MacroHandler
  4. AstCreatorHelper
  5. AstNodeBuilder
  6. AstForExpressionsCreator
  7. AstForStatementsCreator
  8. AstForPrimitivesCreator
  9. AstForFunctionsCreator
  10. AstForTypesCreator
  11. AstCreatorBase
  12. AnyRef
  13. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new AstCreator(filename: String, config: Config, cdtAst: IASTTranslationUnit, file2OffsetTable: ConcurrentHashMap[String, Array[Int]])

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def absolutePath(filename: String): String
    Definition Classes
    AstCreatorBase
  5. def annotationAssignmentAst(assignmentValueName: String, code: String, assignmentAst: Ast): Ast
    Definition Classes
    AstCreatorBase
  6. def annotationAst(annotation: NewAnnotation, children: Seq[Ast]): Ast
    Definition Classes
    AstCreatorBase
  7. def annotationNode(node: IASTNode, code: String, name: String, fullName: String): NewAnnotation
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  8. def asChildOfMacroCall(node: IASTNode, ast: Ast): Ast

    For the given node, determine if it is expanded from a macro, and if so, create a Call node to represent the macro invocation and attach ast as its child.

    For the given node, determine if it is expanded from a macro, and if so, create a Call node to represent the macro invocation and attach ast as its child.

    Definition Classes
    MacroHandler
  9. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  10. def astForASMDeclaration(asm: IASTASMDeclaration): Ast
    Attributes
    protected
    Definition Classes
    AstForTypesCreator
  11. def astForAliasDeclaration(aliasDeclaration: ICPPASTAliasDeclaration): Ast
    Attributes
    protected
    Definition Classes
    AstForTypesCreator
  12. def astForArrayModifier(arrMod: IASTArrayModifier): Ast
    Attributes
    protected
    Definition Classes
    AstForPrimitivesCreator
  13. def astForBlockStatement(blockStmt: IASTCompoundStatement, order: Int = -1): Ast
    Attributes
    protected
    Definition Classes
    AstForStatementsCreator
  14. def astForComment(comment: IASTComment): Ast
    Attributes
    protected
    Definition Classes
    AstForPrimitivesCreator
  15. def astForDeclarator(declaration: IASTSimpleDeclaration, declarator: IASTDeclarator, index: Int): Ast
    Attributes
    protected
    Definition Classes
    AstForTypesCreator
  16. def astForExpression(expression: IASTExpression): Ast
    Attributes
    protected
    Definition Classes
    AstForExpressionsCreator
  17. def astForFieldReference(fieldRef: IASTFieldReference): Ast
    Attributes
    protected
    Definition Classes
    AstForPrimitivesCreator
  18. def astForFunctionDeclarator(funcDecl: IASTFunctionDeclarator): Ast
    Attributes
    protected
    Definition Classes
    AstForFunctionsCreator
  19. def astForFunctionDefinition(funcDef: IASTFunctionDefinition): Ast
    Attributes
    protected
    Definition Classes
    AstForFunctionsCreator
  20. def astForIdentifier(ident: IASTNode): Ast
    Attributes
    protected
    Definition Classes
    AstForPrimitivesCreator
  21. def astForInitializer(declarator: IASTDeclarator, init: IASTInitializer): Ast
    Attributes
    protected
    Definition Classes
    AstForTypesCreator
  22. def astForInitializerList(l: IASTInitializerList): Ast
    Attributes
    protected
    Definition Classes
    AstForPrimitivesCreator
  23. def astForLiteral(lit: IASTLiteralExpression): Ast
    Attributes
    protected
    Definition Classes
    AstForPrimitivesCreator
  24. def astForMethodRefForLambda(lambdaExpression: ICPPASTLambdaExpression): Ast
    Attributes
    protected
    Definition Classes
    AstForFunctionsCreator
  25. def astForNamespaceAlias(namespaceAlias: ICPPASTNamespaceAlias): Ast
    Attributes
    protected
    Definition Classes
    AstForTypesCreator
  26. def astForNode(node: IASTNode): Ast
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  27. def astForQualifiedName(qualId: CPPASTQualifiedName): Ast
    Attributes
    protected
    Definition Classes
    AstForPrimitivesCreator
  28. def astForStaticAssert(a: ICPPASTStaticAssertDeclaration): Ast
    Attributes
    protected
    Definition Classes
    AstForExpressionsCreator
  29. def astsForComments(iASTTranslationUnit: IASTTranslationUnit): Seq[Ast]
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  30. def astsForDeclaration(decl: IASTDeclaration): Seq[Ast]
    Attributes
    protected
    Definition Classes
    AstForTypesCreator
  31. def astsForStatement(statement: IASTStatement, argIndex: Int = -1): Seq[Ast]
    Attributes
    protected
    Definition Classes
    AstForStatementsCreator
  32. def attachDependenciesAndImports(iASTTranslationUnit: IASTTranslationUnit): Unit
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  33. def blockAst(blockNode: NewBlock, statements: List[Ast]): Ast
    Definition Classes
    AstCreatorBase
  34. def blockNode(node: IASTNode, code: String, typeFullName: String): NewBlock
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  35. def blockNode(node: IASTNode): NewBlock
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  36. def callAst(callNode: NewCall, arguments: Seq[Ast], base: Option[Ast], receiver: Option[Ast]): Ast
    Definition Classes
    AstCreatorBase
  37. def callNode(node: IASTNode, code: String, name: String, methodFullName: String, dispatchType: String, signature: Option[String], typeFullName: Option[String]): NewCall
    Definition Classes
    AstNodeBuilder
  38. def callNode(node: IASTNode, code: String, name: String, methodFullName: String, dispatchType: String): NewCall
    Definition Classes
    AstNodeBuilder
  39. val cdtAst: IASTTranslationUnit
  40. def cleanType(rawType: String, stripKeywords: Boolean = true): String
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  41. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  42. def column(node: IASTNode): Option[Integer]
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  43. def columnEnd(node: IASTNode): Option[Integer]
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  44. val config: Config
  45. def controlStructureAst(controlStructureNode: NewControlStructure, condition: Option[Ast], children: Seq[Ast], placeConditionLast: Boolean): Ast
    Definition Classes
    AstCreatorBase
  46. def controlStructureNode(node: IASTNode, controlStructureType: String, code: String): NewControlStructure
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  47. def createAst(): DiffGraphBuilder
    Definition Classes
    AstCreator → AstCreatorBase
  48. def dereferenceTypeFullName(fullName: String): String
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  49. val diffGraph: DiffGraphBuilder
    Definition Classes
    AstCreatorBase
  50. def doWhileAst(condition: Option[Ast], body: Seq[Ast], code: Option[String], lineNumber: Option[Integer], columnNumber: Option[Integer]): Ast
    Definition Classes
    AstCreatorBase
  51. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  52. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  53. def fieldIdentifierNode(node: IASTNode, name: String, code: String): NewFieldIdentifier
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  54. val file2OffsetTable: ConcurrentHashMap[String, Array[Int]]
  55. def fileName(node: IASTNode): String
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  56. val filename: String
  57. def fixQualifiedName(name: String): String
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  58. def forAst(forNode: NewControlStructure, locals: Seq[Ast], initAsts: Seq[Ast], conditionAsts: Seq[Ast], updateAsts: Seq[Ast], bodyAsts: Seq[Ast]): Ast
    Definition Classes
    AstCreatorBase
  59. def forAst(forNode: NewControlStructure, locals: Seq[Ast], initAsts: Seq[Ast], conditionAsts: Seq[Ast], updateAsts: Seq[Ast], bodyAst: Ast): Ast
    Definition Classes
    AstCreatorBase
  60. def fullName(node: IASTNode): String
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  61. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  62. def globalNamespaceBlock(): NewNamespaceBlock
    Definition Classes
    AstCreatorBase
  63. def handleUsingDeclaration(usingDecl: ICPPASTUsingDeclaration): Seq[Ast]
    Attributes
    protected
    Definition Classes
    AstForTypesCreator
  64. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  65. def identifierNode(node: IASTNode, name: String, code: String, typeFullName: String, dynamicTypeHints: Seq[String]): NewIdentifier
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  66. def isIncludedNode(node: IASTNode): Boolean
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  67. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  68. def isQualifiedName(name: String): Boolean
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  69. def lastNameOfQualifiedName(name: String): String
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  70. def line(node: IASTNode): Option[Integer]
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  71. def lineEnd(node: IASTNode): Option[Integer]
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  72. def literalNode(node: IASTNode, code: String, typeFullName: String, dynamicTypeHints: Seq[String]): NewLiteral
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  73. def localNode(node: IASTNode, name: String, code: String, typeFullName: String, closureBindingId: Option[String]): NewLocal
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  74. val logger: Logger
    Attributes
    protected
  75. def memberNode(node: IASTNode, name: String, code: String, typeFullName: String, dynamicTypeHints: Seq[String]): NewMember
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  76. def memberNode(node: IASTNode, name: String, code: String, typeFullName: String): NewMember
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  77. def methodAst(method: NewMethod, parameters: Seq[Ast], body: Ast, methodReturn: NewMethodReturn, modifiers: Seq[NewModifier]): Ast
    Definition Classes
    AstCreatorBase
  78. val methodAstParentStack: Stack[NewNode]
    Attributes
    protected
  79. def methodAstWithAnnotations(method: NewMethod, parameters: Seq[Ast], body: Ast, methodReturn: NewMethodReturn, modifiers: Seq[NewModifier], annotations: Seq[Ast]): Ast
    Definition Classes
    AstCreatorBase
  80. def methodNode(node: IASTNode, name: String, code: String, fullName: String, signature: Option[String], fileName: String, astParentType: Option[String], astParentFullName: Option[String]): NewMethod
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  81. def methodNode(node: IASTNode, name: String, fullName: String, signature: String, fileName: String): NewMethod
    Definition Classes
    AstNodeBuilder
  82. def methodRefNode(node: IASTNode, code: String, methodFullName: String, typeFullName: String): NewMethodRef
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  83. def methodStubAst(method: NewMethod, parameters: Seq[NewMethodParameterIn], methodReturn: NewMethodReturn, modifiers: Seq[NewModifier]): Ast
    Definition Classes
    AstCreatorBase
  84. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  85. def newCommentNode(node: IASTNode, code: String, filename: String): NewComment
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  86. def newImportNode(code: String, importedEntity: String, include: IASTPreprocessorIncludeStatement): NewImport
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  87. def newJumpTargetNode(node: IASTNode): NewJumpTarget
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  88. def newMethodReturnNode(node: IASTNode, typeFullName: String): NewMethodReturn
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  89. def newNamespaceBlockNode(node: IASTNode, name: String, fullname: String, code: String, filename: String): NewNamespaceBlock
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  90. def nodeSignature(node: IASTNode): String

    The CDT utility method is unfortunately in a class that is marked as deprecated, however, this is because the CDT team would like to discourage its use but at the same time does not plan to remove this code.

    The CDT utility method is unfortunately in a class that is marked as deprecated, however, this is because the CDT team would like to discourage its use but at the same time does not plan to remove this code.

    Definition Classes
    MacroHandler
    Annotations
    @nowarn()
  91. def notHandledYet(node: IASTNode): Ast
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  92. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  93. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  94. def nullSafeAst(node: IASTStatement, argIndex: Int = -1): Seq[Ast]
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  95. def nullSafeAst(node: IASTExpression): Ast
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  96. def nullSafeAst(node: IASTExpression, argIndex: Int): Ast
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  97. def nullSafeCode(node: IASTNode): String
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  98. def parameterInNode(node: IASTNode, name: String, code: String, index: Int, isVariadic: Boolean, evaluationStrategy: String, typeFullName: Option[String]): NewMethodParameterIn
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  99. def parameterInNode(node: IASTNode, name: String, code: String, index: Int, isVariadic: Boolean, evaluationStrategy: String, typeFullName: String): NewMethodParameterIn
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  100. def registerType(typeName: String): String
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  101. def returnAst(returnNode: NewReturn, arguments: Seq[Ast]): Ast
    Definition Classes
    AstCreatorBase
  102. def returnNode(node: IASTNode, code: String): NewReturn
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  103. val scope: Scope[String, (NewNode, String), NewNode]
    Attributes
    protected
  104. def setArgumentIndices(arguments: Seq[Ast]): Unit
    Definition Classes
    AstCreatorBase
  105. def shortName(node: IASTNode): String
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  106. def shortenCode(code: String, length: Int = MaxCodeLength): String
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  107. def staticInitMethodAst(initAsts: List[Ast], fullName: String, signature: Option[String], returnType: String, fileName: Option[String], lineNumber: Option[Integer], columnNumber: Option[Integer]): Ast
    Definition Classes
    AstCreatorBase
  108. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  109. def templateParameters(e: IASTNode): Option[String]
    Attributes
    protected
    Definition Classes
    AstForTypesCreator
  110. def toString(): String
    Definition Classes
    AnyRef → Any
  111. def tryCatchAst(tryNode: NewControlStructure, tryBodyAst: Ast, catchAsts: Seq[Ast], finallyAst: Option[Ast]): Ast
    Definition Classes
    AstCreatorBase
  112. def typeDeclNode(node: IASTNode, name: String, fullName: String, filename: String, code: String, astParentType: String, astParentFullName: String, inherits: Seq[String], alias: Option[String]): NewTypeDecl
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  113. def typeDeclNode(node: IASTNode, name: String, fullName: String, fileName: String, inheritsFrom: Seq[String], alias: Option[String]): NewTypeDecl
    Definition Classes
    AstNodeBuilder
  114. def typeFor(node: IASTNode, stripKeywords: Boolean = true): String
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
    Annotations
    @nowarn()
  115. def typeForDeclSpecifier(spec: IASTNode, stripKeywords: Boolean = true, index: Int = 0): String
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  116. def typeRefNode(node: IASTNode, code: String, typeFullName: String): NewTypeRef
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  117. def uniqueName(target: String, name: String, fullName: String): (String, String)
    Attributes
    protected
    Definition Classes
    AstCreatorHelper
  118. def unknownNode(node: IASTNode, code: String): NewUnknown
    Attributes
    protected
    Definition Classes
    AstNodeBuilder
  119. val usingDeclarationMappings: Map[String, String]
    Attributes
    protected
  120. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  121. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  122. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  123. def whileAst(condition: Option[Ast], body: Seq[Ast], code: Option[String], lineNumber: Option[Integer], columnNumber: Option[Integer]): Ast
    Definition Classes
    AstCreatorBase
  124. def withArgumentIndex[T <: ExpressionNew](node: T, argIdxOpt: Option[Int]): T
    Definition Classes
    AstCreatorBase
  125. def withArgumentName[T <: ExpressionNew](node: T, argNameOpt: Option[String]): T
    Definition Classes
    AstCreatorBase
  126. def withIndex[T, X](nodes: Array[T])(f: (T, Int) => X): Seq[X]
    Definition Classes
    AstCreatorBase
  127. def withIndex[T, X](nodes: Seq[T])(f: (T, Int) => X): Seq[X]
    Definition Classes
    AstCreatorBase
  128. def wrapMultipleInBlock(asts: Seq[Ast], lineNumber: Option[Integer]): Ast
    Definition Classes
    AstCreatorBase

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated
    Deprecated

Inherited from x2cpg.AstNodeBuilder[IASTNode, AstCreator]

Inherited from MacroHandler

Inherited from AstCreatorHelper

Inherited from AstNodeBuilder

Inherited from AstForFunctionsCreator

Inherited from AstForTypesCreator

Inherited from AstCreatorBase

Inherited from AnyRef

Inherited from Any

Ungrouped