Package com.google.api.expr.v1beta1
Class SourceInfo
java.lang.Object
com.google.protobuf.AbstractMessageLite<MessageType,BuilderType>
com.google.protobuf.GeneratedMessageLite<SourceInfo,SourceInfo.Builder>
com.google.api.expr.v1beta1.SourceInfo
- All Implemented Interfaces:
SourceInfoOrBuilder,com.google.protobuf.MessageLite,com.google.protobuf.MessageLiteOrBuilder
public final class SourceInfo
extends com.google.protobuf.GeneratedMessageLite<SourceInfo,SourceInfo.Builder>
implements SourceInfoOrBuilder
Source information collected at parse time.Protobuf type
google.api.expr.v1beta1.SourceInfo-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classSource information collected at parse time.Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageLite
com.google.protobuf.GeneratedMessageLite.DefaultInstanceBasedParser<T extends com.google.protobuf.GeneratedMessageLite<T,?>>, com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<MessageType extends com.google.protobuf.GeneratedMessageLite.ExtendableMessage<MessageType, BuilderType>, BuilderType extends com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<MessageType, BuilderType>>, com.google.protobuf.GeneratedMessageLite.ExtendableMessage<MessageType extends com.google.protobuf.GeneratedMessageLite.ExtendableMessage<MessageType, BuilderType>, BuilderType extends com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<MessageType, BuilderType>>, com.google.protobuf.GeneratedMessageLite.ExtendableMessageOrBuilder<MessageType extends com.google.protobuf.GeneratedMessageLite.ExtendableMessage<MessageType, BuilderType>, BuilderType extends com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<MessageType, BuilderType>>, com.google.protobuf.GeneratedMessageLite.GeneratedExtension<ContainingType extends com.google.protobuf.MessageLite, Type extends Object>, com.google.protobuf.GeneratedMessageLite.MethodToInvoke, com.google.protobuf.GeneratedMessageLite.SerializedForm Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessageLite.InternalOneOfEnum -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intFields inherited from class com.google.protobuf.GeneratedMessageLite
unknownFieldsFields inherited from class com.google.protobuf.AbstractMessageLite
memoizedHashCode -
Method Summary
Modifier and TypeMethodDescriptionbooleancontainsPositions(int key) A map from the parse node id (e.g.protected final ObjectdynamicMethod(com.google.protobuf.GeneratedMessageLite.MethodToInvoke method, Object arg0, Object arg1) static SourceInfointgetLineOffsets(int index) Monotonically increasing list of character offsets where newlines appear.intMonotonically increasing list of character offsets where newlines appear.Monotonically increasing list of character offsets where newlines appear.The location name.com.google.protobuf.ByteStringThe location name.Deprecated.intA map from the parse node id (e.g.A map from the parse node id (e.g.intgetPositionsOrDefault(int key, int defaultValue) A map from the parse node id (e.g.intgetPositionsOrThrow(int key) A map from the parse node id (e.g.static SourceInfo.Builderstatic SourceInfo.BuildernewBuilder(SourceInfo prototype) static SourceInfoparseDelimitedFrom(InputStream input) static SourceInfoparseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static SourceInfoparseFrom(byte[] data) static SourceInfoparseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static SourceInfoparseFrom(com.google.protobuf.ByteString data) static SourceInfoparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static SourceInfoparseFrom(com.google.protobuf.CodedInputStream input) static SourceInfoparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static SourceInfoparseFrom(InputStream input) static SourceInfoparseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static SourceInfoparseFrom(ByteBuffer data) static SourceInfoparseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static com.google.protobuf.Parser<SourceInfo>parser()Methods inherited from class com.google.protobuf.GeneratedMessageLite
createBuilder, createBuilder, dynamicMethod, dynamicMethod, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyLongList, emptyProtobufList, equals, getDefaultInstanceForType, getParserForType, getSerializedSize, hashCode, isInitialized, isInitialized, makeImmutable, mergeLengthDelimitedField, mergeUnknownFields, mergeVarintField, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBuilderForType, newMessageInfo, newRepeatedGeneratedExtension, newSingularGeneratedExtension, parseDelimitedFrom, parseDelimitedFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parsePartialFrom, parseUnknownField, registerDefaultInstance, toBuilder, toString, writeToMethods inherited from class com.google.protobuf.AbstractMessageLite
addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.MessageLiteOrBuilder
getDefaultInstanceForType, isInitialized
-
Field Details
-
LOCATION_FIELD_NUMBER
public static final int LOCATION_FIELD_NUMBER- See Also:
-
LINE_OFFSETS_FIELD_NUMBER
public static final int LINE_OFFSETS_FIELD_NUMBER- See Also:
-
POSITIONS_FIELD_NUMBER
public static final int POSITIONS_FIELD_NUMBER- See Also:
-
-
Method Details
-
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"];- Specified by:
getLocationin interfaceSourceInfoOrBuilder- Returns:
- The location.
-
getLocationBytes
public 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"];- Specified by:
getLocationBytesin interfaceSourceInfoOrBuilder- 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"];- Specified by:
getLineOffsetsListin interfaceSourceInfoOrBuilder- Returns:
- A list containing the lineOffsets.
-
getLineOffsetsCount
public 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"];- Specified by:
getLineOffsetsCountin interfaceSourceInfoOrBuilder- Returns:
- The count of lineOffsets.
-
getLineOffsets
public 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"];- Specified by:
getLineOffsetsin interfaceSourceInfoOrBuilder- Parameters:
index- The index of the element to return.- Returns:
- The lineOffsets at the given index.
-
getPositionsCount
public int getPositionsCount()Description copied from interface:SourceInfoOrBuilderA map from the parse node id (e.g. `Expr.id`) to the character offset within source.
map<int32, int32> positions = 4 [json_name = "positions"];- Specified by:
getPositionsCountin interfaceSourceInfoOrBuilder
-
containsPositions
public 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"];- Specified by:
containsPositionsin interfaceSourceInfoOrBuilder
-
getPositions
Deprecated.UsegetPositionsMap()instead.- Specified by:
getPositionsin interfaceSourceInfoOrBuilder
-
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"];- Specified by:
getPositionsMapin interfaceSourceInfoOrBuilder
-
getPositionsOrDefault
public 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"];- Specified by:
getPositionsOrDefaultin interfaceSourceInfoOrBuilder
-
getPositionsOrThrow
public 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"];- Specified by:
getPositionsOrThrowin interfaceSourceInfoOrBuilder
-
parseFrom
public static SourceInfo parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static SourceInfo parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static SourceInfo parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static SourceInfo parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static SourceInfo parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static SourceInfo parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static SourceInfo parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseDelimitedFrom
- Throws:
IOException
-
parseDelimitedFrom
public static SourceInfo parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static SourceInfo parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
newBuilder
-
newBuilder
-
dynamicMethod
protected final Object dynamicMethod(com.google.protobuf.GeneratedMessageLite.MethodToInvoke method, Object arg0, Object arg1) - Specified by:
dynamicMethodin classcom.google.protobuf.GeneratedMessageLite<SourceInfo,SourceInfo.Builder>
-
getDefaultInstance
-
parser
-