Class: Twilio::REST::Preview::BulkExports::ExportList::JobContext
- Inherits:
-
InstanceContext
- Object
- InstanceContext
- Twilio::REST::Preview::BulkExports::ExportList::JobContext
- Defined in:
- lib/twilio-ruby/rest/preview/bulk_exports/export/job.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 JobInstance.
-
#fetch ⇒ JobInstance
Fetch a JobInstance.
-
#initialize(version, job_sid) ⇒ JobContext
constructor
Initialize the JobContext.
-
#inspect ⇒ Object
Provide a detailed, user friendly representation.
-
#to_s ⇒ Object
Provide a user friendly representation.
Constructor Details
#initialize(version, job_sid) ⇒ JobContext
Initialize the JobContext
74 75 76 77 78 79 80 |
# File 'lib/twilio-ruby/rest/preview/bulk_exports/export/job.rb', line 74 def initialize(version, job_sid) super(version) # Path Solution @solution = {job_sid: job_sid, } @uri = "/Exports/Jobs/#{@solution[:job_sid]}" end |
Instance Method Details
#delete ⇒ Boolean
Deletes the JobInstance
100 101 102 |
# File 'lib/twilio-ruby/rest/preview/bulk_exports/export/job.rb', line 100 def delete @version.delete('delete', @uri) end |
#fetch ⇒ JobInstance
Fetch a JobInstance
85 86 87 88 89 90 91 92 93 94 95 |
# File 'lib/twilio-ruby/rest/preview/bulk_exports/export/job.rb', line 85 def fetch params = Twilio::Values.of({}) payload = @version.fetch( 'GET', @uri, params, ) JobInstance.new(@version, payload, job_sid: @solution[:job_sid], ) end |
#inspect ⇒ Object
Provide a detailed, user friendly representation
113 114 115 116 |
# File 'lib/twilio-ruby/rest/preview/bulk_exports/export/job.rb', line 113 def inspect context = @solution.map {|k, v| "#{k}: #{v}"}.join(',') "#<Twilio.Preview.BulkExports.JobContext #{context}>" end |
#to_s ⇒ Object
Provide a user friendly representation
106 107 108 109 |
# File 'lib/twilio-ruby/rest/preview/bulk_exports/export/job.rb', line 106 def to_s context = @solution.map {|k, v| "#{k}: #{v}"}.join(',') "#<Twilio.Preview.BulkExports.JobContext #{context}>" end |