Class SeqnoRange


  • public class SeqnoRange
    extends Seqno
    Keeps track of a range of messages to be retransmitted. A bit set is used to represent missing messages. Every non-received message has a corresponding bit set to 0, every received message is 1.
    Author:
    Bela Ban
    • Constructor Detail

      • SeqnoRange

        public SeqnoRange​(long low,
                          long high)
    • Method Detail

      • getHigh

        public long getHigh()
      • contains

        public boolean contains​(long num)
        Overrides:
        contains in class Seqno
      • get

        public boolean get​(long num)
        Overrides:
        get in class Seqno
      • set

        public void set​(long num)
        Overrides:
        set in class Seqno
      • set

        public void set​(long... nums)
      • clear

        public void clear​(long num)
        Overrides:
        clear in class Seqno
      • clear

        public void clear​(long... nums)
      • size

        public int size()
        Overrides:
        size in class Seqno
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class Seqno
      • print

        public java.lang.String print()
        Overrides:
        print in class Seqno
      • getIndex

        protected int getIndex​(long num)
      • printBits

        public java.lang.String printBits​(boolean value)
      • getBits

        public java.util.Collection<Range> getBits​(boolean value)
        Returns ranges of all bit set to value
        Parameters:
        value - If true, returns all bits set to 1, else 0
        Returns: