Package p4.config.v1

Class P4Types.P4NewTypeSpec

java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessage
p4.config.v1.P4Types.P4NewTypeSpec
All Implemented Interfaces:
com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Serializable, P4Types.P4NewTypeSpecOrBuilder
Enclosing class:
P4Types

public static final class P4Types.P4NewTypeSpec extends com.google.protobuf.GeneratedMessage implements P4Types.P4NewTypeSpecOrBuilder
 New types introduced with the "type" keyword
 
Protobuf type p4.config.v1.P4NewTypeSpec
See Also:
  • Field Details

    • ORIGINAL_TYPE_FIELD_NUMBER

      public static final int ORIGINAL_TYPE_FIELD_NUMBER
      See Also:
    • TRANSLATED_TYPE_FIELD_NUMBER

      public static final int TRANSLATED_TYPE_FIELD_NUMBER
      See Also:
    • ANNOTATIONS_FIELD_NUMBER

      public static final int ANNOTATIONS_FIELD_NUMBER
      See Also:
    • ANNOTATION_LOCATIONS_FIELD_NUMBER

      public static final int ANNOTATION_LOCATIONS_FIELD_NUMBER
      See Also:
    • STRUCTURED_ANNOTATIONS_FIELD_NUMBER

      public static final int STRUCTURED_ANNOTATIONS_FIELD_NUMBER
      See Also:
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessage
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage
    • getRepresentationCase

      public P4Types.P4NewTypeSpec.RepresentationCase getRepresentationCase()
      Specified by:
      getRepresentationCase in interface P4Types.P4NewTypeSpecOrBuilder
    • hasOriginalType

      public boolean hasOriginalType()
       if no @p4runtime_translation annotation present
       
      .p4.config.v1.P4DataTypeSpec original_type = 1;
      Specified by:
      hasOriginalType in interface P4Types.P4NewTypeSpecOrBuilder
      Returns:
      Whether the originalType field is set.
    • getOriginalType

      public P4Types.P4DataTypeSpec getOriginalType()
       if no @p4runtime_translation annotation present
       
      .p4.config.v1.P4DataTypeSpec original_type = 1;
      Specified by:
      getOriginalType in interface P4Types.P4NewTypeSpecOrBuilder
      Returns:
      The originalType.
    • getOriginalTypeOrBuilder

      public P4Types.P4DataTypeSpecOrBuilder getOriginalTypeOrBuilder()
       if no @p4runtime_translation annotation present
       
      .p4.config.v1.P4DataTypeSpec original_type = 1;
      Specified by:
      getOriginalTypeOrBuilder in interface P4Types.P4NewTypeSpecOrBuilder
    • hasTranslatedType

      public boolean hasTranslatedType()
       if @p4runtime_translation annotation present
       
      .p4.config.v1.P4NewTypeTranslation translated_type = 2;
      Specified by:
      hasTranslatedType in interface P4Types.P4NewTypeSpecOrBuilder
      Returns:
      Whether the translatedType field is set.
    • getTranslatedType

      public P4Types.P4NewTypeTranslation getTranslatedType()
       if @p4runtime_translation annotation present
       
      .p4.config.v1.P4NewTypeTranslation translated_type = 2;
      Specified by:
      getTranslatedType in interface P4Types.P4NewTypeSpecOrBuilder
      Returns:
      The translatedType.
    • getTranslatedTypeOrBuilder

      public P4Types.P4NewTypeTranslationOrBuilder getTranslatedTypeOrBuilder()
       if @p4runtime_translation annotation present
       
      .p4.config.v1.P4NewTypeTranslation translated_type = 2;
      Specified by:
      getTranslatedTypeOrBuilder in interface P4Types.P4NewTypeSpecOrBuilder
    • getAnnotationsList

      public com.google.protobuf.ProtocolStringList getAnnotationsList()
       for other annotations (not @p4runtime_translation)
       
      repeated string annotations = 3;
      Specified by:
      getAnnotationsList in interface P4Types.P4NewTypeSpecOrBuilder
      Returns:
      A list containing the annotations.
    • getAnnotationsCount

      public int getAnnotationsCount()
       for other annotations (not @p4runtime_translation)
       
      repeated string annotations = 3;
      Specified by:
      getAnnotationsCount in interface P4Types.P4NewTypeSpecOrBuilder
      Returns:
      The count of annotations.
    • getAnnotations

      public String getAnnotations(int index)
       for other annotations (not @p4runtime_translation)
       
      repeated string annotations = 3;
      Specified by:
      getAnnotations in interface P4Types.P4NewTypeSpecOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The annotations at the given index.
    • getAnnotationsBytes

      public com.google.protobuf.ByteString getAnnotationsBytes(int index)
       for other annotations (not @p4runtime_translation)
       
      repeated string annotations = 3;
      Specified by:
      getAnnotationsBytes in interface P4Types.P4NewTypeSpecOrBuilder
      Parameters:
      index - The index of the value to return.
      Returns:
      The bytes of the annotations at the given index.
    • getAnnotationLocationsList

      public List<P4Types.SourceLocation> getAnnotationLocationsList()
       Optional. If present, the location of `annotations[i]` is given by
       `annotation_locations[i]`.
       
      repeated .p4.config.v1.SourceLocation annotation_locations = 5;
      Specified by:
      getAnnotationLocationsList in interface P4Types.P4NewTypeSpecOrBuilder
    • getAnnotationLocationsOrBuilderList

      public List<? extends P4Types.SourceLocationOrBuilder> getAnnotationLocationsOrBuilderList()
       Optional. If present, the location of `annotations[i]` is given by
       `annotation_locations[i]`.
       
      repeated .p4.config.v1.SourceLocation annotation_locations = 5;
      Specified by:
      getAnnotationLocationsOrBuilderList in interface P4Types.P4NewTypeSpecOrBuilder
    • getAnnotationLocationsCount

      public int getAnnotationLocationsCount()
       Optional. If present, the location of `annotations[i]` is given by
       `annotation_locations[i]`.
       
      repeated .p4.config.v1.SourceLocation annotation_locations = 5;
      Specified by:
      getAnnotationLocationsCount in interface P4Types.P4NewTypeSpecOrBuilder
    • getAnnotationLocations

      public P4Types.SourceLocation getAnnotationLocations(int index)
       Optional. If present, the location of `annotations[i]` is given by
       `annotation_locations[i]`.
       
      repeated .p4.config.v1.SourceLocation annotation_locations = 5;
      Specified by:
      getAnnotationLocations in interface P4Types.P4NewTypeSpecOrBuilder
    • getAnnotationLocationsOrBuilder

      public P4Types.SourceLocationOrBuilder getAnnotationLocationsOrBuilder(int index)
       Optional. If present, the location of `annotations[i]` is given by
       `annotation_locations[i]`.
       
      repeated .p4.config.v1.SourceLocation annotation_locations = 5;
      Specified by:
      getAnnotationLocationsOrBuilder in interface P4Types.P4NewTypeSpecOrBuilder
    • getStructuredAnnotationsList

      public List<P4Types.StructuredAnnotation> getStructuredAnnotationsList()
      repeated .p4.config.v1.StructuredAnnotation structured_annotations = 4;
      Specified by:
      getStructuredAnnotationsList in interface P4Types.P4NewTypeSpecOrBuilder
    • getStructuredAnnotationsOrBuilderList

      public List<? extends P4Types.StructuredAnnotationOrBuilder> getStructuredAnnotationsOrBuilderList()
      repeated .p4.config.v1.StructuredAnnotation structured_annotations = 4;
      Specified by:
      getStructuredAnnotationsOrBuilderList in interface P4Types.P4NewTypeSpecOrBuilder
    • getStructuredAnnotationsCount

      public int getStructuredAnnotationsCount()
      repeated .p4.config.v1.StructuredAnnotation structured_annotations = 4;
      Specified by:
      getStructuredAnnotationsCount in interface P4Types.P4NewTypeSpecOrBuilder
    • getStructuredAnnotations

      public P4Types.StructuredAnnotation getStructuredAnnotations(int index)
      repeated .p4.config.v1.StructuredAnnotation structured_annotations = 4;
      Specified by:
      getStructuredAnnotations in interface P4Types.P4NewTypeSpecOrBuilder
    • getStructuredAnnotationsOrBuilder

      public P4Types.StructuredAnnotationOrBuilder getStructuredAnnotationsOrBuilder(int index)
      repeated .p4.config.v1.StructuredAnnotation structured_annotations = 4;
      Specified by:
      getStructuredAnnotationsOrBuilder in interface P4Types.P4NewTypeSpecOrBuilder
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage
    • writeTo

      public void writeTo(com.google.protobuf.CodedOutputStream output) throws IOException
      Specified by:
      writeTo in interface com.google.protobuf.MessageLite
      Overrides:
      writeTo in class com.google.protobuf.GeneratedMessage
      Throws:
      IOException
    • getSerializedSize

      public int getSerializedSize()
      Specified by:
      getSerializedSize in interface com.google.protobuf.MessageLite
      Overrides:
      getSerializedSize in class com.google.protobuf.GeneratedMessage
    • equals

      public boolean equals(Object obj)
      Specified by:
      equals in interface com.google.protobuf.Message
      Overrides:
      equals in class com.google.protobuf.AbstractMessage
    • hashCode

      public int hashCode()
      Specified by:
      hashCode in interface com.google.protobuf.Message
      Overrides:
      hashCode in class com.google.protobuf.AbstractMessage
    • parseFrom

      public static P4Types.P4NewTypeSpec parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static P4Types.P4NewTypeSpec parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static P4Types.P4NewTypeSpec parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static P4Types.P4NewTypeSpec parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static P4Types.P4NewTypeSpec parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static P4Types.P4NewTypeSpec parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static P4Types.P4NewTypeSpec parseFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static P4Types.P4NewTypeSpec parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static P4Types.P4NewTypeSpec parseDelimitedFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static P4Types.P4NewTypeSpec parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseFrom

      public static P4Types.P4NewTypeSpec parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static P4Types.P4NewTypeSpec parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • newBuilderForType

      public P4Types.P4NewTypeSpec.Builder newBuilderForType()
      Specified by:
      newBuilderForType in interface com.google.protobuf.Message
      Specified by:
      newBuilderForType in interface com.google.protobuf.MessageLite
    • newBuilder

      public static P4Types.P4NewTypeSpec.Builder newBuilder()
    • newBuilder

      public static P4Types.P4NewTypeSpec.Builder newBuilder(P4Types.P4NewTypeSpec prototype)
    • toBuilder

      public P4Types.P4NewTypeSpec.Builder toBuilder()
      Specified by:
      toBuilder in interface com.google.protobuf.Message
      Specified by:
      toBuilder in interface com.google.protobuf.MessageLite
    • newBuilderForType

      protected P4Types.P4NewTypeSpec.Builder newBuilderForType(com.google.protobuf.AbstractMessage.BuilderParent parent)
      Overrides:
      newBuilderForType in class com.google.protobuf.AbstractMessage
    • getDefaultInstance

      public static P4Types.P4NewTypeSpec getDefaultInstance()
    • parser

      public static com.google.protobuf.Parser<P4Types.P4NewTypeSpec> parser()
    • getParserForType

      public com.google.protobuf.Parser<P4Types.P4NewTypeSpec> getParserForType()
      Specified by:
      getParserForType in interface com.google.protobuf.Message
      Specified by:
      getParserForType in interface com.google.protobuf.MessageLite
      Overrides:
      getParserForType in class com.google.protobuf.GeneratedMessage
    • getDefaultInstanceForType

      public P4Types.P4NewTypeSpec getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder