Class: Relaton::Processor

Inherits:
Object
  • Object
show all
Defined in:
lib/relaton/processor.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeProcessor

Returns a new instance of Processor.


8
9
10
# File 'lib/relaton/processor.rb', line 8

def initialize
  raise "This is an abstract class!"
end

Instance Attribute Details

#defaultprefixObject (readonly)

Returns the value of attribute defaultprefix


5
6
7
# File 'lib/relaton/processor.rb', line 5

def defaultprefix
  @defaultprefix
end

#idtypeObject (readonly)

Returns the value of attribute idtype


6
7
8
# File 'lib/relaton/processor.rb', line 6

def idtype
  @idtype
end

#prefixObject (readonly)

Returns the value of attribute prefix


4
5
6
# File 'lib/relaton/processor.rb', line 4

def prefix
  @prefix
end

#shortObject (readonly)

Returns the value of attribute short


3
4
5
# File 'lib/relaton/processor.rb', line 3

def short
  @short
end

Instance Method Details

#from_xml(_xml) ⇒ Object


16
17
18
# File 'lib/relaton/processor.rb', line 16

def from_xml(_xml)
  raise "This is an abstract class!"
end

#get(_code, _date, _opts) ⇒ Object


12
13
14
# File 'lib/relaton/processor.rb', line 12

def get(_code, _date, _opts)
  raise "This is an abstract class!"
end

#grammar_hashObject


24
25
26
# File 'lib/relaton/processor.rb', line 24

def grammar_hash
  raise "This is an abstract class!"
end

#hash_to_bib(_hash) ⇒ Object


20
21
22
# File 'lib/relaton/processor.rb', line 20

def hash_to_bib(_hash)
  raise "This is an abstract class!"
end

#threadsInteger

Retuns default number of workers. Should be overraded by childred classes if need.

Returns:

  • (Integer)

    nuber of wokrers


31
32
33
# File 'lib/relaton/processor.rb', line 31

def threads
  10
end