Class Protocol.Command

  • All Implemented Interfaces:
    com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, Protocol.CommandOrBuilder
    Enclosing class:
    Protocol

    public static final class Protocol.Command
    extends com.google.protobuf.GeneratedMessageLite<Protocol.Command,​Protocol.Command.Builder>
    implements Protocol.CommandOrBuilder
     Command sent from a client to a server.
     ProtocolVersion1 uses id, method and params fields.
     ProtocolVersion2 uses id and one of the possible request messages.
     
    Protobuf type centrifugal.centrifuge.protocol.Command
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  Protocol.Command.Builder
      Command sent from a client to a server.
      static class  Protocol.Command.MethodType
      Protobuf enum centrifugal.centrifuge.protocol.Command.MethodType
      • 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 java.lang.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
    • Method Detail

      • getId

        public int getId()
         Id of command to let client match replies to commands.
         
        uint32 id = 1;
        Specified by:
        getId in interface Protocol.CommandOrBuilder
        Returns:
        The id.
      • getMethodValue

        public int getMethodValue()
         Method is used in ProtocolVersion1 only.
         
        .centrifugal.centrifuge.protocol.Command.MethodType method = 2;
        Specified by:
        getMethodValue in interface Protocol.CommandOrBuilder
        Returns:
        The enum numeric value on the wire for method.
      • getParams

        public com.google.protobuf.ByteString getParams()
         Params is used in ProtocolVersion1 only.
         
        bytes params = 3;
        Specified by:
        getParams in interface Protocol.CommandOrBuilder
        Returns:
        The params.
      • hasConnect

        public boolean hasConnect()
         ProtocolVersion2 client can send one of the following requests. Server will
         only take the first non-null request out of these and may return an error if
         client passed more than one request. We are not using oneof here due to JSON
         interoperability concerns.
         
        .centrifugal.centrifuge.protocol.ConnectRequest connect = 4;
        Specified by:
        hasConnect in interface Protocol.CommandOrBuilder
        Returns:
        Whether the connect field is set.
      • getConnect

        public Protocol.ConnectRequest getConnect()
         ProtocolVersion2 client can send one of the following requests. Server will
         only take the first non-null request out of these and may return an error if
         client passed more than one request. We are not using oneof here due to JSON
         interoperability concerns.
         
        .centrifugal.centrifuge.protocol.ConnectRequest connect = 4;
        Specified by:
        getConnect in interface Protocol.CommandOrBuilder
        Returns:
        The connect.
      • hasSubscribe

        public boolean hasSubscribe()
        .centrifugal.centrifuge.protocol.SubscribeRequest subscribe = 5;
        Specified by:
        hasSubscribe in interface Protocol.CommandOrBuilder
        Returns:
        Whether the subscribe field is set.
      • hasUnsubscribe

        public boolean hasUnsubscribe()
        .centrifugal.centrifuge.protocol.UnsubscribeRequest unsubscribe = 6;
        Specified by:
        hasUnsubscribe in interface Protocol.CommandOrBuilder
        Returns:
        Whether the unsubscribe field is set.
      • hasPublish

        public boolean hasPublish()
        .centrifugal.centrifuge.protocol.PublishRequest publish = 7;
        Specified by:
        hasPublish in interface Protocol.CommandOrBuilder
        Returns:
        Whether the publish field is set.
      • hasPresence

        public boolean hasPresence()
        .centrifugal.centrifuge.protocol.PresenceRequest presence = 8;
        Specified by:
        hasPresence in interface Protocol.CommandOrBuilder
        Returns:
        Whether the presence field is set.
      • hasPresenceStats

        public boolean hasPresenceStats()
        .centrifugal.centrifuge.protocol.PresenceStatsRequest presence_stats = 9;
        Specified by:
        hasPresenceStats in interface Protocol.CommandOrBuilder
        Returns:
        Whether the presenceStats field is set.
      • hasHistory

        public boolean hasHistory()
        .centrifugal.centrifuge.protocol.HistoryRequest history = 10;
        Specified by:
        hasHistory in interface Protocol.CommandOrBuilder
        Returns:
        Whether the history field is set.
      • hasPing

        public boolean hasPing()
        .centrifugal.centrifuge.protocol.PingRequest ping = 11;
        Specified by:
        hasPing in interface Protocol.CommandOrBuilder
        Returns:
        Whether the ping field is set.
      • hasSend

        public boolean hasSend()
        .centrifugal.centrifuge.protocol.SendRequest send = 12;
        Specified by:
        hasSend in interface Protocol.CommandOrBuilder
        Returns:
        Whether the send field is set.
      • hasRpc

        public boolean hasRpc()
        .centrifugal.centrifuge.protocol.RPCRequest rpc = 13;
        Specified by:
        hasRpc in interface Protocol.CommandOrBuilder
        Returns:
        Whether the rpc field is set.
      • hasRefresh

        public boolean hasRefresh()
        .centrifugal.centrifuge.protocol.RefreshRequest refresh = 14;
        Specified by:
        hasRefresh in interface Protocol.CommandOrBuilder
        Returns:
        Whether the refresh field is set.
      • hasSubRefresh

        public boolean hasSubRefresh()
        .centrifugal.centrifuge.protocol.SubRefreshRequest sub_refresh = 15;
        Specified by:
        hasSubRefresh in interface Protocol.CommandOrBuilder
        Returns:
        Whether the subRefresh field is set.
      • parseFrom

        public static Protocol.Command parseFrom​(java.nio.ByteBuffer data)
                                          throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

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

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

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

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

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

        public static Protocol.Command parseFrom​(java.io.InputStream input)
                                          throws java.io.IOException
        Throws:
        java.io.IOException
      • parseFrom

        public static Protocol.Command parseFrom​(java.io.InputStream input,
                                                 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                          throws java.io.IOException
        Throws:
        java.io.IOException
      • parseDelimitedFrom

        public static Protocol.Command parseDelimitedFrom​(java.io.InputStream input)
                                                   throws java.io.IOException
        Throws:
        java.io.IOException
      • parseDelimitedFrom

        public static Protocol.Command parseDelimitedFrom​(java.io.InputStream input,
                                                          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                                   throws java.io.IOException
        Throws:
        java.io.IOException
      • parseFrom

        public static Protocol.Command parseFrom​(com.google.protobuf.CodedInputStream input)
                                          throws java.io.IOException
        Throws:
        java.io.IOException
      • parseFrom

        public static Protocol.Command parseFrom​(com.google.protobuf.CodedInputStream input,
                                                 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                          throws java.io.IOException
        Throws:
        java.io.IOException
      • dynamicMethod

        protected final java.lang.Object dynamicMethod​(com.google.protobuf.GeneratedMessageLite.MethodToInvoke method,
                                                       java.lang.Object arg0,
                                                       java.lang.Object arg1)
        Specified by:
        dynamicMethod in class com.google.protobuf.GeneratedMessageLite<Protocol.Command,​Protocol.Command.Builder>