Class: Thingiverse::Files
- Inherits:
-
Object
- Object
- Thingiverse::Files
- Includes:
- ActiveModel::Validations
- Defined in:
- lib/thingiverse/files.rb
Instance Attribute Summary collapse
-
#download_url ⇒ Object
Returns the value of attribute download_url.
-
#id ⇒ Object
Returns the value of attribute id.
-
#name ⇒ Object
Returns the value of attribute name.
-
#public_url ⇒ Object
Returns the value of attribute public_url.
-
#threejs_url ⇒ Object
Returns the value of attribute threejs_url.
-
#thumbnail ⇒ Object
Returns the value of attribute thumbnail.
-
#url ⇒ Object
Returns the value of attribute url.
Instance Method Summary collapse
- #attributes ⇒ Object
-
#initialize(attributes = {}) ⇒ Files
constructor
A new instance of Files.
Constructor Details
#initialize(attributes = {}) ⇒ Files
Returns a new instance of Files.
7 8 9 10 11 |
# File 'lib/thingiverse/files.rb', line 7 def initialize(attributes={}) attributes.each do |name, value| send("#{name}=", value) end end |
Instance Attribute Details
#download_url ⇒ Object
Returns the value of attribute download_url.
6 7 8 |
# File 'lib/thingiverse/files.rb', line 6 def download_url @download_url end |
#id ⇒ Object
Returns the value of attribute id.
6 7 8 |
# File 'lib/thingiverse/files.rb', line 6 def id @id end |
#name ⇒ Object
Returns the value of attribute name.
6 7 8 |
# File 'lib/thingiverse/files.rb', line 6 def name @name end |
#public_url ⇒ Object
Returns the value of attribute public_url.
6 7 8 |
# File 'lib/thingiverse/files.rb', line 6 def public_url @public_url end |
#threejs_url ⇒ Object
Returns the value of attribute threejs_url.
6 7 8 |
# File 'lib/thingiverse/files.rb', line 6 def threejs_url @threejs_url end |
#thumbnail ⇒ Object
Returns the value of attribute thumbnail.
6 7 8 |
# File 'lib/thingiverse/files.rb', line 6 def thumbnail @thumbnail end |
#url ⇒ Object
Returns the value of attribute url.
6 7 8 |
# File 'lib/thingiverse/files.rb', line 6 def url @url end |
Instance Method Details
#attributes ⇒ Object
13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/thingiverse/files.rb', line 13 def attributes { :id => id, :name => name, :thumbnail => thumbnail, :url => url, :public_url => public_url, :threejs_url => threejs_url, :download_url => download_url } end |