AstCreator

class AstCreator(filename: String, phpAst: PhpFile, global: Global) extends AstCreatorBase
Companion:
object
class AstCreatorBase
class Object
trait Matchable
class Any

Value members

Concrete methods

override def createAst(): DiffGraphBuilder
Definition Classes
AstCreatorBase

Inherited methods

def absolutePath(filename: String): String

Absolute path for the given file name

Absolute path for the given file name

Inherited from:
AstCreatorBase
def blockAst(blockNode: NewBlock, statements: List[Ast]): Ast

For a given block node and statement ASTs, create an AST that represents the block. The main purpose of this method is to increase the readability of the code which creates block asts.

For a given block node and statement ASTs, create an AST that represents the block. The main purpose of this method is to increase the readability of the code which creates block asts.

Inherited from:
AstCreatorBase
def callAst(callNode: NewCall, arguments: Seq[Ast], receiver: Option[Ast], withRecvArgEdge: Boolean): Ast

For a given call node, arguments, and optionally, a receiver, create an AST that represents the call site. The main purpose of this method is to automatically assign the correct argument indices.

For a given call node, arguments, and optionally, a receiver, create an AST that represents the call site. The main purpose of this method is to automatically assign the correct argument indices.

Inherited from:
AstCreatorBase
def controlStructureAst(controlStructureNode: NewControlStructure, condition: Option[Ast], children: List[Ast], placeConditionLast: Boolean): Ast

For a given node, condition AST and children ASTs, create an AST that represents the control structure. The main purpose of this method is to automatically assign the correct condition edges.

For a given node, condition AST and children ASTs, create an AST that represents the control structure. The main purpose of this method is to automatically assign the correct condition edges.

Inherited from:
AstCreatorBase
def forAst(forNode: NewControlStructure, locals: Seq[Ast], initAsts: Seq[Ast], conditionAsts: Seq[Ast], updateAsts: Seq[Ast], bodyAst: Ast): Ast
Inherited from:
AstCreatorBase
def globalNamespaceBlock(): NewNamespaceBlock

Create a global namespace block for the given filename

Create a global namespace block for the given filename

Inherited from:
AstCreatorBase
def methodAst(method: NewMethod, parameters: Seq[NewMethodParameterIn], body: Ast, methodReturn: NewMethodReturn, modifiers: Seq[NewModifier]): Ast

Creates an AST that represents an entire method, including its content.

Creates an AST that represents an entire method, including its content.

Inherited from:
AstCreatorBase
def methodAstWithAnnotations(method: NewMethod, parameters: Seq[Ast], body: Ast, methodReturn: NewMethodReturn, modifiers: Seq[NewModifier], annotations: Seq[Ast]): Ast

Creates an AST that represents an entire method, including its content and with support for both method and parameter annotations.

Creates an AST that represents an entire method, including its content and with support for both method and parameter annotations.

Inherited from:
AstCreatorBase
def methodReturnNode(tfn: String, dtfn: Option[String], line: Option[Integer], column: Option[Integer]): NewMethodReturn

Create a method return node

Create a method return node

Inherited from:
AstCreatorBase
def methodStubAst(method: NewMethod, parameters: Seq[NewMethodParameterIn], methodReturn: NewMethodReturn, modifiers: Seq[NewModifier]): Ast

Creates an AST that represents a method stub, containing information about the method, its parameters, and the return type.

Creates an AST that represents a method stub, containing information about the method, its parameters, and the return type.

Inherited from:
AstCreatorBase
def returnAst(returnNode: NewReturn, arguments: Seq[Ast]): Ast

For a given return node and arguments, create an AST that represents the return instruction. The main purpose of this method is to automatically assign the correct argument indices.

For a given return node and arguments, create an AST that represents the return instruction. The main purpose of this method is to automatically assign the correct argument indices.

Inherited from:
AstCreatorBase
def setArgumentIndices(arguments: Seq[Ast]): Unit
Inherited from:
AstCreatorBase
def staticInitMethodAst(initAsts: List[Ast], fullName: String, signature: Option[String], returnType: String): Ast
Inherited from:
AstCreatorBase
def withArgumentIndex[T <: ExpressionNew](node: T, argIdxOpt: Option[Int]): T
Inherited from:
AstCreatorBase
def withIndex[T, X](nodes: Array[T])(f: (T, Int) => X): Seq[X]
Inherited from:
AstCreatorBase
def withIndex[T, X](nodes: Seq[T])(f: (T, Int) => X): Seq[X]
Inherited from:
AstCreatorBase
def wrapMultipleInBlock(asts: Seq[Ast], lineNumber: Option[Integer]): Ast
Inherited from:
AstCreatorBase

Inherited fields

val diffGraph: DiffGraphBuilder
Inherited from:
AstCreatorBase