Package 

Interface DataMerger

    • Method Summary

      Modifier and Type Method Description
      abstract boolean merge(@NonNull() DataStream output, @Nullable() Array<byte> lastPacket, @IntRange(from = 0) int index) This method should merge the last packet into the output message.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • merge

         abstract boolean merge(@NonNull() DataStream output, @Nullable() Array<byte> lastPacket, @IntRange(from = 0) int index)

        This method should merge the last packet into the output message.

        Parameters:
        output - the stream for the output message, initially empty.
        lastPacket - the data received in the last read/notify/indicate operation.
        index - an index of the packet, 0-based (if you expect 3 packets, they will becalled with indexes 0, 1, 2).