Class: Twilio::REST::Supersim::V1::SimContext::SimIpAddressInstance

Inherits:
InstanceResource
  • Object
show all
Defined in:
lib/twilio-ruby/rest/supersim/v1/sim/sim_ip_address.rb

Instance Method Summary collapse

Constructor Details

#initialize(version, payload, sim_sid: nil) ⇒ SimIpAddressInstance

Initialize the SimIpAddressInstance

Parameters:

  • version (Version)

    Version that contains the resource

  • payload (Hash)

    payload that contains response from Twilio

  • account_sid (String)

    The SID of the Account that created this SimIpAddress resource.

  • sid (String)

    The SID of the Call resource to fetch.



165
166
167
168
169
170
171
172
173
# File 'lib/twilio-ruby/rest/supersim/v1/sim/sim_ip_address.rb', line 165

def initialize(version, payload , sim_sid: nil)
    super(version)
    
    # Marshaled Properties
    @properties = { 
        'ip_address' => payload['ip_address'],
        'ip_address_version' => payload['ip_address_version'],
    }
end

Instance Method Details

#inspectObject

Provide a detailed, user friendly representation



196
197
198
# File 'lib/twilio-ruby/rest/supersim/v1/sim/sim_ip_address.rb', line 196

def inspect
    "<Twilio.Supersim.V1.SimIpAddressInstance>"
end

#ip_addressString

Returns IP address assigned to the given Super SIM.

Returns:

  • (String)

    IP address assigned to the given Super SIM



178
179
180
# File 'lib/twilio-ruby/rest/supersim/v1/sim/sim_ip_address.rb', line 178

def ip_address
    @properties['ip_address']
end

#ip_address_versionIpAddressVersion

Returns:

  • (IpAddressVersion)


184
185
186
# File 'lib/twilio-ruby/rest/supersim/v1/sim/sim_ip_address.rb', line 184

def ip_address_version
    @properties['ip_address_version']
end

#to_sObject

Provide a user friendly representation



190
191
192
# File 'lib/twilio-ruby/rest/supersim/v1/sim/sim_ip_address.rb', line 190

def to_s
    "<Twilio.Supersim.V1.SimIpAddressInstance>"
end