Class: GoogleBook::Book
- Inherits:
-
Struct
- Object
- Struct
- GoogleBook::Book
- Defined in:
- lib/googlebook/book.rb
Instance Attribute Summary collapse
-
#creator ⇒ Object
Returns the value of attribute creator.
-
#date ⇒ Object
Returns the value of attribute date.
-
#description ⇒ Object
Returns the value of attribute description.
-
#format ⇒ Object
Returns the value of attribute format.
-
#identifier ⇒ Object
Returns the value of attribute identifier.
-
#images ⇒ Object
Returns the value of attribute images.
-
#info ⇒ Object
Returns the value of attribute info.
-
#preview ⇒ Object
Returns the value of attribute preview.
-
#publisher ⇒ Object
Returns the value of attribute publisher.
-
#subject ⇒ Object
Returns the value of attribute subject.
-
#title ⇒ Object
Returns the value of attribute title.
Instance Method Summary collapse
-
#initialize(args = {}) ⇒ Book
constructor
A new instance of Book.
- #isbn ⇒ Object
Constructor Details
#initialize(args = {}) ⇒ Book
Returns a new instance of Book.
14 15 16 |
# File 'lib/googlebook/book.rb', line 14 def initialize(args={}) args.each { |k, v| self.send "#{k}=", v } end |
Instance Attribute Details
#creator ⇒ Object
Returns the value of attribute creator
2 3 4 |
# File 'lib/googlebook/book.rb', line 2 def creator @creator end |
#date ⇒ Object
Returns the value of attribute date
2 3 4 |
# File 'lib/googlebook/book.rb', line 2 def date @date end |
#description ⇒ Object
Returns the value of attribute description
2 3 4 |
# File 'lib/googlebook/book.rb', line 2 def description @description end |
#format ⇒ Object
Returns the value of attribute format
2 3 4 |
# File 'lib/googlebook/book.rb', line 2 def format @format end |
#identifier ⇒ Object
Returns the value of attribute identifier
2 3 4 |
# File 'lib/googlebook/book.rb', line 2 def identifier @identifier end |
#images ⇒ Object
Returns the value of attribute images
2 3 4 |
# File 'lib/googlebook/book.rb', line 2 def images @images end |
#info ⇒ Object
Returns the value of attribute info
2 3 4 |
# File 'lib/googlebook/book.rb', line 2 def info @info end |
#preview ⇒ Object
Returns the value of attribute preview
2 3 4 |
# File 'lib/googlebook/book.rb', line 2 def preview @preview end |
#publisher ⇒ Object
Returns the value of attribute publisher
2 3 4 |
# File 'lib/googlebook/book.rb', line 2 def publisher @publisher end |
#subject ⇒ Object
Returns the value of attribute subject
2 3 4 |
# File 'lib/googlebook/book.rb', line 2 def subject @subject end |
#title ⇒ Object
Returns the value of attribute title
2 3 4 |
# File 'lib/googlebook/book.rb', line 2 def title @title end |
Instance Method Details
#isbn ⇒ Object
18 19 20 |
# File 'lib/googlebook/book.rb', line 18 def isbn @isbn ||= find_isbn end |