Package com.google.api.expr.v1beta1
Interface SourceInfoOrBuilder
- All Superinterfaces:
com.google.protobuf.MessageLiteOrBuilder
- All Known Implementing Classes:
SourceInfo
,SourceInfo.Builder
public interface SourceInfoOrBuilder
extends com.google.protobuf.MessageLiteOrBuilder
-
Method Summary
Modifier and TypeMethodDescriptionboolean
containsPositions
(int key) A map from the parse node id (e.g.int
getLineOffsets
(int index) Monotonically increasing list of character offsets where newlines appear.int
Monotonically increasing list of character offsets where newlines appear.Monotonically increasing list of character offsets where newlines appear.The location name.com.google.protobuf.ByteString
The location name.Deprecated.int
A map from the parse node id (e.g.A map from the parse node id (e.g.int
getPositionsOrDefault
(int key, int defaultValue) A map from the parse node id (e.g.int
getPositionsOrThrow
(int key) A map from the parse node id (e.g.Methods inherited from interface com.google.protobuf.MessageLiteOrBuilder
getDefaultInstanceForType, isInitialized
-
Method Details
-
getLocation
String getLocation()The location name. All position information attached to an expression is relative to this location. The location could be a file, UI element, or similar. For example, `acme/app/AnvilPolicy.cel`.
string location = 2 [json_name = "location"];
- Returns:
- The location.
-
getLocationBytes
com.google.protobuf.ByteString getLocationBytes()The location name. All position information attached to an expression is relative to this location. The location could be a file, UI element, or similar. For example, `acme/app/AnvilPolicy.cel`.
string location = 2 [json_name = "location"];
- Returns:
- The bytes for location.
-
getLineOffsetsList
Monotonically increasing list of character offsets where newlines appear. The line number of a given position is the index `i` where for a given `id` the `line_offsets[i] < id_positions[id] < line_offsets[i+1]`. The column may be derivd from `id_positions[id] - line_offsets[i]`.
repeated int32 line_offsets = 3 [json_name = "lineOffsets"];
- Returns:
- A list containing the lineOffsets.
-
getLineOffsetsCount
int getLineOffsetsCount()Monotonically increasing list of character offsets where newlines appear. The line number of a given position is the index `i` where for a given `id` the `line_offsets[i] < id_positions[id] < line_offsets[i+1]`. The column may be derivd from `id_positions[id] - line_offsets[i]`.
repeated int32 line_offsets = 3 [json_name = "lineOffsets"];
- Returns:
- The count of lineOffsets.
-
getLineOffsets
int getLineOffsets(int index) Monotonically increasing list of character offsets where newlines appear. The line number of a given position is the index `i` where for a given `id` the `line_offsets[i] < id_positions[id] < line_offsets[i+1]`. The column may be derivd from `id_positions[id] - line_offsets[i]`.
repeated int32 line_offsets = 3 [json_name = "lineOffsets"];
- Parameters:
index
- The index of the element to return.- Returns:
- The lineOffsets at the given index.
-
getPositionsCount
int getPositionsCount()A map from the parse node id (e.g. `Expr.id`) to the character offset within source.
map<int32, int32> positions = 4 [json_name = "positions"];
-
containsPositions
boolean containsPositions(int key) A map from the parse node id (e.g. `Expr.id`) to the character offset within source.
map<int32, int32> positions = 4 [json_name = "positions"];
-
getPositions
Deprecated.UsegetPositionsMap()
instead. -
getPositionsMap
A map from the parse node id (e.g. `Expr.id`) to the character offset within source.
map<int32, int32> positions = 4 [json_name = "positions"];
-
getPositionsOrDefault
int getPositionsOrDefault(int key, int defaultValue) A map from the parse node id (e.g. `Expr.id`) to the character offset within source.
map<int32, int32> positions = 4 [json_name = "positions"];
-
getPositionsOrThrow
int getPositionsOrThrow(int key) A map from the parse node id (e.g. `Expr.id`) to the character offset within source.
map<int32, int32> positions = 4 [json_name = "positions"];
-