Class Message

  • All Implemented Interfaces:
    MessageOrBuilder, com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Serializable

    public final class Message
    extends com.google.protobuf.GeneratedMessageV3
    implements MessageOrBuilder
    Protobuf type blipai.deckard.Message
    See Also:
    Serialized Form
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  Message.Builder
      Protobuf type blipai.deckard.Message
      • Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageV3

        com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>,​BuilderT extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT,​BuilderT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter
      • Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite

        com.google.protobuf.AbstractMessageLite.InternalOneOfEnum
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method Description
      boolean containsMetadata​(String key)
      Metadata is a map of string to be used as a key-value store.
      boolean containsPayload​(String key)
      A payload map with formatted data to be stored and used by clients.
      boolean equals​(Object obj)  
      String getBreakpoint()
      Breakpoint is a field to be used as an auxiliar field for some specific use cases.
      com.google.protobuf.ByteString getBreakpointBytes()
      Breakpoint is a field to be used as an auxiliar field for some specific use cases.
      static Message getDefaultInstance()  
      Message getDefaultInstanceForType()  
      String getDescription()
      Description of the message, this should be used as a human readable string to be used in diagnostics.
      com.google.protobuf.ByteString getDescriptionBytes()
      Description of the message, this should be used as a human readable string to be used in diagnostics.
      static com.google.protobuf.Descriptors.Descriptor getDescriptor()  
      MessageDiagnostics getDiagnostics()
      Diagnostics is a field holding information about the message's usage.
      MessageDiagnosticsOrBuilder getDiagnosticsOrBuilder()
      Diagnostics is a field holding information about the message's usage.
      String getId()
      ID is an unique identifier inside a queue.
      com.google.protobuf.ByteString getIdBytes()
      ID is an unique identifier inside a queue.
      Map<String,​String> getMetadata()
      Deprecated.
      int getMetadataCount()
      Metadata is a map of string to be used as a key-value store.
      Map<String,​String> getMetadataMap()
      Metadata is a map of string to be used as a key-value store.
      String getMetadataOrDefault​(String key, String defaultValue)
      Metadata is a map of string to be used as a key-value store.
      String getMetadataOrThrow​(String key)
      Metadata is a map of string to be used as a key-value store.
      com.google.protobuf.Parser<Message> getParserForType()  
      Map<String,​com.google.protobuf.Any> getPayload()
      Deprecated.
      int getPayloadCount()
      A payload map with formatted data to be stored and used by clients.
      Map<String,​com.google.protobuf.Any> getPayloadMap()
      A payload map with formatted data to be stored and used by clients.
      com.google.protobuf.Any getPayloadOrDefault​(String key, com.google.protobuf.Any defaultValue)
      A payload map with formatted data to be stored and used by clients.
      com.google.protobuf.Any getPayloadOrThrow​(String key)
      A payload map with formatted data to be stored and used by clients.
      String getQueue()
      Full name of the queue this message belongs (including any prefixes)
      com.google.protobuf.ByteString getQueueBytes()
      Full name of the queue this message belongs (including any prefixes)
      double getScore()
      Score represents the priority score the message currently have in the queue.
      int getSerializedSize()  
      String getStringPayload()
      Message string payload.
      com.google.protobuf.ByteString getStringPayloadBytes()
      Message string payload.
      boolean hasDiagnostics()
      Diagnostics is a field holding information about the message's usage.
      int hashCode()  
      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()  
      protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection​(int number)  
      boolean isInitialized()  
      static Message.Builder newBuilder()  
      static Message.Builder newBuilder​(Message prototype)  
      Message.Builder newBuilderForType()  
      protected Message.Builder newBuilderForType​(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)  
      protected Object newInstance​(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)  
      static Message parseDelimitedFrom​(InputStream input)  
      static Message parseDelimitedFrom​(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)  
      static Message parseFrom​(byte[] data)  
      static Message parseFrom​(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)  
      static Message parseFrom​(com.google.protobuf.ByteString data)  
      static Message parseFrom​(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)  
      static Message parseFrom​(com.google.protobuf.CodedInputStream input)  
      static Message parseFrom​(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)  
      static Message parseFrom​(InputStream input)  
      static Message parseFrom​(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)  
      static Message parseFrom​(ByteBuffer data)  
      static Message parseFrom​(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)  
      static com.google.protobuf.Parser<Message> parser()  
      Message.Builder toBuilder()  
      void writeTo​(com.google.protobuf.CodedOutputStream output)  
      • Methods inherited from class com.google.protobuf.GeneratedMessageV3

        canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, isStringEmpty, makeExtensionsImmutable, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTag
      • Methods inherited from class com.google.protobuf.AbstractMessage

        findInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toString
      • Methods inherited from class com.google.protobuf.AbstractMessageLite

        addAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeTo
      • Methods inherited from interface com.google.protobuf.MessageLite

        toByteArray, toByteString, writeDelimitedTo, writeTo
      • Methods inherited from interface com.google.protobuf.MessageOrBuilder

        findInitializationErrors, getAllFields, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
    • Method Detail

      • newInstance

        protected Object newInstance​(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
        Overrides:
        newInstance in class com.google.protobuf.GeneratedMessageV3
      • getDescriptor

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

        protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection​(int number)
        Overrides:
        internalGetMapFieldReflection in class com.google.protobuf.GeneratedMessageV3
      • internalGetFieldAccessorTable

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

        public String getId()
         ID is an unique identifier inside a queue.
         Any message with the same id and queue will be considered the same message.
         
        string id = 1;
        Specified by:
        getId in interface MessageOrBuilder
        Returns:
        The id.
      • getIdBytes

        public com.google.protobuf.ByteString getIdBytes()
         ID is an unique identifier inside a queue.
         Any message with the same id and queue will be considered the same message.
         
        string id = 1;
        Specified by:
        getIdBytes in interface MessageOrBuilder
        Returns:
        The bytes for id.
      • getDescription

        public String getDescription()
         Description of the message, this should be used as a human readable string to be used in diagnostics.
         
        string description = 2;
        Specified by:
        getDescription in interface MessageOrBuilder
        Returns:
        The description.
      • getDescriptionBytes

        public com.google.protobuf.ByteString getDescriptionBytes()
         Description of the message, this should be used as a human readable string to be used in diagnostics.
         
        string description = 2;
        Specified by:
        getDescriptionBytes in interface MessageOrBuilder
        Returns:
        The bytes for description.
      • getQueue

        public String getQueue()
         Full name of the queue this message belongs (including any prefixes)
         
        string queue = 3;
        Specified by:
        getQueue in interface MessageOrBuilder
        Returns:
        The queue.
      • getQueueBytes

        public com.google.protobuf.ByteString getQueueBytes()
         Full name of the queue this message belongs (including any prefixes)
         
        string queue = 3;
        Specified by:
        getQueueBytes in interface MessageOrBuilder
        Returns:
        The bytes for queue.
      • getPayloadCount

        public int getPayloadCount()
        Description copied from interface: MessageOrBuilder
         A payload map with formatted data to be stored and used by clients.
         
        map<string, .google.protobuf.Any> payload = 8;
        Specified by:
        getPayloadCount in interface MessageOrBuilder
      • containsPayload

        public boolean containsPayload​(String key)
         A payload map with formatted data to be stored and used by clients.
         
        map<string, .google.protobuf.Any> payload = 8;
        Specified by:
        containsPayload in interface MessageOrBuilder
      • getPayloadMap

        public Map<String,​com.google.protobuf.Any> getPayloadMap()
         A payload map with formatted data to be stored and used by clients.
         
        map<string, .google.protobuf.Any> payload = 8;
        Specified by:
        getPayloadMap in interface MessageOrBuilder
      • getPayloadOrDefault

        public com.google.protobuf.Any getPayloadOrDefault​(String key,
                                                           com.google.protobuf.Any defaultValue)
         A payload map with formatted data to be stored and used by clients.
         
        map<string, .google.protobuf.Any> payload = 8;
        Specified by:
        getPayloadOrDefault in interface MessageOrBuilder
      • getPayloadOrThrow

        public com.google.protobuf.Any getPayloadOrThrow​(String key)
         A payload map with formatted data to be stored and used by clients.
         
        map<string, .google.protobuf.Any> payload = 8;
        Specified by:
        getPayloadOrThrow in interface MessageOrBuilder
      • getMetadataCount

        public int getMetadataCount()
        Description copied from interface: MessageOrBuilder
         Metadata is a map of string to be used as a key-value store.
         It is a simple way to store data that is not part of the message payload.
         
        map<string, string> metadata = 4;
        Specified by:
        getMetadataCount in interface MessageOrBuilder
      • containsMetadata

        public boolean containsMetadata​(String key)
         Metadata is a map of string to be used as a key-value store.
         It is a simple way to store data that is not part of the message payload.
         
        map<string, string> metadata = 4;
        Specified by:
        containsMetadata in interface MessageOrBuilder
      • getMetadataMap

        public Map<String,​String> getMetadataMap()
         Metadata is a map of string to be used as a key-value store.
         It is a simple way to store data that is not part of the message payload.
         
        map<string, string> metadata = 4;
        Specified by:
        getMetadataMap in interface MessageOrBuilder
      • getMetadataOrDefault

        public String getMetadataOrDefault​(String key,
                                           String defaultValue)
         Metadata is a map of string to be used as a key-value store.
         It is a simple way to store data that is not part of the message payload.
         
        map<string, string> metadata = 4;
        Specified by:
        getMetadataOrDefault in interface MessageOrBuilder
      • getMetadataOrThrow

        public String getMetadataOrThrow​(String key)
         Metadata is a map of string to be used as a key-value store.
         It is a simple way to store data that is not part of the message payload.
         
        map<string, string> metadata = 4;
        Specified by:
        getMetadataOrThrow in interface MessageOrBuilder
      • getStringPayload

        public String getStringPayload()
         Message string payload. Is responsibility of the caller to know how to encode/decode to a useful format for its purpose.
         This field can be used to store simple string data instead of using the payload field.
         
        string string_payload = 5;
        Specified by:
        getStringPayload in interface MessageOrBuilder
        Returns:
        The stringPayload.
      • getStringPayloadBytes

        public com.google.protobuf.ByteString getStringPayloadBytes()
         Message string payload. Is responsibility of the caller to know how to encode/decode to a useful format for its purpose.
         This field can be used to store simple string data instead of using the payload field.
         
        string string_payload = 5;
        Specified by:
        getStringPayloadBytes in interface MessageOrBuilder
        Returns:
        The bytes for stringPayload.
      • getScore

        public double getScore()
         Score represents the priority score the message currently have in the queue.
         The lower the score, the higher the priority.
         The maximum score accepted by Deckard is 9007199254740992 and the minimum is 0
         
        double score = 6;
        Specified by:
        getScore in interface MessageOrBuilder
        Returns:
        The score.
      • getBreakpoint

        public String getBreakpoint()
         Breakpoint is a field to be used as an auxiliar field for some specific use cases.
         For example if you need to keep a record of the last result processing a message, or want to iteract with a pagination system.
        
         Examples: imagine a message representing a web news portal and you want to navigate through the articles. This field could be used to store the last visited article id.
         Or imagine a message representing a user and you want to iterate through the user's publications pages. This field could be used to store the last page number you visited.
         
        string breakpoint = 7;
        Specified by:
        getBreakpoint in interface MessageOrBuilder
        Returns:
        The breakpoint.
      • getBreakpointBytes

        public com.google.protobuf.ByteString getBreakpointBytes()
         Breakpoint is a field to be used as an auxiliar field for some specific use cases.
         For example if you need to keep a record of the last result processing a message, or want to iteract with a pagination system.
        
         Examples: imagine a message representing a web news portal and you want to navigate through the articles. This field could be used to store the last visited article id.
         Or imagine a message representing a user and you want to iterate through the user's publications pages. This field could be used to store the last page number you visited.
         
        string breakpoint = 7;
        Specified by:
        getBreakpointBytes in interface MessageOrBuilder
        Returns:
        The bytes for breakpoint.
      • hasDiagnostics

        public boolean hasDiagnostics()
         Diagnostics is a field holding information about the message's usage.
         It is useful to track how many times a message was ACKed or NACKed.
         
        .blipai.deckard.MessageDiagnostics diagnostics = 9;
        Specified by:
        hasDiagnostics in interface MessageOrBuilder
        Returns:
        Whether the diagnostics field is set.
      • getDiagnostics

        public MessageDiagnostics getDiagnostics()
         Diagnostics is a field holding information about the message's usage.
         It is useful to track how many times a message was ACKed or NACKed.
         
        .blipai.deckard.MessageDiagnostics diagnostics = 9;
        Specified by:
        getDiagnostics in interface MessageOrBuilder
        Returns:
        The diagnostics.
      • getDiagnosticsOrBuilder

        public MessageDiagnosticsOrBuilder getDiagnosticsOrBuilder()
         Diagnostics is a field holding information about the message's usage.
         It is useful to track how many times a message was ACKed or NACKed.
         
        .blipai.deckard.MessageDiagnostics diagnostics = 9;
        Specified by:
        getDiagnosticsOrBuilder in interface MessageOrBuilder
      • 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 Message parseFrom​(ByteBuffer data)
                                 throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

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

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

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

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

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

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

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

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

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

        public static Message getDefaultInstance()
      • parser

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

        public com.google.protobuf.Parser<Message> 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 Message getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder