Class: Twilio::REST::Webhooks::V1::RuleList::PatchRule
- Inherits:
-
Object
- Object
- Twilio::REST::Webhooks::V1::RuleList::PatchRule
- Defined in:
- lib/twilio-ruby/rest/webhooks/v1/rule.rb,
lib/twilio-ruby/rest/webhooks/v1/rule.rb
Instance Attribute Summary collapse
- #description ⇒ Object
- #friendly_name ⇒ Object
- #match_type ⇒ Object
- #prefix ⇒ Object
- #settings ⇒ Object
- #value ⇒ Object
Instance Method Summary collapse
-
#initialize(payload) ⇒ PatchRule
constructor
A new instance of PatchRule.
- #to_json(options = {}) ⇒ Object
Constructor Details
#initialize(payload) ⇒ PatchRule
Returns a new instance of PatchRule.
30 31 32 33 34 35 36 37 |
# File 'lib/twilio-ruby/rest/webhooks/v1/rule.rb', line 30 def initialize(payload) @friendly_name = payload["friendly_name"] @description = payload["description"] @match_type = payload["match_type"] @prefix = payload["prefix"] @settings = payload["settings"] @value = payload["value"] end |
Instance Attribute Details
#description ⇒ Object
29 30 31 |
# File 'lib/twilio-ruby/rest/webhooks/v1/rule.rb', line 29 def description @description end |
#friendly_name ⇒ Object
29 30 31 |
# File 'lib/twilio-ruby/rest/webhooks/v1/rule.rb', line 29 def friendly_name @friendly_name end |
#match_type ⇒ Object
29 30 31 |
# File 'lib/twilio-ruby/rest/webhooks/v1/rule.rb', line 29 def match_type @match_type end |
#prefix ⇒ Object
29 30 31 |
# File 'lib/twilio-ruby/rest/webhooks/v1/rule.rb', line 29 def prefix @prefix end |
#settings ⇒ Object
29 30 31 |
# File 'lib/twilio-ruby/rest/webhooks/v1/rule.rb', line 29 def settings @settings end |
#value ⇒ Object
29 30 31 |
# File 'lib/twilio-ruby/rest/webhooks/v1/rule.rb', line 29 def value @value end |
Instance Method Details
#to_json(options = {}) ⇒ Object
38 39 40 41 42 43 44 45 46 47 |
# File 'lib/twilio-ruby/rest/webhooks/v1/rule.rb', line 38 def to_json( = {}) { "friendlyName": @friendly_name, "description": @description, "matchType": @match_type, "prefix": @prefix, "settings": @settings, "value": @value, }.to_json() end |