final class Method extends AnyVal
A method, function, or procedure
- Annotations
- @Traversal()
- Alphabetic
- By Inheritance
- Method
- AnyVal
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new Method(traversal: Traversal[codepropertygraph.generated.nodes.Method])
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- Any
- final def ##: Int
- Definition Classes
- Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def bindingTypeDecl: Traversal[codepropertygraph.generated.nodes.TypeDecl]
Traverse to type decl which have this method bound to it.
- def block: Traversal[codepropertygraph.generated.nodes.Block]
Traverse to block
Traverse to block
- Annotations
- @Doc("Root of the abstract syntax tree", help.this.Doc.<init>$default$2, help.this.Doc.<init>$default$3)
- def body: Traversal[codepropertygraph.generated.nodes.Block]
Traverse to method body (alias for
block
)Traverse to method body (alias for
block
)- Annotations
- @Doc("Alias for `block`", help.this.Doc.<init>$default$2, help.this.Doc.<init>$default$3)
- def cfgFirst: Traversal[Expression]
Traverse to first expression in CFG.
Traverse to first expression in CFG.
- Annotations
- @Doc("First control flow graph node", help.this.Doc.<init>$default$2, help.this.Doc.<init>$default$3)
- def cfgLast: Traversal[Expression]
Traverse to last expression in CFG.
Traverse to last expression in CFG.
- Annotations
- @Doc("Last control flow graph node", help.this.Doc.<init>$default$2, help.this.Doc.<init>$default$3)
- def cfgNode: Traversal[CfgNode]
- Annotations
- @Doc("Control flow graph nodes", help.this.Doc.<init>$default$2, help.this.Doc.<init>$default$3)
- def controlStructure(regex: String): Traversal[ControlStructure]
Shorthand to traverse to control structures where condition matches
regex
- def controlStructure: Traversal[ControlStructure]
All control structures of this method
All control structures of this method
- Annotations
- @Doc("Control structures (source frontends only)", help.this.Doc.<init>$default$2, help.this.Doc.<init>$default$3)
- def definingMethod: Traversal[codepropertygraph.generated.nodes.Method]
The method in which this method is defined
The method in which this method is defined
- Annotations
- @Doc("Method this method is defined in", help.this.Doc.<init>$default$2, help.this.Doc.<init>$default$3)
- def definingTypeDecl: Traversal[codepropertygraph.generated.nodes.TypeDecl]
The type declaration associated with this method, e.g., the class it is defined in.
The type declaration associated with this method, e.g., the class it is defined in.
- Annotations
- @Doc("Type this method is defined in", help.this.Doc.<init>$default$2, help.this.Doc.<init>$default$3)
- def external: Traversal[codepropertygraph.generated.nodes.Method]
Traverse to external methods, that is, methods not present but only referenced in the CPG.
Traverse to external methods, that is, methods not present but only referenced in the CPG.
- Annotations
- @Doc("External methods (called, but no body available)", help.this.Doc.<init>$default$2, help.this.Doc.<init>$default$3)
- def getClass(): Class[_ <: AnyVal]
- Definition Classes
- AnyVal → Any
- def internal: Traversal[codepropertygraph.generated.nodes.Method]
Traverse to internal methods, that is, methods for which code is included in this CPG.
Traverse to internal methods, that is, methods for which code is included in this CPG.
- Annotations
- @Doc("Internal methods, i.e., a body is available", help.this.Doc.<init>$default$2, help.this.Doc.<init>$default$3)
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def isNotStub: Traversal[codepropertygraph.generated.nodes.Method]
Traverse only to methods that are not stubs.
- def isStub: Traversal[codepropertygraph.generated.nodes.Method]
Traverse only to methods that are stubs, e.g., their code is not available or the method body is empty.
- def literal: Traversal[Literal]
Traverse to literals of method
Traverse to literals of method
- Annotations
- @Doc("Literals used in the method", help.this.Doc.<init>$default$2, help.this.Doc.<init>$default$3)
- def local: Traversal[codepropertygraph.generated.nodes.Local]
Traverse to the methods local variables
Traverse to the methods local variables
- Annotations
- @Doc("Local variables declared in the method", help.this.Doc.<init>$default$2, help.this.Doc.<init>$default$3)
- def methodReturn: Traversal[codepropertygraph.generated.nodes.MethodReturn]
Traverse to formal return parameter
Traverse to formal return parameter
- Annotations
- @Doc("All formal return parameters", help.this.Doc.<init>$default$2, help.this.Doc.<init>$default$3)
- def namespace: Traversal[codepropertygraph.generated.nodes.Namespace]
Traverse to namespace
Traverse to namespace
- Annotations
- @Doc("Namespace this method is declared in", help.this.Doc.<init>$default$2, help.this.Doc.<init>$default$3)
- def numberOfLines: Traversal[Int]
- def parameter: Traversal[MethodParameterIn]
Traverse to parameters of the method
Traverse to parameters of the method
- Annotations
- @Doc("All parameters", help.this.Doc.<init>$default$2, help.this.Doc.<init>$default$3)
- def referencingBinding: Traversal[codepropertygraph.generated.nodes.Binding]
Traverse to bindings which reference to this method.
- def toString(): String
- Definition Classes
- Any
- def topLevelExpressions: Traversal[Expression]
- Annotations
- @Doc("Top level expressions (\"Statements\")", help.this.Doc.<init>$default$2, help.this.Doc.<init>$default$3)
- val traversal: Traversal[codepropertygraph.generated.nodes.Method]