Class: Bio::FlatFileIndex::Flat_1::SecondaryNameSpace

Inherits:
Template::NameSpace show all
Defined in:
lib/bio/io/flatfile/index.rb

Overview

secondary name space

Internal use only.

Instance Attribute Summary

Attributes inherited from Template::NameSpace

#dbname, #file, #name

Instance Method Summary collapse

Methods inherited from Template::NameSpace

#close, #include?, #initialize

Constructor Details

This class inherits a constructor from Bio::FlatFileIndex::Template::NameSpace

Instance Method Details

#filenameObject



1030
1031
1032
# File 'lib/bio/io/flatfile/index.rb', line 1030

def filename
  File.join(dbname, "id_#{name}.index")
end

#mapping(filename) ⇒ Object



1027
1028
1029
# File 'lib/bio/io/flatfile/index.rb', line 1027

def mapping(filename)
  FlatMappingFile.new(filename)
end

#search(key) ⇒ Object



1033
1034
1035
1036
1037
1038
# File 'lib/bio/io/flatfile/index.rb', line 1033

def search(key)
  r = super(key)
  file.close
  r.flatten!
  r
end