Class: Bio::FlatFile::Splitter::Template

Inherits:
Object
  • Object
show all
Defined in:
lib/bio/io/flatfile.rb

Overview

This is a template of splitter.

Direct Known Subclasses

Default

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(klass, bstream) ⇒ Template

Creates a new splitter.

Raises:

  • (NotImplementedError)


246
247
248
249
# File 'lib/bio/io/flatfile.rb', line 246

def initialize(klass, bstream)
  @stream = bstream
  raise NotImplementedError
end

Instance Attribute Details

#entryObject (readonly)

the last entry read from the stream



262
263
264
# File 'lib/bio/io/flatfile.rb', line 262

def entry
  @entry
end

#entry_ended_posObject (readonly)

(end position of the entry) + 1



271
272
273
# File 'lib/bio/io/flatfile.rb', line 271

def entry_ended_pos
  @entry_ended_pos
end

#entry_pos_flagObject

a flag to write down entry start and end positions



265
266
267
# File 'lib/bio/io/flatfile.rb', line 265

def entry_pos_flag
  @entry_pos_flag
end

#entry_start_posObject (readonly)

start position of the entry



268
269
270
# File 'lib/bio/io/flatfile.rb', line 268

def entry_start_pos
  @entry_start_pos
end

Instance Method Details

#get_entryObject

Gets entry as a string

Raises:

  • (NotImplementedError)


257
258
259
# File 'lib/bio/io/flatfile.rb', line 257

def get_entry
  raise NotImplementedError
end

#skip_leaderObject

skips leader of the entry.

Raises:

  • (NotImplementedError)


252
253
254
# File 'lib/bio/io/flatfile.rb', line 252

def skip_leader
  raise NotImplementedError
end