Class: Aladin::Book
- Inherits:
-
OpenStruct
- Object
- OpenStruct
- Aladin::Book
- Defined in:
- lib/aladin/book.rb
Instance Method Summary collapse
-
#initialize(hash = {}) ⇒ Book
constructor
A new instance of Book.
Constructor Details
#initialize(hash = {}) ⇒ Book
Returns a new instance of Book.
3 4 5 6 7 8 |
# File 'lib/aladin/book.rb', line 3 def initialize(hash = {}) super(nil) hash.each do |key, value| send("#{key.to_s.underscore}=", value) end end |