Represents version 2 of GFF specification. Its behavior is somehow different from Bio::GFF, especially for attributes.
Metadata (except "#gff-version"). Must be an array of Bio::GFF::GFF2::MetaData objects.
Creates a Bio::GFF::GFF2 object by building a collection of Bio::GFF::GFF2::Record (and metadata) objects.
Arguments:
str: string in GFF format
Returns |
Bio::GFF::GFF2 object |
# File lib/bio/db/gff.rb, line 823 def initialize(str = nil) @gff_version = nil @records = [] @metadata = [] parse(str) if str end
Parses a GFF2 entries, and concatenated the parsed data.
Arguments:
str: string in GFF format
Returns |
self |
# File lib/bio/db/gff.rb, line 843 def parse(str) # parses GFF lines str.each_line do |line| if /^\#\#([^\s]+)/ =~ line then parse_metadata($1, line) else @records << GFF2::Record.new(line) end end self end
Generated with the Darkfish Rdoc Generator 2.