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
Overview
PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
Instance Method Summary collapse
-
#account_sid ⇒ String
The SID of the 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 ISO 8601 date and time in GMT when the resource was created.
-
#date_updated ⇒ Time
The ISO 8601 date and time in GMT when the resource was last updated.
-
#fetch ⇒ NetworkAccessProfileInstance
Fetch the NetworkAccessProfileInstance.
-
#initialize(version, payload, sid: nil) ⇒ NetworkAccessProfileInstance
constructor
Initialize the NetworkAccessProfileInstance.
-
#inspect ⇒ Object
Provide a detailed, user friendly representation.
-
#links ⇒ String
The links.
-
#networks ⇒ networks
Access the networks.
-
#sid ⇒ String
The unique string that identifies the 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 resource.
Constructor Details
#initialize(version, payload, sid: nil) ⇒ NetworkAccessProfileInstance
Initialize the NetworkAccessProfileInstance
250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 250 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 that the Network Access Profile belongs to.
294 295 296 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 294 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
273 274 275 276 277 278 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 273 def context unless @instance_context @instance_context = NetworkAccessProfileContext.new(@version, @params['sid'], ) end @instance_context end |
#date_created ⇒ Time
Returns The ISO 8601 date and time in GMT when the resource was created.
300 301 302 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 300 def date_created @properties['date_created'] end |
#date_updated ⇒ Time
Returns The ISO 8601 date and time in GMT when the resource was last updated.
306 307 308 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 306 def date_updated @properties['date_updated'] end |
#fetch ⇒ NetworkAccessProfileInstance
Fetch the NetworkAccessProfileInstance
325 326 327 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 325 def fetch context.fetch end |
#inspect ⇒ Object
Provide a detailed, user friendly representation
353 354 355 356 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 353 def inspect values = @properties.map{|k, v| "#{k}: #{v}"}.join(" ") "<Twilio.Supersim.V1.NetworkAccessProfileInstance #{values}>" end |
#links ⇒ String
Returns The links.
318 319 320 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 318 def links @properties['links'] end |
#networks ⇒ networks
Access the networks
340 341 342 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 340 def networks context.networks end |
#sid ⇒ String
Returns The unique string that identifies the resource.
282 283 284 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 282 def sid @properties['sid'] end |
#to_s ⇒ Object
Provide a user friendly representation
346 347 348 349 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 346 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.
288 289 290 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 288 def unique_name @properties['unique_name'] end |
#update(unique_name: :unset) ⇒ NetworkAccessProfileInstance
Update the NetworkAccessProfileInstance
333 334 335 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 333 def update(unique_name: :unset) context.update(unique_name: unique_name, ) end |
#url ⇒ String
Returns The absolute URL of the resource.
312 313 314 |
# File 'lib/twilio-ruby/rest/supersim/v1/network_access_profile.rb', line 312 def url @properties['url'] end |