java.lang.Object
org.yamcs.parameterarchive.BaseSegment
org.yamcs.parameterarchive.LongValueSegment
- All Implemented Interfaces:
ValueSegment
-
Field Summary
Fields inherited from class org.yamcs.parameterarchive.BaseSegment
FORMAT_ID_BinaryValueSegment, FORMAT_ID_BooleanValueSegment, FORMAT_ID_DoubleValueSegment, FORMAT_ID_FloatValueSegment, FORMAT_ID_GenericValueSegment, FORMAT_ID_IntValueSegment, FORMAT_ID_LongValueSegment, FORMAT_ID_ParameterStatusSegment, FORMAT_ID_SortedTimeValueSegment, FORMAT_ID_StringValueSegment, formatId -
Method Summary
Modifier and TypeMethodDescriptionvoidstatic LongValueSegmentconsolidate(List<Value> values, org.yamcs.protobuf.Yamcs.Value.Type type) intgetRange(int posStart, int posStop, boolean ascending) returns an array containing the values in the range [posStart, posStop) if ascending or [posStop, posStart) if descendinggetValue(int index) returns Value at position indexstatic LongValueSegmentparseFrom(ByteBuffer bb) intsize()voidwriteTo(ByteBuffer bb) Methods inherited from class org.yamcs.parameterarchive.BaseSegment
getFormatId, parseSegment
-
Method Details
-
writeTo
- Specified by:
writeToin classBaseSegment
-
parseFrom
- Throws:
DecodingException
-
consolidate
public static LongValueSegment consolidate(List<Value> values, org.yamcs.protobuf.Yamcs.Value.Type type) -
getMaxSerializedSize
public int getMaxSerializedSize()- Specified by:
getMaxSerializedSizein classBaseSegment- Returns:
- a high approximation for the serialized size in order to allocate a ByteBuffer big enough
-
getRange
Description copied from interface:ValueSegmentreturns an array containing the values in the range [posStart, posStop) if ascending or [posStop, posStart) if descending- Specified by:
getRangein interfaceValueSegment- Returns:
- an array containing the values in the specified range
-
getValue
Description copied from interface:ValueSegmentreturns Value at position index- Specified by:
getValuein interfaceValueSegment- Returns:
- the value at the index
-
size
public int size()- Specified by:
sizein interfaceValueSegment- Specified by:
sizein classBaseSegment
-
add
- Specified by:
addin interfaceValueSegment
-
consolidate
- Specified by:
consolidatein interfaceValueSegment
-