Class ProtobufCommands.ProtobufCommand

java.lang.Object
us.hebi.quickbuf.ProtoMessage<ProtobufCommands.ProtobufCommand>
org.wpilib.command3.proto.ProtobufCommands.ProtobufCommand
All Implemented Interfaces:
Cloneable
Enclosing class:
ProtobufCommands

public static final class ProtobufCommands.ProtobufCommand extends us.hebi.quickbuf.ProtoMessage<ProtobufCommands.ProtobufCommand> implements Cloneable
Protobuf type ProtobufCommand
  • Method Details

    • newInstance

      public static ProtobufCommands.ProtobufCommand newInstance()
      Returns:
      a new empty instance of ProtobufCommand
    • hasLastTimeMs

      public boolean hasLastTimeMs()
       How much time the command took to execute in its most recent run.
       Only included in a message for an actively running command.
      
      optional double last_time_ms = 6;
      Returns:
      whether the lastTimeMs field is set
    • clearLastTimeMs

      public ProtobufCommands.ProtobufCommand clearLastTimeMs()
       How much time the command took to execute in its most recent run.
       Only included in a message for an actively running command.
      
      optional double last_time_ms = 6;
      Returns:
      this
    • getLastTimeMs

      public double getLastTimeMs()
       How much time the command took to execute in its most recent run.
       Only included in a message for an actively running command.
      
      optional double last_time_ms = 6;
      Returns:
      the lastTimeMs
    • setLastTimeMs

      public ProtobufCommands.ProtobufCommand setLastTimeMs(double value)
       How much time the command took to execute in its most recent run.
       Only included in a message for an actively running command.
      
      optional double last_time_ms = 6;
      Parameters:
      value - the lastTimeMs to set
      Returns:
      this
    • hasTotalTimeMs

      public boolean hasTotalTimeMs()
       How long the command has taken to run, in aggregate.
       Only included in a message for an actively running command.
      
      optional double total_time_ms = 7;
      Returns:
      whether the totalTimeMs field is set
    • clearTotalTimeMs

      public ProtobufCommands.ProtobufCommand clearTotalTimeMs()
       How long the command has taken to run, in aggregate.
       Only included in a message for an actively running command.
      
      optional double total_time_ms = 7;
      Returns:
      this
    • getTotalTimeMs

      public double getTotalTimeMs()
       How long the command has taken to run, in aggregate.
       Only included in a message for an actively running command.
      
      optional double total_time_ms = 7;
      Returns:
      the totalTimeMs
    • setTotalTimeMs

      public ProtobufCommands.ProtobufCommand setTotalTimeMs(double value)
       How long the command has taken to run, in aggregate.
       Only included in a message for an actively running command.
      
      optional double total_time_ms = 7;
      Parameters:
      value - the totalTimeMs to set
      Returns:
      this
    • hasPriority

      public boolean hasPriority()
       The priority level of the command.
      
      optional int32 priority = 4;
      Returns:
      whether the priority field is set
    • clearPriority

      public ProtobufCommands.ProtobufCommand clearPriority()
       The priority level of the command.
      
      optional int32 priority = 4;
      Returns:
      this
    • getPriority

      public int getPriority()
       The priority level of the command.
      
      optional int32 priority = 4;
      Returns:
      the priority
    • setPriority

      public ProtobufCommands.ProtobufCommand setPriority(int value)
       The priority level of the command.
      
      optional int32 priority = 4;
      Parameters:
      value - the priority to set
      Returns:
      this
    • hasId

      public boolean hasId()
       A unique ID for the command.
       Different invocations of the same command object have different IDs.
      
      optional uint32 id = 1;
      Returns:
      whether the id field is set
    • clearId

       A unique ID for the command.
       Different invocations of the same command object have different IDs.
      
      optional uint32 id = 1;
      Returns:
      this
    • getId

      public int getId()
       A unique ID for the command.
       Different invocations of the same command object have different IDs.
      
      optional uint32 id = 1;
      Returns:
      the id
    • setId

      public ProtobufCommands.ProtobufCommand setId(int value)
       A unique ID for the command.
       Different invocations of the same command object have different IDs.
      
      optional uint32 id = 1;
      Parameters:
      value - the id to set
      Returns:
      this
    • hasParentId

      public boolean hasParentId()
       The ID of the parent command.
       Not included in the message for top-level commands.
      
      optional uint32 parent_id = 2;
      Returns:
      whether the parentId field is set
    • clearParentId

      public ProtobufCommands.ProtobufCommand clearParentId()
       The ID of the parent command.
       Not included in the message for top-level commands.
      
      optional uint32 parent_id = 2;
      Returns:
      this
    • getParentId

      public int getParentId()
       The ID of the parent command.
       Not included in the message for top-level commands.
      
      optional uint32 parent_id = 2;
      Returns:
      the parentId
    • setParentId

      public ProtobufCommands.ProtobufCommand setParentId(int value)
       The ID of the parent command.
       Not included in the message for top-level commands.
      
      optional uint32 parent_id = 2;
      Parameters:
      value - the parentId to set
      Returns:
      this
    • hasName

      public boolean hasName()
       The name of the command.
      
      optional string name = 3;
      Returns:
      whether the name field is set
    • clearName

       The name of the command.
      
      optional string name = 3;
      Returns:
      this
    • getName

      public String getName()
       The name of the command.
      
      optional string name = 3;
      Returns:
      the name
    • getNameBytes

      public us.hebi.quickbuf.Utf8String getNameBytes()
       The name of the command.
      
      optional string name = 3;
      Returns:
      internal Utf8String representation of name for reading
    • getMutableNameBytes

      public us.hebi.quickbuf.Utf8String getMutableNameBytes()
       The name of the command.
      
      optional string name = 3;
      Returns:
      internal Utf8String representation of name for modifications
    • setName

       The name of the command.
      
      optional string name = 3;
      Parameters:
      value - the name to set
      Returns:
      this
    • setName

      public ProtobufCommands.ProtobufCommand setName(us.hebi.quickbuf.Utf8String value)
       The name of the command.
      
      optional string name = 3;
      Parameters:
      value - the name to set
      Returns:
      this
    • hasRequirements

      public boolean hasRequirements()
       The mechanisms required by the command.
      
      repeated .wpi.proto.ProtobufMechanism requirements = 5;
      Returns:
      whether the requirements field is set
    • clearRequirements

      public ProtobufCommands.ProtobufCommand clearRequirements()
       The mechanisms required by the command.
      
      repeated .wpi.proto.ProtobufMechanism requirements = 5;
      Returns:
      this
    • getRequirements

      public us.hebi.quickbuf.RepeatedMessage<ProtobufCommands.ProtobufMechanism> getRequirements()
       The mechanisms required by the command.
      
      repeated .wpi.proto.ProtobufMechanism requirements = 5; This method returns the internal storage object without modifying any has state. The returned object should not be modified and be treated as read-only. Use getMutableRequirements() if you want to modify it.
      Returns:
      internal storage object for reading
    • getMutableRequirements

      public us.hebi.quickbuf.RepeatedMessage<ProtobufCommands.ProtobufMechanism> getMutableRequirements()
       The mechanisms required by the command.
      
      repeated .wpi.proto.ProtobufMechanism requirements = 5; This method returns the internal storage object and sets the corresponding has state. The returned object will become part of this message and its contents may be modified as long as the has state is not cleared.
      Returns:
      internal storage object for modifications
    • addRequirements

       The mechanisms required by the command.
      
      repeated .wpi.proto.ProtobufMechanism requirements = 5;
      Parameters:
      value - the requirements to add
      Returns:
      this
    • addAllRequirements

       The mechanisms required by the command.
      
      repeated .wpi.proto.ProtobufMechanism requirements = 5;
      Parameters:
      values - the requirements to add
      Returns:
      this
    • copyFrom

      Specified by:
      copyFrom in class us.hebi.quickbuf.ProtoMessage<ProtobufCommands.ProtobufCommand>
    • mergeFrom

      Overrides:
      mergeFrom in class us.hebi.quickbuf.ProtoMessage<ProtobufCommands.ProtobufCommand>
    • clear

      Specified by:
      clear in class us.hebi.quickbuf.ProtoMessage<ProtobufCommands.ProtobufCommand>
    • clearQuick

      public ProtobufCommands.ProtobufCommand clearQuick()
      Overrides:
      clearQuick in class us.hebi.quickbuf.ProtoMessage<ProtobufCommands.ProtobufCommand>
    • equals

      public boolean equals(Object o)
      Specified by:
      equals in class us.hebi.quickbuf.ProtoMessage<ProtobufCommands.ProtobufCommand>
    • writeTo

      public void writeTo(us.hebi.quickbuf.ProtoSink output) throws IOException
      Specified by:
      writeTo in class us.hebi.quickbuf.ProtoMessage<ProtobufCommands.ProtobufCommand>
      Throws:
      IOException
    • computeSerializedSize

      protected int computeSerializedSize()
      Specified by:
      computeSerializedSize in class us.hebi.quickbuf.ProtoMessage<ProtobufCommands.ProtobufCommand>
    • mergeFrom

      public ProtobufCommands.ProtobufCommand mergeFrom(us.hebi.quickbuf.ProtoSource input) throws IOException
      Specified by:
      mergeFrom in class us.hebi.quickbuf.ProtoMessage<ProtobufCommands.ProtobufCommand>
      Throws:
      IOException
    • writeTo

      public void writeTo(us.hebi.quickbuf.JsonSink output) throws IOException
      Overrides:
      writeTo in class us.hebi.quickbuf.ProtoMessage<ProtobufCommands.ProtobufCommand>
      Throws:
      IOException
    • mergeFrom

      public ProtobufCommands.ProtobufCommand mergeFrom(us.hebi.quickbuf.JsonSource input) throws IOException
      Overrides:
      mergeFrom in class us.hebi.quickbuf.ProtoMessage<ProtobufCommands.ProtobufCommand>
      Throws:
      IOException
    • clone

      Specified by:
      clone in class us.hebi.quickbuf.ProtoMessage<ProtobufCommands.ProtobufCommand>
    • isEmpty

      public boolean isEmpty()
      Overrides:
      isEmpty in class us.hebi.quickbuf.ProtoMessage<ProtobufCommands.ProtobufCommand>
    • parseFrom

      public static ProtobufCommands.ProtobufCommand parseFrom(byte[] data) throws us.hebi.quickbuf.InvalidProtocolBufferException
      Throws:
      us.hebi.quickbuf.InvalidProtocolBufferException
    • parseFrom

      public static ProtobufCommands.ProtobufCommand parseFrom(us.hebi.quickbuf.ProtoSource input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static ProtobufCommands.ProtobufCommand parseFrom(us.hebi.quickbuf.JsonSource input) throws IOException
      Throws:
      IOException
    • getFactory

      public static us.hebi.quickbuf.MessageFactory<ProtobufCommands.ProtobufCommand> getFactory()
      Returns:
      factory for creating ProtobufCommand messages
    • getDescriptor

      public static us.hebi.quickbuf.Descriptors.Descriptor getDescriptor()
      Returns:
      this type's descriptor.