Class: Blingee::Entry
- Inherits:
-
Object
- Object
- Blingee::Entry
- Defined in:
- lib/blingee/entry.rb
Overview
An entry contains details and Blingee::Image instances for a single entry found on Blingee.com.
Instance Attribute Summary collapse
-
#display_url ⇒ Object
readonly
Returns the value of attribute display_url.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#images ⇒ Object
readonly
Returns the value of attribute images.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
-
#initialize(attributes = {}) ⇒ Entry
constructor
A new instance of Entry.
Constructor Details
#initialize(attributes = {}) ⇒ Entry
Returns a new instance of Entry.
11 12 13 14 15 16 |
# File 'lib/blingee/entry.rb', line 11 def initialize(attributes = {}) @display_url = attributes[:display_url] @id = attributes[:id].to_i @images = collect_images(attributes[:images]) @name = attributes[:name] end |
Instance Attribute Details
#display_url ⇒ Object (readonly)
Returns the value of attribute display_url.
9 10 11 |
# File 'lib/blingee/entry.rb', line 9 def display_url @display_url end |
#id ⇒ Object (readonly)
Returns the value of attribute id.
9 10 11 |
# File 'lib/blingee/entry.rb', line 9 def id @id end |
#images ⇒ Object (readonly)
Returns the value of attribute images.
9 10 11 |
# File 'lib/blingee/entry.rb', line 9 def images @images end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
9 10 11 |
# File 'lib/blingee/entry.rb', line 9 def name @name end |