Interface GFFRecord

  • All Known Implementing Classes:
    SimpleGFFRecord

    public interface GFFRecord
    A single GFF record.

    This object has fields for each GFF field. It also defines a couple of useful constants.

    GFF is described at http://www.sanger.ac.uk/Software/formats/GFF/

    Author:
    Matthew Pocock, Keith James (docs)
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.util.Comparator NATURAL_ORDER
      Comparator which defines a useful sort order for GFF records.
      static int NO_FRAME
      Deprecated.
      Use GFFTools.NO_FRAME instead
      static double NO_SCORE
      Deprecated.
      Use GFFTools.NO_SCORE instead
    • Field Detail

      • NO_SCORE

        static final double NO_SCORE
        Deprecated.
        Use GFFTools.NO_SCORE instead
        Flag to indicate that there is no score info.
      • NO_FRAME

        static final int NO_FRAME
        Deprecated.
        Use GFFTools.NO_FRAME instead
        Flag to indicate that there is no frame info.
      • NATURAL_ORDER

        static final java.util.Comparator NATURAL_ORDER
        Comparator which defines a useful sort order for GFF records. GFFRecord properties are considered in the following order
        1. Sequence name
        2. Feature start
        3. Feature end
        4. Feature type
        5. Feature source
        6. The complete GFF line corresponding to this record

        Two records are equal iff their GFF lines are character-for-character identical.

        Since:
        1.4
    • Method Detail

      • getSeqName

        java.lang.String getSeqName()
        The sequence name field.

        This should be the name of the sequence that this GFF record is within.

        Returns:
        the name of the sequence
      • getSource

        java.lang.String getSource()
        The source, or creator of this feature.

        This is usualy a program name.

        Returns:
        the feature source
      • getFeature

        java.lang.String getFeature()
        The feature type filed.

        This is something like "exon" - usualy corresponds to an EMBL term.

        Returns:
        the feature type
      • getStart

        int getStart()
        The start of this feature within the source sequence.
        Returns:
        the start index
      • getEnd

        int getEnd()
        The end of this feature within the source sequence.
        Returns:
        the end index
      • getScore

        double getScore()
        The score of the feature.

        For sequences that have no score, this will be set to GFFRecord.NO_SCORE.

        Returns:
        the score, or NO_SCORE
      • getStrand

        StrandedFeature.Strand getStrand()
        The strand of the feature.

        This will be one of GFFRecord.POSITIVE_STRAND, GFFRecord.NEGATIVE_STRAND, or GFFRecord.NO_STRAND.

        Returns:
        the strand field
      • getFrame

        int getFrame()
        The frame of the feature.

        This will be one of {1, 2, 3} or GFFRecord.NO_FRAME.

        Returns:
        the frame field
      • getGroupAttributes

        java.util.Map getGroupAttributes()
        A Map containing the group / attribute information.

        This will be a Map of group-names to List objects.

        Returns:
        a Map containing the group and attribute info.
      • getComment

        java.lang.String getComment()
        The feature comment.
        Returns:
        null or the feature comment