Class BpSeq.Entry

    • Constructor Detail

      • Entry

        public Entry()
    • Method Detail

      • fromString

        public static BpSeq.Entry fromString​(String line)
        Parses a string into a BPSEQ entry. Expected format: int char int
        Parameters:
        line - A line containing a BPSEQ entry.
        Returns:
        An instance of this class.
      • index

        @Parameter(order=1)
        public abstract int index()
        Returns:
        The value of index column.
      • seq

        @Parameter(order=2)
        public abstract char seq()
        Returns:
        The value of sequence column.
      • pair

        @Parameter(order=3)
        public abstract int pair()
        Returns:
        The value of pair column.
      • comment

        @Default
        public String comment()
        Returns:
        The optional comment.
      • isPaired

        public boolean isPaired()
        Returns:
        True if pair column is non-zero.
      • contains

        public final boolean contains​(int index)
        Checks for a paired BPSEQ entry (i, j) if a given index k lies between them: i < k < j.
        Parameters:
        index - The index to check
        Returns:
        True if index lies between this entry and its pair.
      • length

        public final int length()
        Returns:
        The difference between pair column and index column or 0 for unpaired entries.