Class: Exlibris::Aleph::TabParser::TabSubLibrary

Inherits:
Base
  • Object
show all
Defined in:
lib/exlibris/aleph/tabs_parser/tab_sub_library.rb

Instance Attribute Summary

Attributes inherited from Base

#config_array, #config_hash, #file_name, #hash_key, #library, #local_file, #local_path, #pattern, #pattern_key

Instance Method Summary collapse

Methods inherited from Base

#to_a, #to_h

Constructor Details

#initialize(args) ⇒ TabSubLibrary

Returns a new instance of TabSubLibrary.



6
7
8
9
10
11
12
13
14
15
16
17
# File 'lib/exlibris/aleph/tabs_parser/tab_sub_library.rb', line 6

def initialize(args)
  args[:aleph_file_name] = "tab_sub_library.eng"
  args[:pattern] = /^(.{5})\s([1-6]{1})\s(.{5})\s([L,H,A,R,S]{1})\s(.{1,30})/
  args[:pattern_key] = {
    1  => :code, 
    2  => :type, 
    3  => :library, 
    5  => :text
  }
  args[:hash_key] = :code
  super(args)
end