module BioVcf::VcfRecordParser

Public Class Methods

get_format(s) click to toggle source

Parse the format field into a Hash

# File lib/bio-vcf/vcfrecord.rb, line 72
def VcfRecordParser.get_format s
  if s==$cached_sample_format_s
    $cached_sample_format
  else
    h = {}
    s.split(/:/).each_with_index { |v,i| h[v] = i }
    $cached_sample_format = h
    $cached_sample_format_s = s
    h
  end
end
get_info(s) click to toggle source
# File lib/bio-vcf/vcfrecord.rb, line 83
def VcfRecordParser.get_info s
  VcfRecordInfo.new(s)
end