Class: Twilio::REST::Studio::V2::FlowContext::FlowTestUserInstance
- Inherits:
-
InstanceResource
- Object
- InstanceResource
- Twilio::REST::Studio::V2::FlowContext::FlowTestUserInstance
- Defined in:
- lib/twilio-ruby/rest/studio/v2/flow/test_user.rb
Overview
PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
Instance Method Summary collapse
-
#context ⇒ FlowTestUserContext
Generate an instance context for the instance, the context is capable of performing various actions.
-
#fetch ⇒ FlowTestUserInstance
Fetch a FlowTestUserInstance.
-
#initialize(version, payload, sid: nil) ⇒ FlowTestUserInstance
constructor
Initialize the FlowTestUserInstance.
-
#inspect ⇒ Object
Provide a detailed, user friendly representation.
-
#sid ⇒ String
The sid.
-
#test_users ⇒ String
The test_users.
-
#to_s ⇒ Object
Provide a user friendly representation.
-
#update(test_users: nil) ⇒ FlowTestUserInstance
Update the FlowTestUserInstance.
-
#url ⇒ String
The url.
Constructor Details
#initialize(version, payload, sid: nil) ⇒ FlowTestUserInstance
Initialize the FlowTestUserInstance
138 139 140 141 142 143 144 145 146 147 148 149 150 151 |
# File 'lib/twilio-ruby/rest/studio/v2/flow/test_user.rb', line 138 def initialize(version, payload, sid: nil) super(version) # Marshaled Properties @properties = { 'sid' => payload['sid'], 'test_users' => payload['test_users'], 'url' => payload['url'], } # Context @instance_context = nil @params = {'sid' => sid, } end |
Instance Method Details
#context ⇒ FlowTestUserContext
Generate an instance context for the instance, the context is capable of performing various actions. All instance actions are proxied to the context
157 158 159 160 161 162 |
# File 'lib/twilio-ruby/rest/studio/v2/flow/test_user.rb', line 157 def context unless @instance_context @instance_context = FlowTestUserContext.new(@version, @params['sid'], ) end @instance_context end |
#fetch ⇒ FlowTestUserInstance
Fetch a FlowTestUserInstance
185 186 187 |
# File 'lib/twilio-ruby/rest/studio/v2/flow/test_user.rb', line 185 def fetch context.fetch end |
#inspect ⇒ Object
Provide a detailed, user friendly representation
206 207 208 209 |
# File 'lib/twilio-ruby/rest/studio/v2/flow/test_user.rb', line 206 def inspect values = @properties.map{|k, v| "#{k}: #{v}"}.join(" ") "<Twilio.Studio.V2.FlowTestUserInstance #{values}>" end |
#sid ⇒ String
Returns The sid.
166 167 168 |
# File 'lib/twilio-ruby/rest/studio/v2/flow/test_user.rb', line 166 def sid @properties['sid'] end |
#test_users ⇒ String
Returns The test_users.
172 173 174 |
# File 'lib/twilio-ruby/rest/studio/v2/flow/test_user.rb', line 172 def test_users @properties['test_users'] end |
#to_s ⇒ Object
Provide a user friendly representation
199 200 201 202 |
# File 'lib/twilio-ruby/rest/studio/v2/flow/test_user.rb', line 199 def to_s values = @params.map{|k, v| "#{k}: #{v}"}.join(" ") "<Twilio.Studio.V2.FlowTestUserInstance #{values}>" end |
#update(test_users: nil) ⇒ FlowTestUserInstance
Update the FlowTestUserInstance
193 194 195 |
# File 'lib/twilio-ruby/rest/studio/v2/flow/test_user.rb', line 193 def update(test_users: nil) context.update(test_users: test_users, ) end |
#url ⇒ String
Returns The url.
178 179 180 |
# File 'lib/twilio-ruby/rest/studio/v2/flow/test_user.rb', line 178 def url @properties['url'] end |