Class: Fastly::Settings
Overview
Represent arbitary key value settings for a given Version
Instance Attribute Summary collapse
-
#service_id ⇒ Object
Returns the value of attribute service_id.
-
#settings ⇒ Object
Returns the value of attribute settings.
-
#version ⇒ Object
Returns the value of attribute version.
Attributes inherited from Base
Class Method Summary collapse
-
.delete_path ⇒ Object
:nodoc:.
-
.get_path(service, number) ⇒ Object
:nodoc:.
-
.list_path(opts = {}) ⇒ Object
:nodoc:.
-
.post_path ⇒ Object
:nodoc:.
-
.put_path(obj) ⇒ Object
:nodoc:.
Instance Method Summary collapse
-
#as_hash ⇒ Object
:nodoc:.
-
#delete! ⇒ Object
:nodoc:.
Methods inherited from Base
Constructor Details
This class inherits a constructor from Fastly::Base
Instance Attribute Details
#service_id ⇒ Object
Returns the value of attribute service_id.
4 5 6 |
# File 'lib/fastly/settings.rb', line 4 def service_id @service_id end |
#settings ⇒ Object
Returns the value of attribute settings.
4 5 6 |
# File 'lib/fastly/settings.rb', line 4 def settings @settings end |
#version ⇒ Object
Returns the value of attribute version.
4 5 6 |
# File 'lib/fastly/settings.rb', line 4 def version @version end |
Class Method Details
.delete_path ⇒ Object
:nodoc:
44 45 46 |
# File 'lib/fastly/settings.rb', line 44 def self.delete_path raise "You can't DELETE to an setting" end |
.get_path(service, number) ⇒ Object
:nodoc:
24 25 26 |
# File 'lib/fastly/settings.rb', line 24 def self.get_path(service, number) "/service/#{service}/version/#{number}/settings" end |
.list_path(opts = {}) ⇒ Object
:nodoc:
34 35 36 |
# File 'lib/fastly/settings.rb', line 34 def self.list_path(opts={}) nil end |
.post_path ⇒ Object
:nodoc:
39 40 41 |
# File 'lib/fastly/settings.rb', line 39 def self.post_path raise "You can't POST to an setting" end |
.put_path(obj) ⇒ Object
:nodoc:
29 30 31 |
# File 'lib/fastly/settings.rb', line 29 def self.put_path(obj) get_path(obj.service_id, obj.version) end |
Instance Method Details
#as_hash ⇒ Object
:nodoc:
54 55 56 |
# File 'lib/fastly/settings.rb', line 54 def as_hash settings end |
#delete! ⇒ Object
:nodoc:
49 50 51 |
# File 'lib/fastly/settings.rb', line 49 def delete! raise "You can't delete an invoice" end |