class Genomer::OutputType::Genbank < Genomer::OutputType

  SUFFIX = 'gb'

  def generate
    build = Bio::Sequence.new(sequence)
    build.entry_id = @rules.identifier if @rules.identifier
    build.definition = @rules.description if @rules.description
    build.output(:genbank)
  end

end

class Genomer::OutputType::Genbank < Genomer::OutputType

  SUFFIX = 'gb'

  METADATA_MAP = {
    :entry_id => :identifier,
    :definition => :description
  }

  def generate
    build = Bio::Sequence.new(sequence)
    METADATA_MAP.each do |a,b|
      value = @rules.send(b)
      build.send(a.to_s + '=',value) unless value.nil?
    end
    build.output(:genbank)
  end

end

Refactor method for setting metadata
Refactor method for setting metadata
