Class SegmentKey

java.lang.Object
org.yamcs.parameterarchive.SegmentKey

public class SegmentKey extends Object
Holder, encoder and decoder for the segment keys (in the sense of key,value storage used for RocksDb)
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final byte
     
    static final byte
     
    static final byte
     
    static final byte
     
  • Constructor Summary

    Constructors
    Constructor
    Description
    SegmentKey(int parameterId, int parameterGroupId, long segmentStart, byte type)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static SegmentKey
    decode(byte[] b)
    Key decode in Yamcs starting with 5.10 - we use the invertSign for the timestamps in order for the negative times to sort before the positive ones in the archive
    static SegmentKey
    decodeV0(byte[] b)
    Version 0 is prior to Yamcs 5.10 when the negative times were not sorting properly
    byte[]
    Key encode in Yamcs starting with 5.10 - we use the invertSign for the timestamps in order for the negative times to sort before the positive ones in the archive
    static byte[]
    encode(int parameterId, int parameterGroupId, long segmentStart, byte type)
    Key encode in Yamcs starting with 5.10 - we use the invertSign for the timestamps in order for the negative times to sort before the positive ones in the archive
    byte[]
    Version 0 is prior to Yamcs 5.10 when the negative times were not sorting properly
    static byte[]
    encodeV0(int parameterId, int parameterGroupId, long segmentStart, byte type)
    Version 0 is prior to Yamcs 5.10 when the negative times were not sorting properly
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Field Details

  • Constructor Details

    • SegmentKey

      public SegmentKey(int parameterId, int parameterGroupId, long segmentStart, byte type)
  • Method Details

    • encode

      public byte[] encode()
      Key encode in Yamcs starting with 5.10 - we use the invertSign for the timestamps in order for the negative times to sort before the positive ones in the archive
    • decode

      public static SegmentKey decode(byte[] b)
      Key decode in Yamcs starting with 5.10 - we use the invertSign for the timestamps in order for the negative times to sort before the positive ones in the archive
    • encode

      public static byte[] encode(int parameterId, int parameterGroupId, long segmentStart, byte type)
      Key encode in Yamcs starting with 5.10 - we use the invertSign for the timestamps in order for the negative times to sort before the positive ones in the archive
    • encodeV0

      public byte[] encodeV0()
      Version 0 is prior to Yamcs 5.10 when the negative times were not sorting properly
    • decodeV0

      public static SegmentKey decodeV0(byte[] b)
      Version 0 is prior to Yamcs 5.10 when the negative times were not sorting properly
    • encodeV0

      public static byte[] encodeV0(int parameterId, int parameterGroupId, long segmentStart, byte type)
      Version 0 is prior to Yamcs 5.10 when the negative times were not sorting properly
    • toString

      public String toString()
      Overrides:
      toString in class Object