Class: Exlibris::Aleph::Record

Inherits:
Object
  • Object
show all
Defined in:
lib/exlibris/aleph/record.rb,
lib/exlibris/aleph/record/metadata.rb

Defined Under Namespace

Classes: Metadata

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(id) ⇒ Record

Returns a new instance of Record.



7
8
9
# File 'lib/exlibris/aleph/record.rb', line 7

def initialize(id)
  @id = id
end

Instance Attribute Details

#idObject (readonly)

Returns the value of attribute id.



5
6
7
# File 'lib/exlibris/aleph/record.rb', line 5

def id
  @id
end

Instance Method Details

#holdingsObject



15
16
17
# File 'lib/exlibris/aleph/record.rb', line 15

def holdings
  @holdings ||= Holdings.new(id).to_a
end

#itemsObject



19
20
21
# File 'lib/exlibris/aleph/record.rb', line 19

def items
  @items ||= Items.new(id).to_a
end

#metadataObject



11
12
13
# File 'lib/exlibris/aleph/record.rb', line 11

def 
  @metadata ||= Metadata.new(client.to_xml) unless client.error?
end