Class: Twilio::REST::Video::V1::CompositionContext
- Inherits:
-
InstanceContext
- Object
- InstanceContext
- Twilio::REST::Video::V1::CompositionContext
- Defined in:
- lib/twilio-ruby/rest/video/v1/composition.rb
Overview
PLEASE NOTE that this class contains preview products that are subject to change. Use them with caution. If you currently do not have developer preview access, please contact [email protected].
Instance Method Summary collapse
-
#delete ⇒ Boolean
Deletes the CompositionInstance.
-
#fetch ⇒ CompositionInstance
Fetch a CompositionInstance.
-
#initialize(version, sid) ⇒ CompositionContext
constructor
Initialize the CompositionContext.
-
#inspect ⇒ Object
Provide a detailed, user friendly representation.
-
#to_s ⇒ Object
Provide a user friendly representation.
Constructor Details
#initialize(version, sid) ⇒ CompositionContext
Initialize the CompositionContext
285 286 287 288 289 290 291 |
# File 'lib/twilio-ruby/rest/video/v1/composition.rb', line 285 def initialize(version, sid) super(version) # Path Solution @solution = {sid: sid, } @uri = "/Compositions/#{@solution[:sid]}" end |
Instance Method Details
#delete ⇒ Boolean
Deletes the CompositionInstance
311 312 313 |
# File 'lib/twilio-ruby/rest/video/v1/composition.rb', line 311 def delete @version.delete('delete', @uri) end |
#fetch ⇒ CompositionInstance
Fetch a CompositionInstance
296 297 298 299 300 301 302 303 304 305 306 |
# File 'lib/twilio-ruby/rest/video/v1/composition.rb', line 296 def fetch params = Twilio::Values.of({}) payload = @version.fetch( 'GET', @uri, params, ) CompositionInstance.new(@version, payload, sid: @solution[:sid], ) end |
#inspect ⇒ Object
Provide a detailed, user friendly representation
324 325 326 327 |
# File 'lib/twilio-ruby/rest/video/v1/composition.rb', line 324 def inspect context = @solution.map {|k, v| "#{k}: #{v}"}.join(',') "#<Twilio.Video.V1.CompositionContext #{context}>" end |
#to_s ⇒ Object
Provide a user friendly representation
317 318 319 320 |
# File 'lib/twilio-ruby/rest/video/v1/composition.rb', line 317 def to_s context = @solution.map {|k, v| "#{k}: #{v}"}.join(',') "#<Twilio.Video.V1.CompositionContext #{context}>" end |