Package io.shiftleft.proto.cpg
Enum Cpg.NodePropertyName
- java.lang.Object
-
- java.lang.Enum<Cpg.NodePropertyName>
-
- io.shiftleft.proto.cpg.Cpg.NodePropertyName
-
- All Implemented Interfaces:
com.google.protobuf.Internal.EnumLite
,com.google.protobuf.ProtocolMessageEnum
,java.io.Serializable
,java.lang.Comparable<Cpg.NodePropertyName>
- Enclosing class:
- Cpg
public static enum Cpg.NodePropertyName extends java.lang.Enum<Cpg.NodePropertyName> implements com.google.protobuf.ProtocolMessageEnum
Protobuf enumcpg.NodePropertyName
-
-
Enum Constant Summary
Enum Constants Enum Constant Description ALIAS_TYPE_FULL_NAME
This property holds the fully qualified name of the type that the node is a type alias of.ARGUMENT_INDEX
AST-children of CALL nodes have an argument index, that is used to match call-site arguments with callee parameters.ARGUMENT_NAME
For calls involving named parameters, the `ARGUMENT_NAME` field holds the name of the parameter initialized by the expression.AST_PARENT_FULL_NAME
This field holds the FULL_NAME of the AST parent of an entity.AST_PARENT_TYPE
The type of the AST parent.CANONICAL_NAME
This field holds the canonical name of a `FIELD_IDENTIFIER`.CLASS_NAME
CLASS_NAME = 104;
CLASS_SHORT_NAME
CLASS_SHORT_NAME = 132;
CODE
This field holds the code snippet that the node represents.COLUMN_NUMBER
This optional fields provides the column number of the program construct represented by the node.COLUMN_NUMBER_END
This optional fields provides the column number at which the program construct represented by the node ends.CONTAINED_REF
References to other nodes.CONTROL_STRUCTURE_TYPE
The `CONTROL_STRUCTURE_TYPE` field indicates which kind of control structure a `CONTROL_STRUCTURE` node represents.DISPATCH_TYPE
This field holds the dispatch type of a call, which is either `STATIC_DISPATCH` or `DYNAMIC_DISPATCH`.EVALUATION_STRATEGY
For formal method input parameters, output parameters, and return parameters, this field holds the evaluation strategy, which is one of the following: 1) `BY_REFERENCE` indicates that the parameter is passed by reference, 2) `BY_VALUE` indicates that it is passed by value, that is, a copy is made, 3) `BY_SHARING` the parameter is a pointer/reference and it is shared with the caller/callee.FILENAME
The absolute path of the source file this node was generated from.FULL_NAME
This is the fully-qualified name of an entity, e.g., the fully-qualified name of a method or type.HASH
This property contains a hash value in the form of a string.INHERITS_FROM_TYPE_FULL_NAME
The static types a TYPE_DECL inherits from.IS_EXTERNAL
Indicates that the construct (METHOD or TYPE_DECL) is external, that is, it is referenced but not defined in the code (applies both to insular parsing and to library functions where we have header files only)IS_VARIADIC
Specifies whether a parameter is the variadic argument handling parameter of a variadic method.KEY
This property denotes a key of a key-value pair.LANGUAGE
This field indicates which CPG language frontend generated the CPG.LINE_NUMBER
This optional field provides the line number of the program construct represented by the node.LINE_NUMBER_END
This optional fields provides the line number at which the program construct represented by the node ends.METHOD_FULL_NAME
The FULL_NAME of a method.METHOD_SHORT_NAME
METHOD_SHORT_NAME = 102;
MODIFIER_TYPE
The modifier type is a free-form string.NAME
Name of represented object, e.g., method name (e.g.NODE_LABEL
NODE_LABEL = 105;
ORDER
This integer indicates the position of the node among its siblings in the AST.OVERLAYS
The field contains the names of the overlays applied to this CPG, in order of their application.PACKAGE_NAME
PACKAGE_NAME = 103;
PARSER_TYPE_NAME
AST node type name emitted by parser.SIGNATURE
The method signature encodes the types of parameters in a string.SYMBOL
SYMBOL = 100;
TYPE_DECL_FULL_NAME
The static type decl of a TYPE.TYPE_FULL_NAME
This field contains the fully-qualified static type name of the program construct represented by a node.UNKNOWN_NODE_PROPERTY
UNKNOWN_NODE_PROPERTY = 0;
UNRECOGNIZED
VALUE
This property denotes a string value as used in a key-value pair.VERSION
A version, given as a string.
-
Field Summary
Fields Modifier and Type Field Description static int
ALIAS_TYPE_FULL_NAME_VALUE
This property holds the fully qualified name of the type that the node is a type alias of.static int
ARGUMENT_INDEX_VALUE
AST-children of CALL nodes have an argument index, that is used to match call-site arguments with callee parameters.static int
ARGUMENT_NAME_VALUE
For calls involving named parameters, the `ARGUMENT_NAME` field holds the name of the parameter initialized by the expression.static int
AST_PARENT_FULL_NAME_VALUE
This field holds the FULL_NAME of the AST parent of an entity.static int
AST_PARENT_TYPE_VALUE
The type of the AST parent.static int
CANONICAL_NAME_VALUE
This field holds the canonical name of a `FIELD_IDENTIFIER`.static int
CLASS_NAME_VALUE
CLASS_NAME = 104;
static int
CLASS_SHORT_NAME_VALUE
CLASS_SHORT_NAME = 132;
static int
CODE_VALUE
This field holds the code snippet that the node represents.static int
COLUMN_NUMBER_END_VALUE
This optional fields provides the column number at which the program construct represented by the node ends.static int
COLUMN_NUMBER_VALUE
This optional fields provides the column number of the program construct represented by the node.static int
CONTAINED_REF_VALUE
References to other nodes.static int
CONTROL_STRUCTURE_TYPE_VALUE
The `CONTROL_STRUCTURE_TYPE` field indicates which kind of control structure a `CONTROL_STRUCTURE` node represents.static int
DISPATCH_TYPE_VALUE
This field holds the dispatch type of a call, which is either `STATIC_DISPATCH` or `DYNAMIC_DISPATCH`.static int
EVALUATION_STRATEGY_VALUE
For formal method input parameters, output parameters, and return parameters, this field holds the evaluation strategy, which is one of the following: 1) `BY_REFERENCE` indicates that the parameter is passed by reference, 2) `BY_VALUE` indicates that it is passed by value, that is, a copy is made, 3) `BY_SHARING` the parameter is a pointer/reference and it is shared with the caller/callee.static int
FILENAME_VALUE
The absolute path of the source file this node was generated from.static int
FULL_NAME_VALUE
This is the fully-qualified name of an entity, e.g., the fully-qualified name of a method or type.static int
HASH_VALUE
This property contains a hash value in the form of a string.static int
INHERITS_FROM_TYPE_FULL_NAME_VALUE
The static types a TYPE_DECL inherits from.static int
IS_EXTERNAL_VALUE
Indicates that the construct (METHOD or TYPE_DECL) is external, that is, it is referenced but not defined in the code (applies both to insular parsing and to library functions where we have header files only)static int
IS_VARIADIC_VALUE
Specifies whether a parameter is the variadic argument handling parameter of a variadic method.static int
KEY_VALUE
This property denotes a key of a key-value pair.static int
LANGUAGE_VALUE
This field indicates which CPG language frontend generated the CPG.static int
LINE_NUMBER_END_VALUE
This optional fields provides the line number at which the program construct represented by the node ends.static int
LINE_NUMBER_VALUE
This optional field provides the line number of the program construct represented by the node.static int
METHOD_FULL_NAME_VALUE
The FULL_NAME of a method.static int
METHOD_SHORT_NAME_VALUE
METHOD_SHORT_NAME = 102;
static int
MODIFIER_TYPE_VALUE
The modifier type is a free-form string.static int
NAME_VALUE
Name of represented object, e.g., method name (e.g.static int
NODE_LABEL_VALUE
NODE_LABEL = 105;
static int
ORDER_VALUE
This integer indicates the position of the node among its siblings in the AST.static int
OVERLAYS_VALUE
The field contains the names of the overlays applied to this CPG, in order of their application.static int
PACKAGE_NAME_VALUE
PACKAGE_NAME = 103;
static int
PARSER_TYPE_NAME_VALUE
AST node type name emitted by parser.static int
SIGNATURE_VALUE
The method signature encodes the types of parameters in a string.static int
SYMBOL_VALUE
SYMBOL = 100;
static int
TYPE_DECL_FULL_NAME_VALUE
The static type decl of a TYPE.static int
TYPE_FULL_NAME_VALUE
This field contains the fully-qualified static type name of the program construct represented by a node.static int
UNKNOWN_NODE_PROPERTY_VALUE
UNKNOWN_NODE_PROPERTY = 0;
static int
VALUE_VALUE
This property denotes a string value as used in a key-value pair.static int
VERSION_VALUE
A version, given as a string.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static Cpg.NodePropertyName
forNumber(int value)
static com.google.protobuf.Descriptors.EnumDescriptor
getDescriptor()
com.google.protobuf.Descriptors.EnumDescriptor
getDescriptorForType()
int
getNumber()
com.google.protobuf.Descriptors.EnumValueDescriptor
getValueDescriptor()
static com.google.protobuf.Internal.EnumLiteMap<Cpg.NodePropertyName>
internalGetValueMap()
static Cpg.NodePropertyName
valueOf(int value)
Deprecated.static Cpg.NodePropertyName
valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc)
Returns the enum constant of this type with the specified name.static Cpg.NodePropertyName
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static Cpg.NodePropertyName[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
UNKNOWN_NODE_PROPERTY
public static final Cpg.NodePropertyName UNKNOWN_NODE_PROPERTY
UNKNOWN_NODE_PROPERTY = 0;
-
LINE_NUMBER
public static final Cpg.NodePropertyName LINE_NUMBER
This optional field provides the line number of the program construct represented by the node.
LINE_NUMBER = 2;
-
PARSER_TYPE_NAME
public static final Cpg.NodePropertyName PARSER_TYPE_NAME
AST node type name emitted by parser.
PARSER_TYPE_NAME = 3;
-
ORDER
public static final Cpg.NodePropertyName ORDER
This integer indicates the position of the node among its siblings in the AST. The left-most child has an order of 0.
ORDER = 4;
-
NAME
public static final Cpg.NodePropertyName NAME
Name of represented object, e.g., method name (e.g. "run")
NAME = 5;
-
FULL_NAME
public static final Cpg.NodePropertyName FULL_NAME
This is the fully-qualified name of an entity, e.g., the fully-qualified name of a method or type. The details of what constitutes a fully-qualified name are language specific. This field SHOULD be human readable.
FULL_NAME = 6;
-
IS_EXTERNAL
public static final Cpg.NodePropertyName IS_EXTERNAL
Indicates that the construct (METHOD or TYPE_DECL) is external, that is, it is referenced but not defined in the code (applies both to insular parsing and to library functions where we have header files only)
IS_EXTERNAL = 7;
-
VALUE
public static final Cpg.NodePropertyName VALUE
This property denotes a string value as used in a key-value pair.
VALUE = 8;
-
COLUMN_NUMBER
public static final Cpg.NodePropertyName COLUMN_NUMBER
This optional fields provides the column number of the program construct represented by the node.
COLUMN_NUMBER = 11;
-
LINE_NUMBER_END
public static final Cpg.NodePropertyName LINE_NUMBER_END
This optional fields provides the line number at which the program construct represented by the node ends.
LINE_NUMBER_END = 12;
-
VERSION
public static final Cpg.NodePropertyName VERSION
A version, given as a string. Used, for example, in the META_DATA node to indicate which version of the CPG spec this CPG conforms to
VERSION = 13;
-
EVALUATION_STRATEGY
public static final Cpg.NodePropertyName EVALUATION_STRATEGY
For formal method input parameters, output parameters, and return parameters, this field holds the evaluation strategy, which is one of the following: 1) `BY_REFERENCE` indicates that the parameter is passed by reference, 2) `BY_VALUE` indicates that it is passed by value, that is, a copy is made, 3) `BY_SHARING` the parameter is a pointer/reference and it is shared with the caller/callee. While a copy of the pointer is made, a copy of the object that it points to is not made.
EVALUATION_STRATEGY = 15;
-
COLUMN_NUMBER_END
public static final Cpg.NodePropertyName COLUMN_NUMBER_END
This optional fields provides the column number at which the program construct represented by the node ends.
COLUMN_NUMBER_END = 16;
-
LANGUAGE
public static final Cpg.NodePropertyName LANGUAGE
This field indicates which CPG language frontend generated the CPG. Frontend developers may freely choose a value that describes their frontend so long as it is not used by an existing frontend. Reserved values are to date: C, LLVM, GHIDRA, PHP.
LANGUAGE = 19;
-
CODE
public static final Cpg.NodePropertyName CODE
This field holds the code snippet that the node represents.
CODE = 21;
-
SIGNATURE
public static final Cpg.NodePropertyName SIGNATURE
The method signature encodes the types of parameters in a string. The string SHOULD be human readable and suitable for differentiating methods with different parameter types sufficiently to allow for resolving of function overloading. The present specification does not enforce a strict format for the signature, that is, it can be chosen by the frontend implementor to fit the source language.
SIGNATURE = 22;
-
DISPATCH_TYPE
public static final Cpg.NodePropertyName DISPATCH_TYPE
This field holds the dispatch type of a call, which is either `STATIC_DISPATCH` or `DYNAMIC_DISPATCH`. For statically dispatched method calls, the call target is known at compile time while for dynamically dispatched calls, it can only be determined at runtime as it may depend on the type of an object (as is the case for virtual method calls) or calculation of an offset.
DISPATCH_TYPE = 25;
-
MODIFIER_TYPE
public static final Cpg.NodePropertyName MODIFIER_TYPE
The modifier type is a free-form string. The following are known modifier types: `STATIC`, `PUBLIC`, `PROTECTED`, `PRIVATE`, `ABSTRACT`, `NATIVE`, `CONSTRUCTOR`, `VIRTUAL`.
MODIFIER_TYPE = 26;
-
CONTROL_STRUCTURE_TYPE
public static final Cpg.NodePropertyName CONTROL_STRUCTURE_TYPE
The `CONTROL_STRUCTURE_TYPE` field indicates which kind of control structure a `CONTROL_STRUCTURE` node represents. The available types are the following: BREAK, CONTINUE, DO, WHILE, FOR, GOTO, IF, ELSE, TRY, and SWITCH.
CONTROL_STRUCTURE_TYPE = 27;
-
ARGUMENT_INDEX
public static final Cpg.NodePropertyName ARGUMENT_INDEX
AST-children of CALL nodes have an argument index, that is used to match call-site arguments with callee parameters. Explicit parameters are numbered from 1 to N, while index 0 is reserved for implicit self / this parameter. CALLs without implicit parameter therefore have arguments starting with index 1. AST-children of BLOCK nodes may have an argument index as well; in this case, the last argument index determines the return expression of a BLOCK expression. If the `PARAMETER_NAME` field is set, then the `ARGUMENT_INDEX` field is ignored. It is suggested to set it to -1.
ARGUMENT_INDEX = 40;
-
TYPE_FULL_NAME
public static final Cpg.NodePropertyName TYPE_FULL_NAME
This field contains the fully-qualified static type name of the program construct represented by a node. It is the name of an instantiated type, e.g., `java.util.List<Integer>`, rather than `java.util.List[T]`. If the type cannot be determined, this field should be set to the empty string.
TYPE_FULL_NAME = 51;
-
TYPE_DECL_FULL_NAME
public static final Cpg.NodePropertyName TYPE_DECL_FULL_NAME
The static type decl of a TYPE. This property is matched against the FULL_NAME of TYPE_DECL nodes. It is required to have exactly one TYPE_DECL for each different TYPE_DECL_FULL_NAME
TYPE_DECL_FULL_NAME = 52;
-
INHERITS_FROM_TYPE_FULL_NAME
public static final Cpg.NodePropertyName INHERITS_FROM_TYPE_FULL_NAME
The static types a TYPE_DECL inherits from. This property is matched against the FULL_NAME of TYPE nodes and thus it is required to have at least one TYPE node for each TYPE_FULL_NAME
INHERITS_FROM_TYPE_FULL_NAME = 53;
-
METHOD_FULL_NAME
public static final Cpg.NodePropertyName METHOD_FULL_NAME
The FULL_NAME of a method. Used to link CALL and METHOD nodes. It is required to have exactly one METHOD node for each METHOD_FULL_NAME
METHOD_FULL_NAME = 54;
-
AST_PARENT_TYPE
public static final Cpg.NodePropertyName AST_PARENT_TYPE
The type of the AST parent. Since this is only used in some parts of the graph, the list does not include all possible parents by intention. Possible parents: METHOD, TYPE_DECL, NAMESPACE_BLOCK.
AST_PARENT_TYPE = 56;
-
AST_PARENT_FULL_NAME
public static final Cpg.NodePropertyName AST_PARENT_FULL_NAME
This field holds the FULL_NAME of the AST parent of an entity.
AST_PARENT_FULL_NAME = 57;
-
SYMBOL
public static final Cpg.NodePropertyName SYMBOL
SYMBOL = 100;
-
METHOD_SHORT_NAME
public static final Cpg.NodePropertyName METHOD_SHORT_NAME
METHOD_SHORT_NAME = 102;
-
PACKAGE_NAME
public static final Cpg.NodePropertyName PACKAGE_NAME
PACKAGE_NAME = 103;
-
CLASS_NAME
public static final Cpg.NodePropertyName CLASS_NAME
CLASS_NAME = 104;
-
NODE_LABEL
public static final Cpg.NodePropertyName NODE_LABEL
NODE_LABEL = 105;
-
FILENAME
public static final Cpg.NodePropertyName FILENAME
The absolute path of the source file this node was generated from. This field must be set but may be set to the value `<unknown>` to indicate that no source file can be associated with the node, e.g., because the node represents an entity known to exist because it is referenced, but for which the file that is is declared in is unknown.
FILENAME = 106;
-
OVERLAYS
public static final Cpg.NodePropertyName OVERLAYS
The field contains the names of the overlays applied to this CPG, in order of their application. Names are free-form strings, that is, this specification does not dictate them but rather requires tool producers and consumers to communicate them between each other.
OVERLAYS = 118;
-
HASH
public static final Cpg.NodePropertyName HASH
This property contains a hash value in the form of a string. Hashes can be used to summarize data, e.g., to summarize the contents of source files or sub graphs. Such summaries are useful to determine whether code has already been analyzed in incremental analysis pipelines. This property is optional to allow its calculation to be deferred or skipped if the hash is not needed.
HASH = 120;
-
ARGUMENT_NAME
public static final Cpg.NodePropertyName ARGUMENT_NAME
For calls involving named parameters, the `ARGUMENT_NAME` field holds the name of the parameter initialized by the expression. For all other calls, this field is unset.
ARGUMENT_NAME = 130;
-
KEY
public static final Cpg.NodePropertyName KEY
This property denotes a key of a key-value pair.
KEY = 131;
-
CLASS_SHORT_NAME
public static final Cpg.NodePropertyName CLASS_SHORT_NAME
CLASS_SHORT_NAME = 132;
-
ALIAS_TYPE_FULL_NAME
public static final Cpg.NodePropertyName ALIAS_TYPE_FULL_NAME
This property holds the fully qualified name of the type that the node is a type alias of.
ALIAS_TYPE_FULL_NAME = 158;
-
IS_VARIADIC
public static final Cpg.NodePropertyName IS_VARIADIC
Specifies whether a parameter is the variadic argument handling parameter of a variadic method. Only one parameter of a method is allowed to have this property set to true.
IS_VARIADIC = 221;
-
CANONICAL_NAME
public static final Cpg.NodePropertyName CANONICAL_NAME
This field holds the canonical name of a `FIELD_IDENTIFIER`. It is typically identical to the CODE field, but canonicalized according to source language semantics. Human readable names are preferable. `FIELD_IDENTIFIER` nodes must share identical `CANONICAL_NAME` if and only if they alias, e.g., in C-style unions (if the aliasing relationship is unknown or there are partial overlaps, then one must make a reasonable guess, and trade off between false negatives and false positives).
CANONICAL_NAME = 2001092;
-
CONTAINED_REF
public static final Cpg.NodePropertyName CONTAINED_REF
References to other nodes. This is not a real property; it exists here for the sake of proto serialization only. valueType and cardinality are meaningless.
CONTAINED_REF = 2007161;
-
UNRECOGNIZED
public static final Cpg.NodePropertyName UNRECOGNIZED
-
-
Field Detail
-
UNKNOWN_NODE_PROPERTY_VALUE
public static final int UNKNOWN_NODE_PROPERTY_VALUE
UNKNOWN_NODE_PROPERTY = 0;
- See Also:
- Constant Field Values
-
LINE_NUMBER_VALUE
public static final int LINE_NUMBER_VALUE
This optional field provides the line number of the program construct represented by the node.
LINE_NUMBER = 2;
- See Also:
- Constant Field Values
-
PARSER_TYPE_NAME_VALUE
public static final int PARSER_TYPE_NAME_VALUE
AST node type name emitted by parser.
PARSER_TYPE_NAME = 3;
- See Also:
- Constant Field Values
-
ORDER_VALUE
public static final int ORDER_VALUE
This integer indicates the position of the node among its siblings in the AST. The left-most child has an order of 0.
ORDER = 4;
- See Also:
- Constant Field Values
-
NAME_VALUE
public static final int NAME_VALUE
Name of represented object, e.g., method name (e.g. "run")
NAME = 5;
- See Also:
- Constant Field Values
-
FULL_NAME_VALUE
public static final int FULL_NAME_VALUE
This is the fully-qualified name of an entity, e.g., the fully-qualified name of a method or type. The details of what constitutes a fully-qualified name are language specific. This field SHOULD be human readable.
FULL_NAME = 6;
- See Also:
- Constant Field Values
-
IS_EXTERNAL_VALUE
public static final int IS_EXTERNAL_VALUE
Indicates that the construct (METHOD or TYPE_DECL) is external, that is, it is referenced but not defined in the code (applies both to insular parsing and to library functions where we have header files only)
IS_EXTERNAL = 7;
- See Also:
- Constant Field Values
-
VALUE_VALUE
public static final int VALUE_VALUE
This property denotes a string value as used in a key-value pair.
VALUE = 8;
- See Also:
- Constant Field Values
-
COLUMN_NUMBER_VALUE
public static final int COLUMN_NUMBER_VALUE
This optional fields provides the column number of the program construct represented by the node.
COLUMN_NUMBER = 11;
- See Also:
- Constant Field Values
-
LINE_NUMBER_END_VALUE
public static final int LINE_NUMBER_END_VALUE
This optional fields provides the line number at which the program construct represented by the node ends.
LINE_NUMBER_END = 12;
- See Also:
- Constant Field Values
-
VERSION_VALUE
public static final int VERSION_VALUE
A version, given as a string. Used, for example, in the META_DATA node to indicate which version of the CPG spec this CPG conforms to
VERSION = 13;
- See Also:
- Constant Field Values
-
EVALUATION_STRATEGY_VALUE
public static final int EVALUATION_STRATEGY_VALUE
For formal method input parameters, output parameters, and return parameters, this field holds the evaluation strategy, which is one of the following: 1) `BY_REFERENCE` indicates that the parameter is passed by reference, 2) `BY_VALUE` indicates that it is passed by value, that is, a copy is made, 3) `BY_SHARING` the parameter is a pointer/reference and it is shared with the caller/callee. While a copy of the pointer is made, a copy of the object that it points to is not made.
EVALUATION_STRATEGY = 15;
- See Also:
- Constant Field Values
-
COLUMN_NUMBER_END_VALUE
public static final int COLUMN_NUMBER_END_VALUE
This optional fields provides the column number at which the program construct represented by the node ends.
COLUMN_NUMBER_END = 16;
- See Also:
- Constant Field Values
-
LANGUAGE_VALUE
public static final int LANGUAGE_VALUE
This field indicates which CPG language frontend generated the CPG. Frontend developers may freely choose a value that describes their frontend so long as it is not used by an existing frontend. Reserved values are to date: C, LLVM, GHIDRA, PHP.
LANGUAGE = 19;
- See Also:
- Constant Field Values
-
CODE_VALUE
public static final int CODE_VALUE
This field holds the code snippet that the node represents.
CODE = 21;
- See Also:
- Constant Field Values
-
SIGNATURE_VALUE
public static final int SIGNATURE_VALUE
The method signature encodes the types of parameters in a string. The string SHOULD be human readable and suitable for differentiating methods with different parameter types sufficiently to allow for resolving of function overloading. The present specification does not enforce a strict format for the signature, that is, it can be chosen by the frontend implementor to fit the source language.
SIGNATURE = 22;
- See Also:
- Constant Field Values
-
DISPATCH_TYPE_VALUE
public static final int DISPATCH_TYPE_VALUE
This field holds the dispatch type of a call, which is either `STATIC_DISPATCH` or `DYNAMIC_DISPATCH`. For statically dispatched method calls, the call target is known at compile time while for dynamically dispatched calls, it can only be determined at runtime as it may depend on the type of an object (as is the case for virtual method calls) or calculation of an offset.
DISPATCH_TYPE = 25;
- See Also:
- Constant Field Values
-
MODIFIER_TYPE_VALUE
public static final int MODIFIER_TYPE_VALUE
The modifier type is a free-form string. The following are known modifier types: `STATIC`, `PUBLIC`, `PROTECTED`, `PRIVATE`, `ABSTRACT`, `NATIVE`, `CONSTRUCTOR`, `VIRTUAL`.
MODIFIER_TYPE = 26;
- See Also:
- Constant Field Values
-
CONTROL_STRUCTURE_TYPE_VALUE
public static final int CONTROL_STRUCTURE_TYPE_VALUE
The `CONTROL_STRUCTURE_TYPE` field indicates which kind of control structure a `CONTROL_STRUCTURE` node represents. The available types are the following: BREAK, CONTINUE, DO, WHILE, FOR, GOTO, IF, ELSE, TRY, and SWITCH.
CONTROL_STRUCTURE_TYPE = 27;
- See Also:
- Constant Field Values
-
ARGUMENT_INDEX_VALUE
public static final int ARGUMENT_INDEX_VALUE
AST-children of CALL nodes have an argument index, that is used to match call-site arguments with callee parameters. Explicit parameters are numbered from 1 to N, while index 0 is reserved for implicit self / this parameter. CALLs without implicit parameter therefore have arguments starting with index 1. AST-children of BLOCK nodes may have an argument index as well; in this case, the last argument index determines the return expression of a BLOCK expression. If the `PARAMETER_NAME` field is set, then the `ARGUMENT_INDEX` field is ignored. It is suggested to set it to -1.
ARGUMENT_INDEX = 40;
- See Also:
- Constant Field Values
-
TYPE_FULL_NAME_VALUE
public static final int TYPE_FULL_NAME_VALUE
This field contains the fully-qualified static type name of the program construct represented by a node. It is the name of an instantiated type, e.g., `java.util.List<Integer>`, rather than `java.util.List[T]`. If the type cannot be determined, this field should be set to the empty string.
TYPE_FULL_NAME = 51;
- See Also:
- Constant Field Values
-
TYPE_DECL_FULL_NAME_VALUE
public static final int TYPE_DECL_FULL_NAME_VALUE
The static type decl of a TYPE. This property is matched against the FULL_NAME of TYPE_DECL nodes. It is required to have exactly one TYPE_DECL for each different TYPE_DECL_FULL_NAME
TYPE_DECL_FULL_NAME = 52;
- See Also:
- Constant Field Values
-
INHERITS_FROM_TYPE_FULL_NAME_VALUE
public static final int INHERITS_FROM_TYPE_FULL_NAME_VALUE
The static types a TYPE_DECL inherits from. This property is matched against the FULL_NAME of TYPE nodes and thus it is required to have at least one TYPE node for each TYPE_FULL_NAME
INHERITS_FROM_TYPE_FULL_NAME = 53;
- See Also:
- Constant Field Values
-
METHOD_FULL_NAME_VALUE
public static final int METHOD_FULL_NAME_VALUE
The FULL_NAME of a method. Used to link CALL and METHOD nodes. It is required to have exactly one METHOD node for each METHOD_FULL_NAME
METHOD_FULL_NAME = 54;
- See Also:
- Constant Field Values
-
AST_PARENT_TYPE_VALUE
public static final int AST_PARENT_TYPE_VALUE
The type of the AST parent. Since this is only used in some parts of the graph, the list does not include all possible parents by intention. Possible parents: METHOD, TYPE_DECL, NAMESPACE_BLOCK.
AST_PARENT_TYPE = 56;
- See Also:
- Constant Field Values
-
AST_PARENT_FULL_NAME_VALUE
public static final int AST_PARENT_FULL_NAME_VALUE
This field holds the FULL_NAME of the AST parent of an entity.
AST_PARENT_FULL_NAME = 57;
- See Also:
- Constant Field Values
-
SYMBOL_VALUE
public static final int SYMBOL_VALUE
SYMBOL = 100;
- See Also:
- Constant Field Values
-
METHOD_SHORT_NAME_VALUE
public static final int METHOD_SHORT_NAME_VALUE
METHOD_SHORT_NAME = 102;
- See Also:
- Constant Field Values
-
PACKAGE_NAME_VALUE
public static final int PACKAGE_NAME_VALUE
PACKAGE_NAME = 103;
- See Also:
- Constant Field Values
-
CLASS_NAME_VALUE
public static final int CLASS_NAME_VALUE
CLASS_NAME = 104;
- See Also:
- Constant Field Values
-
NODE_LABEL_VALUE
public static final int NODE_LABEL_VALUE
NODE_LABEL = 105;
- See Also:
- Constant Field Values
-
FILENAME_VALUE
public static final int FILENAME_VALUE
The absolute path of the source file this node was generated from. This field must be set but may be set to the value `<unknown>` to indicate that no source file can be associated with the node, e.g., because the node represents an entity known to exist because it is referenced, but for which the file that is is declared in is unknown.
FILENAME = 106;
- See Also:
- Constant Field Values
-
OVERLAYS_VALUE
public static final int OVERLAYS_VALUE
The field contains the names of the overlays applied to this CPG, in order of their application. Names are free-form strings, that is, this specification does not dictate them but rather requires tool producers and consumers to communicate them between each other.
OVERLAYS = 118;
- See Also:
- Constant Field Values
-
HASH_VALUE
public static final int HASH_VALUE
This property contains a hash value in the form of a string. Hashes can be used to summarize data, e.g., to summarize the contents of source files or sub graphs. Such summaries are useful to determine whether code has already been analyzed in incremental analysis pipelines. This property is optional to allow its calculation to be deferred or skipped if the hash is not needed.
HASH = 120;
- See Also:
- Constant Field Values
-
ARGUMENT_NAME_VALUE
public static final int ARGUMENT_NAME_VALUE
For calls involving named parameters, the `ARGUMENT_NAME` field holds the name of the parameter initialized by the expression. For all other calls, this field is unset.
ARGUMENT_NAME = 130;
- See Also:
- Constant Field Values
-
KEY_VALUE
public static final int KEY_VALUE
This property denotes a key of a key-value pair.
KEY = 131;
- See Also:
- Constant Field Values
-
CLASS_SHORT_NAME_VALUE
public static final int CLASS_SHORT_NAME_VALUE
CLASS_SHORT_NAME = 132;
- See Also:
- Constant Field Values
-
ALIAS_TYPE_FULL_NAME_VALUE
public static final int ALIAS_TYPE_FULL_NAME_VALUE
This property holds the fully qualified name of the type that the node is a type alias of.
ALIAS_TYPE_FULL_NAME = 158;
- See Also:
- Constant Field Values
-
IS_VARIADIC_VALUE
public static final int IS_VARIADIC_VALUE
Specifies whether a parameter is the variadic argument handling parameter of a variadic method. Only one parameter of a method is allowed to have this property set to true.
IS_VARIADIC = 221;
- See Also:
- Constant Field Values
-
CANONICAL_NAME_VALUE
public static final int CANONICAL_NAME_VALUE
This field holds the canonical name of a `FIELD_IDENTIFIER`. It is typically identical to the CODE field, but canonicalized according to source language semantics. Human readable names are preferable. `FIELD_IDENTIFIER` nodes must share identical `CANONICAL_NAME` if and only if they alias, e.g., in C-style unions (if the aliasing relationship is unknown or there are partial overlaps, then one must make a reasonable guess, and trade off between false negatives and false positives).
CANONICAL_NAME = 2001092;
- See Also:
- Constant Field Values
-
CONTAINED_REF_VALUE
public static final int CONTAINED_REF_VALUE
References to other nodes. This is not a real property; it exists here for the sake of proto serialization only. valueType and cardinality are meaningless.
CONTAINED_REF = 2007161;
- See Also:
- Constant Field Values
-
-
Method Detail
-
values
public static Cpg.NodePropertyName[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (Cpg.NodePropertyName c : Cpg.NodePropertyName.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static Cpg.NodePropertyName valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
getNumber
public final int getNumber()
- Specified by:
getNumber
in interfacecom.google.protobuf.Internal.EnumLite
- Specified by:
getNumber
in interfacecom.google.protobuf.ProtocolMessageEnum
-
valueOf
@Deprecated public static Cpg.NodePropertyName valueOf(int value)
Deprecated.Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
value
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
forNumber
public static Cpg.NodePropertyName forNumber(int value)
- Parameters:
value
- The numeric wire value of the corresponding enum entry.- Returns:
- The enum associated with the given numeric wire value.
-
internalGetValueMap
public static com.google.protobuf.Internal.EnumLiteMap<Cpg.NodePropertyName> internalGetValueMap()
-
getValueDescriptor
public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor()
- Specified by:
getValueDescriptor
in interfacecom.google.protobuf.ProtocolMessageEnum
-
getDescriptorForType
public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType()
- Specified by:
getDescriptorForType
in interfacecom.google.protobuf.ProtocolMessageEnum
-
getDescriptor
public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor()
-
valueOf
public static Cpg.NodePropertyName valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
desc
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
-