Class ProtobufMatrix
java.lang.Object
us.hebi.quickbuf.ProtoMessage<ProtobufMatrix>
org.wpilib.math.proto.ProtobufMatrix
- All Implemented Interfaces:
Cloneable
public final class ProtobufMatrix
extends us.hebi.quickbuf.ProtoMessage<ProtobufMatrix>
implements Cloneable
Protobuf type
ProtobufMatrix-
Field Summary
Fields inherited from class us.hebi.quickbuf.ProtoMessage
bitField0_, cachedSize, unknownBytesFieldName -
Method Summary
Modifier and TypeMethodDescriptionaddAllData(double... values) repeated double data = 3;addData(double value) repeated double data = 3;clear()repeated double data = 3;optional uint32 num_cols = 2;optional uint32 num_rows = 1;clone()protected intcopyFrom(ProtobufMatrix other) booleanus.hebi.quickbuf.RepeatedDoublegetData()repeated double data = 3;This method returns the internal storage object without modifying any has state.static us.hebi.quickbuf.Descriptors.Descriptorstatic us.hebi.quickbuf.MessageFactory<ProtobufMatrix> us.hebi.quickbuf.RepeatedDoublerepeated double data = 3;This method returns the internal storage object and sets the corresponding has state.intoptional uint32 num_cols = 2;intoptional uint32 num_rows = 1;booleanhasData()repeated double data = 3;booleanoptional uint32 num_cols = 2;booleanoptional uint32 num_rows = 1;booleanisEmpty()mergeFrom(ProtobufMatrix other) mergeFrom(us.hebi.quickbuf.JsonSource input) mergeFrom(us.hebi.quickbuf.ProtoSource input) static ProtobufMatrixstatic ProtobufMatrixparseFrom(byte[] data) static ProtobufMatrixparseFrom(us.hebi.quickbuf.JsonSource input) static ProtobufMatrixparseFrom(us.hebi.quickbuf.ProtoSource input) setNumCols(int value) optional uint32 num_cols = 2;setNumRows(int value) optional uint32 num_rows = 1;voidwriteTo(us.hebi.quickbuf.JsonSink output) voidwriteTo(us.hebi.quickbuf.ProtoSink output) Methods inherited from class us.hebi.quickbuf.ProtoMessage
bytesDefaultValue, checkInitialized, getCachedSize, getMissingFields, getMissingFields, getMissingFields, getMissingFields, getSerializedSize, getUnknownBytes, hashCode, isInitialized, mergeDelimitedFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, rethrowFromParent, toByteArray, toByteArray, toByteArray, toString, writeDelimitedTo
-
Method Details
-
newInstance
- Returns:
- a new empty instance of
ProtobufMatrix
-
hasNumRows
-
clearNumRows
-
getNumRows
-
setNumRows
optional uint32 num_rows = 1;- Parameters:
value- the numRows to set- Returns:
- this
-
hasNumCols
-
clearNumCols
-
getNumCols
-
setNumCols
optional uint32 num_cols = 2;- Parameters:
value- the numCols to set- Returns:
- this
-
hasData
-
clearData
-
getData
repeated double data = 3;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. UsegetMutableData()if you want to modify it.- Returns:
- internal storage object for reading
-
getMutableData
repeated double data = 3;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
-
addData
repeated double data = 3;- Parameters:
value- the data to add- Returns:
- this
-
addAllData
repeated double data = 3;- Parameters:
values- the data to add- Returns:
- this
-
copyFrom
- Specified by:
copyFromin classus.hebi.quickbuf.ProtoMessage<ProtobufMatrix>
-
mergeFrom
- Overrides:
mergeFromin classus.hebi.quickbuf.ProtoMessage<ProtobufMatrix>
-
clear
- Specified by:
clearin classus.hebi.quickbuf.ProtoMessage<ProtobufMatrix>
-
clearQuick
- Overrides:
clearQuickin classus.hebi.quickbuf.ProtoMessage<ProtobufMatrix>
-
equals
- Specified by:
equalsin classus.hebi.quickbuf.ProtoMessage<ProtobufMatrix>
-
writeTo
- Specified by:
writeToin classus.hebi.quickbuf.ProtoMessage<ProtobufMatrix>- Throws:
IOException
-
computeSerializedSize
- Specified by:
computeSerializedSizein classus.hebi.quickbuf.ProtoMessage<ProtobufMatrix>
-
mergeFrom
- Specified by:
mergeFromin classus.hebi.quickbuf.ProtoMessage<ProtobufMatrix>- Throws:
IOException
-
writeTo
- Overrides:
writeToin classus.hebi.quickbuf.ProtoMessage<ProtobufMatrix>- Throws:
IOException
-
mergeFrom
- Overrides:
mergeFromin classus.hebi.quickbuf.ProtoMessage<ProtobufMatrix>- Throws:
IOException
-
clone
- Specified by:
clonein classus.hebi.quickbuf.ProtoMessage<ProtobufMatrix>
-
isEmpty
- Overrides:
isEmptyin classus.hebi.quickbuf.ProtoMessage<ProtobufMatrix>
-
parseFrom
public static ProtobufMatrix parseFrom(byte[] data) throws us.hebi.quickbuf.InvalidProtocolBufferException - Throws:
us.hebi.quickbuf.InvalidProtocolBufferException
-
parseFrom
- Throws:
IOException
-
parseFrom
- Throws:
IOException
-
getFactory
- Returns:
- factory for creating ProtobufMatrix messages
-
getDescriptor
- Returns:
- this type's descriptor.
-