abstract class CpgPass extends CpgPassBase
Base class for CPG pass - a program, which receives an input graph and outputs a sequence of additive diff graphs. These diff graphs can be merged into the original graph ("applied"), they can be serialized into a binary format, and finally, they can be added to an existing cpg.bin.zip file.
A pass is provided by inheriting from this class and implementing run
,
a method, which creates the sequence of diff graphs from an input graph.
Overview of steps and their meaning:
1. Create: A sequence of diff graphs is created from the source graph 2. Apply: Each diff graph can be applied to the source graph 3. Serialize: After applying a diff graph, the diff graph can be serialized into a CPG overlay 4. Store: The CPG overlay can be stored in a serialized CPG.
- Alphabetic
- By Inheritance
- CpgPass
- CpgPassBase
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
Abstract Value Members
Concrete Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- def createAndApply(): Unit
Execute the enhancement and apply result to the underlying graph
Execute the enhancement and apply result to the underlying graph
- Definition Classes
- CpgPass → CpgPassBase
- def createApplyAndSerialize(inverse: Boolean = false): Iterator[GeneratedMessageV3]
Execute and create a serialized overlay
Execute and create a serialized overlay
- inverse
invert the diffgraph before serializing
- def createApplySerializeAndStore(serializedCpg: SerializedCpg, inverse: Boolean = false, prefix: String = ""): Unit
Run a CPG pass to create diff graphs, apply diff graphs, create corresponding overlays and add them to the serialized CPG.
Run a CPG pass to create diff graphs, apply diff graphs, create corresponding overlays and add them to the serialized CPG. The name of the overlay is derived from the class name of the pass.
- serializedCpg
the destination serialized CPG to add overlays to
- inverse
invert the diffgraph before serializing
- prefix
a prefix to add to the output name
- Definition Classes
- CpgPass → CpgPassBase
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- def generateOutFileName(prefix: String, outName: String, index: Int): String
- Attributes
- protected
- Definition Classes
- CpgPassBase
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def name: String
Name of the enhancement pass.
Name of the enhancement pass. By default it is inferred from the name of the class, override if needed.
- Definition Classes
- CpgPassBase
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- def serialize(appliedDiffGraph: AppliedDiffGraph, inverse: Boolean): GeneratedMessageV3
- Attributes
- protected
- Definition Classes
- CpgPassBase
- def store(overlay: GeneratedMessageV3, name: String, serializedCpg: SerializedCpg): Unit
- Attributes
- protected
- Definition Classes
- CpgPassBase
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- def withStartEndTimesLogged[A](fun: => A): A
- Attributes
- protected
- Definition Classes
- CpgPassBase