Class: Twilio::REST::Numbers::V2::RegulatoryComplianceList::BundleContext::EvaluationInstance
- Inherits:
-
InstanceResource
- Object
- InstanceResource
- Twilio::REST::Numbers::V2::RegulatoryComplianceList::BundleContext::EvaluationInstance
- Defined in:
- lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/evaluation.rb
Instance Method Summary collapse
-
#account_sid ⇒ String
The SID of the Account that created the resource.
-
#bundle_sid ⇒ String
The unique string that identifies the resource.
-
#context ⇒ EvaluationContext
Generate an instance context for the instance, the context is capable of performing various actions.
-
#date_created ⇒ Time
The date_created.
-
#fetch ⇒ EvaluationInstance
Fetch the EvaluationInstance.
-
#initialize(version, payload, bundle_sid: nil, sid: nil) ⇒ EvaluationInstance
constructor
Initialize the EvaluationInstance.
-
#inspect ⇒ Object
Provide a detailed, user friendly representation.
-
#regulation_sid ⇒ String
The unique string of a regulation.
-
#results ⇒ Array[Hash]
The results of the Evaluation resource.
-
#sid ⇒ String
The unique string that identifies the Evaluation resource.
-
#status ⇒ evaluation.Status
The compliance status of the Evaluation resource.
-
#to_s ⇒ Object
Provide a user friendly representation.
-
#url ⇒ String
The url.
Constructor Details
#initialize(version, payload, bundle_sid: nil, sid: nil) ⇒ EvaluationInstance
Initialize the EvaluationInstance
204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/evaluation.rb', line 204 def initialize(version, payload, bundle_sid: nil, sid: nil) super(version) # Marshaled Properties @properties = { 'sid' => payload['sid'], 'account_sid' => payload['account_sid'], 'regulation_sid' => payload['regulation_sid'], 'bundle_sid' => payload['bundle_sid'], 'status' => payload['status'], 'results' => payload['results'], 'date_created' => Twilio.deserialize_iso8601_datetime(payload['date_created']), 'url' => payload['url'], } # Context @instance_context = nil @params = {'bundle_sid' => bundle_sid, 'sid' => sid || @properties['sid'], } end |
Instance Method Details
#account_sid ⇒ String
Returns The SID of the Account that created the resource.
243 244 245 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/evaluation.rb', line 243 def account_sid @properties['account_sid'] end |
#bundle_sid ⇒ String
Returns The unique string that identifies the resource.
255 256 257 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/evaluation.rb', line 255 def bundle_sid @properties['bundle_sid'] end |
#context ⇒ EvaluationContext
Generate an instance context for the instance, the context is capable of performing various actions. All instance actions are proxied to the context
228 229 230 231 232 233 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/evaluation.rb', line 228 def context unless @instance_context @instance_context = EvaluationContext.new(@version, @params['bundle_sid'], @params['sid'], ) end @instance_context end |
#date_created ⇒ Time
Returns The date_created.
273 274 275 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/evaluation.rb', line 273 def date_created @properties['date_created'] end |
#fetch ⇒ EvaluationInstance
Fetch the EvaluationInstance
286 287 288 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/evaluation.rb', line 286 def fetch context.fetch end |
#inspect ⇒ Object
Provide a detailed, user friendly representation
299 300 301 302 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/evaluation.rb', line 299 def inspect values = @properties.map{|k, v| "#{k}: #{v}"}.join(" ") "<Twilio.Numbers.V2.EvaluationInstance #{values}>" end |
#regulation_sid ⇒ String
Returns The unique string of a regulation.
249 250 251 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/evaluation.rb', line 249 def regulation_sid @properties['regulation_sid'] end |
#results ⇒ Array[Hash]
Returns The results of the Evaluation resource.
267 268 269 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/evaluation.rb', line 267 def results @properties['results'] end |
#sid ⇒ String
Returns The unique string that identifies the Evaluation resource.
237 238 239 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/evaluation.rb', line 237 def sid @properties['sid'] end |
#status ⇒ evaluation.Status
Returns The compliance status of the Evaluation resource.
261 262 263 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/evaluation.rb', line 261 def status @properties['status'] end |
#to_s ⇒ Object
Provide a user friendly representation
292 293 294 295 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/evaluation.rb', line 292 def to_s values = @params.map{|k, v| "#{k}: #{v}"}.join(" ") "<Twilio.Numbers.V2.EvaluationInstance #{values}>" end |
#url ⇒ String
Returns The url.
279 280 281 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/evaluation.rb', line 279 def url @properties['url'] end |