Class: Twilio::REST::Supersim::V1::NetworkAccessProfileInstance
- Inherits:
-
InstanceResource
- Object
- InstanceResource
- Twilio::REST::Supersim::V1::NetworkAccessProfileInstance
- Defined in:
- lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb
Instance Method Summary collapse
-
#account_sid ⇒ String
The SID of the [Account](www.twilio.com/docs/iam/api/account) that the Network Access Profile belongs to.
-
#context ⇒ NetworkAccessProfileContext
Generate an instance context for the instance, the context is capable of performing various actions.
-
#date_created ⇒ Time
The date and time in GMT when the resource was created specified in [ISO 8601](en.wikipedia.org/wiki/ISO_8601) format.
-
#date_updated ⇒ Time
The date and time in GMT when the resource was last updated specified in [ISO 8601](en.wikipedia.org/wiki/ISO_8601) format.
-
#fetch ⇒ NetworkAccessProfileInstance
Fetch the NetworkAccessProfileInstance.
-
#initialize(version, payload, sid: nil) ⇒ NetworkAccessProfileInstance
constructor
Initialize the NetworkAccessProfileInstance.
-
#inspect ⇒ Object
Provide a detailed, user friendly representation.
- #links ⇒ Hash
-
#networks ⇒ networks
Access the networks.
-
#sid ⇒ String
The unique string that identifies the Network Access Profile resource.
-
#to_s ⇒ Object
Provide a user friendly representation.
-
#unique_name ⇒ String
An application-defined string that uniquely identifies the resource.
-
#update(unique_name: :unset) ⇒ NetworkAccessProfileInstance
Update the NetworkAccessProfileInstance.
-
#url ⇒ String
The absolute URL of the Network Access Profile resource.
Constructor Details
#initialize(version, payload, sid: nil) ⇒ NetworkAccessProfileInstance
Initialize the NetworkAccessProfileInstance
292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 292 def initialize(version, payload , sid: nil) super(version) # Marshaled Properties @properties = { 'sid' => payload['sid'], 'unique_name' => payload['unique_name'], 'account_sid' => payload['account_sid'], 'date_created' => Twilio.deserialize_iso8601_datetime(payload['date_created']), 'date_updated' => Twilio.deserialize_iso8601_datetime(payload['date_updated']), 'url' => payload['url'], 'links' => payload['links'], } # Context @instance_context = nil @params = { 'sid' => sid || @properties['sid'] , } end |
Instance Method Details
#account_sid ⇒ String
Returns The SID of the [Account](www.twilio.com/docs/iam/api/account) that the Network Access Profile belongs to.
336 337 338 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 336 def account_sid @properties['account_sid'] end |
#context ⇒ NetworkAccessProfileContext
Generate an instance context for the instance, the context is capable of performing various actions. All instance actions are proxied to the context
315 316 317 318 319 320 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 315 def context unless @instance_context @instance_context = NetworkAccessProfileContext.new(@version , @params['sid']) end @instance_context end |
#date_created ⇒ Time
Returns The date and time in GMT when the resource was created specified in [ISO 8601](en.wikipedia.org/wiki/ISO_8601) format.
342 343 344 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 342 def date_created @properties['date_created'] end |
#date_updated ⇒ Time
Returns The date and time in GMT when the resource was last updated specified in [ISO 8601](en.wikipedia.org/wiki/ISO_8601) format.
348 349 350 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 348 def date_updated @properties['date_updated'] end |
#fetch ⇒ NetworkAccessProfileInstance
Fetch the NetworkAccessProfileInstance
367 368 369 370 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 367 def fetch context.fetch end |
#inspect ⇒ Object
Provide a detailed, user friendly representation
401 402 403 404 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 401 def inspect values = @properties.map{|k, v| "#{k}: #{v}"}.join(" ") "<Twilio.Supersim.V1.NetworkAccessProfileInstance #{values}>" end |
#links ⇒ Hash
360 361 362 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 360 def links @properties['links'] end |
#networks ⇒ networks
Access the networks
388 389 390 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 388 def networks context.networks end |
#sid ⇒ String
Returns The unique string that identifies the Network Access Profile resource.
324 325 326 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 324 def sid @properties['sid'] end |
#to_s ⇒ Object
Provide a user friendly representation
394 395 396 397 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 394 def to_s values = @params.map{|k, v| "#{k}: #{v}"}.join(" ") "<Twilio.Supersim.V1.NetworkAccessProfileInstance #{values}>" end |
#unique_name ⇒ String
Returns An application-defined string that uniquely identifies the resource. It can be used in place of the resource’s ‘sid` in the URL to address the resource.
330 331 332 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 330 def unique_name @properties['unique_name'] end |
#update(unique_name: :unset) ⇒ NetworkAccessProfileInstance
Update the NetworkAccessProfileInstance
376 377 378 379 380 381 382 383 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 376 def update( unique_name: :unset ) context.update( unique_name: unique_name, ) end |
#url ⇒ String
Returns The absolute URL of the Network Access Profile resource.
354 355 356 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 354 def url @properties['url'] end |