Class CloudEvent

java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessageV3
io.cloudevents.v1.proto.CloudEvent
All Implemented Interfaces:
com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, CloudEventOrBuilder, Serializable

public final class CloudEvent extends com.google.protobuf.GeneratedMessageV3 implements CloudEventOrBuilder
Protobuf type io.cloudevents.v1.CloudEvent
See Also:
  • Field Details

  • Method Details

    • getUnknownFields

      public final com.google.protobuf.UnknownFieldSet getUnknownFields()
      Specified by:
      getUnknownFields in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getUnknownFields in class com.google.protobuf.GeneratedMessageV3
    • getDescriptor

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

      protected com.google.protobuf.MapField internalGetMapField(int number)
      Overrides:
      internalGetMapField in class com.google.protobuf.GeneratedMessageV3
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3
    • getDataCase

      public CloudEvent.DataCase getDataCase()
      Specified by:
      getDataCase in interface CloudEventOrBuilder
    • getId

      public String getId()
       Required Attributes
       
      string id = 1;
      Specified by:
      getId in interface CloudEventOrBuilder
    • getIdBytes

      public com.google.protobuf.ByteString getIdBytes()
       Required Attributes
       
      string id = 1;
      Specified by:
      getIdBytes in interface CloudEventOrBuilder
    • getSource

      public String getSource()
       URI-reference
       
      string source = 2;
      Specified by:
      getSource in interface CloudEventOrBuilder
    • getSourceBytes

      public com.google.protobuf.ByteString getSourceBytes()
       URI-reference
       
      string source = 2;
      Specified by:
      getSourceBytes in interface CloudEventOrBuilder
    • getSpecVersion

      public String getSpecVersion()
      string spec_version = 3;
      Specified by:
      getSpecVersion in interface CloudEventOrBuilder
    • getSpecVersionBytes

      public com.google.protobuf.ByteString getSpecVersionBytes()
      string spec_version = 3;
      Specified by:
      getSpecVersionBytes in interface CloudEventOrBuilder
    • getType

      public String getType()
      string type = 4;
      Specified by:
      getType in interface CloudEventOrBuilder
    • getTypeBytes

      public com.google.protobuf.ByteString getTypeBytes()
      string type = 4;
      Specified by:
      getTypeBytes in interface CloudEventOrBuilder
    • getAttributesCount

      public int getAttributesCount()
      Description copied from interface: CloudEventOrBuilder
       Optional & Extension Attributes
       
      map<string, .io.cloudevents.v1.CloudEvent.CloudEventAttributeValue> attributes = 5;
      Specified by:
      getAttributesCount in interface CloudEventOrBuilder
    • containsAttributes

      public boolean containsAttributes(String key)
       Optional & Extension Attributes
       
      map<string, .io.cloudevents.v1.CloudEvent.CloudEventAttributeValue> attributes = 5;
      Specified by:
      containsAttributes in interface CloudEventOrBuilder
    • getAttributes

      Deprecated.
      Use getAttributesMap() instead.
      Specified by:
      getAttributes in interface CloudEventOrBuilder
    • getAttributesMap

      public Map<String,CloudEvent.CloudEventAttributeValue> getAttributesMap()
       Optional & Extension Attributes
       
      map<string, .io.cloudevents.v1.CloudEvent.CloudEventAttributeValue> attributes = 5;
      Specified by:
      getAttributesMap in interface CloudEventOrBuilder
    • getAttributesOrDefault

      public CloudEvent.CloudEventAttributeValue getAttributesOrDefault(String key, CloudEvent.CloudEventAttributeValue defaultValue)
       Optional & Extension Attributes
       
      map<string, .io.cloudevents.v1.CloudEvent.CloudEventAttributeValue> attributes = 5;
      Specified by:
      getAttributesOrDefault in interface CloudEventOrBuilder
    • getAttributesOrThrow

      public CloudEvent.CloudEventAttributeValue getAttributesOrThrow(String key)
       Optional & Extension Attributes
       
      map<string, .io.cloudevents.v1.CloudEvent.CloudEventAttributeValue> attributes = 5;
      Specified by:
      getAttributesOrThrow in interface CloudEventOrBuilder
    • getBinaryData

      public com.google.protobuf.ByteString getBinaryData()
      bytes binary_data = 6;
      Specified by:
      getBinaryData in interface CloudEventOrBuilder
    • getTextData

      public String getTextData()
      string text_data = 7;
      Specified by:
      getTextData in interface CloudEventOrBuilder
    • getTextDataBytes

      public com.google.protobuf.ByteString getTextDataBytes()
      string text_data = 7;
      Specified by:
      getTextDataBytes in interface CloudEventOrBuilder
    • getProtoData

      public com.google.protobuf.Any getProtoData()
      .google.protobuf.Any proto_data = 8;
      Specified by:
      getProtoData in interface CloudEventOrBuilder
    • getProtoDataOrBuilder

      public com.google.protobuf.AnyOrBuilder getProtoDataOrBuilder()
      .google.protobuf.Any proto_data = 8;
      Specified by:
      getProtoDataOrBuilder in interface CloudEventOrBuilder
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessageV3
    • 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.GeneratedMessageV3
      Throws:
      IOException
    • getSerializedSize

      public int getSerializedSize()
      Specified by:
      getSerializedSize in interface com.google.protobuf.MessageLite
      Overrides:
      getSerializedSize in class com.google.protobuf.GeneratedMessageV3
    • 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 CloudEvent parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

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

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

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

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

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

      public static CloudEvent parseFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

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

      public static CloudEvent parseDelimitedFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

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

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

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

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

      public static CloudEvent.Builder newBuilder()
    • newBuilder

      public static CloudEvent.Builder newBuilder(CloudEvent prototype)
    • toBuilder

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

      protected CloudEvent.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
      Specified by:
      newBuilderForType in class com.google.protobuf.GeneratedMessageV3
    • getDefaultInstance

      public static CloudEvent getDefaultInstance()
    • parser

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

      public com.google.protobuf.Parser<CloudEvent> 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.GeneratedMessageV3
    • getDefaultInstanceForType

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