Class: Bio::Bam::SQLine

Inherits:
Object
  • Object
show all
Defined in:
lib/bio-sambamba/samheader.rb

Overview

Represents a @SQ line from SAM header

Instance Method Summary collapse

Constructor Details

#initialize(obj) ⇒ SQLine

Wrap MessagePack record from sambamba output



69
70
71
# File 'lib/bio-sambamba/samheader.rb', line 69

def initialize(obj)
  @obj = obj
end

Instance Method Details

#assemblyObject

Genome assembly identifier



84
85
86
# File 'lib/bio-sambamba/samheader.rb', line 84

def assembly
  @obj['AS']
end

#md5Object

MD5 checksum of the sequence in uppercase, with gaps and spaces removed



89
90
91
# File 'lib/bio-sambamba/samheader.rb', line 89

def md5
  @obj['M5']
end

#sequence_lengthObject

Reference sequence length



79
80
81
# File 'lib/bio-sambamba/samheader.rb', line 79

def sequence_length
  @obj['LN']
end

#sequence_nameObject

Reference sequence name



74
75
76
# File 'lib/bio-sambamba/samheader.rb', line 74

def sequence_name
  @obj['SN']
end

#speciesObject

Species



94
95
96
# File 'lib/bio-sambamba/samheader.rb', line 94

def species
  @obj['SP']
end

#uriObject

URI of the sequence



99
100
101
# File 'lib/bio-sambamba/samheader.rb', line 99

def uri
  @obj['UR']
end