Class: Exlibris::Aleph::Patron::Status

Inherits:
Object
  • Object
show all
Defined in:
lib/exlibris/aleph/patron/status.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(code, display = nil) ⇒ Status

Returns a new instance of Status.



7
8
9
10
# File 'lib/exlibris/aleph/patron/status.rb', line 7

def initialize(code, display=nil)
  @code = code
  @display = display
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



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

def code
  @code
end

#displayObject (readonly)

Returns the value of attribute display.



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

def display
  @display
end

Instance Method Details

#==(other_object) ⇒ Object Also known as: eql?



12
13
14
# File 'lib/exlibris/aleph/patron/status.rb', line 12

def ==(other_object)
  other_object.instance_of?(self.class) && code == other_object.code
end