kaltura-client 3.2.0 → 3.3.0
Sign up to get free protection for your applications and to get access to all the features.
- data/README +3 -0
- data/kaltura.yml +4 -4
- data/lib/kaltura_client.rb +2269 -12871
- data/lib/kaltura_client_base.rb +289 -222
- data/lib/kaltura_enums.rb +3119 -0
- data/lib/kaltura_plugins/kaltura_ad_cue_point_client_plugin.rb +30 -0
- data/lib/kaltura_plugins/kaltura_admin_console_client_plugin.rb +125 -78
- data/lib/kaltura_plugins/kaltura_annotation_client_plugin.rb +76 -34
- data/lib/kaltura_plugins/kaltura_attachment_client_plugin.rb +71 -40
- data/lib/kaltura_plugins/kaltura_bulk_upload_client_plugin.rb +25 -22
- data/lib/kaltura_plugins/kaltura_bulk_upload_csv_client_plugin.rb +7 -0
- data/lib/kaltura_plugins/kaltura_bulk_upload_filter_client_plugin.rb +14 -0
- data/lib/kaltura_plugins/kaltura_bulk_upload_xml_client_plugin.rb +5 -0
- data/lib/kaltura_plugins/kaltura_caption_client_plugin.rb +167 -77
- data/lib/kaltura_plugins/kaltura_caption_search_client_plugin.rb +56 -12
- data/lib/kaltura_plugins/kaltura_cielo24client_plugin.rb +89 -0
- data/lib/kaltura_plugins/kaltura_code_cue_point_client_plugin.rb +31 -0
- data/lib/kaltura_plugins/kaltura_content_distribution_client_plugin.rb +706 -194
- data/lib/kaltura_plugins/kaltura_cue_point_client_plugin.rb +124 -34
- data/lib/kaltura_plugins/kaltura_document_client_plugin.rb +238 -102
- data/lib/kaltura_plugins/kaltura_drop_folder_client_plugin.rb +328 -55
- data/lib/kaltura_plugins/kaltura_drop_folder_xml_bulk_upload_client_plugin.rb +5 -0
- data/lib/kaltura_plugins/kaltura_email_notification_client_plugin.rb +122 -0
- data/lib/kaltura_plugins/kaltura_event_cue_point_client_plugin.rb +18 -0
- data/lib/kaltura_plugins/kaltura_event_notification_client_plugin.rb +142 -51
- data/lib/kaltura_plugins/kaltura_external_media_client_plugin.rb +54 -33
- data/lib/kaltura_plugins/kaltura_feed_drop_folder_client_plugin.rb +28 -0
- data/lib/kaltura_plugins/kaltura_file_sync_client_plugin.rb +84 -0
- data/lib/kaltura_plugins/kaltura_http_notification_client_plugin.rb +94 -0
- data/lib/kaltura_plugins/kaltura_integration_client_plugin.rb +127 -0
- data/lib/kaltura_plugins/kaltura_kaltura_internal_tools_client_plugin.rb +25 -11
- data/lib/kaltura_plugins/kaltura_kontiki_client_plugin.rb +31 -0
- data/lib/kaltura_plugins/kaltura_like_client_plugin.rb +95 -13
- data/lib/kaltura_plugins/kaltura_metadata_client_plugin.rb +331 -149
- data/lib/kaltura_plugins/kaltura_quiz_client_plugin.rb +365 -0
- data/lib/kaltura_plugins/kaltura_scheduled_task_client_plugin.rb +132 -31
- data/lib/kaltura_plugins/kaltura_scheduled_task_content_distribution_client_plugin.rb +6 -0
- data/lib/kaltura_plugins/kaltura_scheduled_task_event_notification_client_plugin.rb +6 -0
- data/lib/kaltura_plugins/kaltura_scheduled_task_metadata_client_plugin.rb +8 -0
- data/lib/kaltura_plugins/kaltura_short_link_client_plugin.rb +74 -27
- data/lib/kaltura_plugins/kaltura_system_partner_client_plugin.rb +203 -62
- data/lib/kaltura_plugins/kaltura_tag_search_client_plugin.rb +51 -14
- data/lib/kaltura_plugins/kaltura_thumb_cue_point_client_plugin.rb +44 -1
- data/lib/kaltura_plugins/kaltura_transcript_client_plugin.rb +101 -0
- data/lib/kaltura_plugins/kaltura_var_console_client_plugin.rb +59 -11
- data/lib/kaltura_plugins/kaltura_velocix_client_plugin.rb +8 -0
- data/lib/kaltura_plugins/kaltura_virus_scan_client_plugin.rb +87 -28
- data/lib/kaltura_plugins/kaltura_voicebase_client_plugin.rb +82 -0
- data/lib/kaltura_plugins/kaltura_wowza_client_plugin.rb +99 -0
- data/lib/kaltura_types.rb +13862 -0
- data/test/access_control_service_test.rb +35 -42
- data/test/base_entry_service_test.rb +265 -241
- data/test/configuration_test.rb +19 -14
- data/test/media_service_test.rb +296 -294
- data/test/metadata_profile_service_test.rb +30 -32
- data/test/response_profile_test.rb +208 -0
- data/test/test_helper.rb +3 -3
- metadata +53 -51
- data/lib/kaltura_plugins/kaltura_abc_screeners_watermark_access_control_client_plugin.rb +0 -37
- data/lib/kaltura_plugins/kaltura_aspera_client_plugin.rb +0 -61
- data/lib/kaltura_plugins/kaltura_audit_client_plugin.rb +0 -349
- data/lib/kaltura_plugins/kaltura_drm_client_plugin.rb +0 -401
- data/lib/kaltura_plugins/kaltura_multi_centers_client_plugin.rb +0 -45
- data/lib/kaltura_plugins/kaltura_play_ready_client_plugin.rb +0 -347
- data/lib/kaltura_plugins/kaltura_webex_drop_folder_client_plugin.rb +0 -111
- data/lib/kaltura_plugins/kaltura_widevine_client_plugin.rb +0 -195
@@ -0,0 +1,365 @@
|
|
1
|
+
# ===================================================================================================
|
2
|
+
# _ __ _ _
|
3
|
+
# | |/ /__ _| | |_ _ _ _ _ __ _
|
4
|
+
# | ' </ _` | | _| || | '_/ _` |
|
5
|
+
# |_|\_\__,_|_|\__|\_,_|_| \__,_|
|
6
|
+
#
|
7
|
+
# This file is part of the Kaltura Collaborative Media Suite which allows users
|
8
|
+
# to do with audio, video, and animation what Wiki platfroms allow them to do with
|
9
|
+
# text.
|
10
|
+
#
|
11
|
+
# Copyright (C) 2006-2015 Kaltura Inc.
|
12
|
+
#
|
13
|
+
# This program is free software: you can redistribute it and/or modify
|
14
|
+
# it under the terms of the GNU Affero General Public License as
|
15
|
+
# published by the Free Software Foundation, either version 3 of the
|
16
|
+
# License, or (at your option) any later version.
|
17
|
+
#
|
18
|
+
# This program is distributed in the hope that it will be useful,
|
19
|
+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
20
|
+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
21
|
+
# GNU Affero General Public License for more details.
|
22
|
+
#
|
23
|
+
# You should have received a copy of the GNU Affero General Public License
|
24
|
+
# along with this program. If not, see <http:#www.gnu.org/licenses/>.
|
25
|
+
#
|
26
|
+
# @ignore
|
27
|
+
# ===================================================================================================
|
28
|
+
require 'kaltura_client.rb'
|
29
|
+
require File.dirname(__FILE__) + '/kaltura_cue_point_client_plugin.rb'
|
30
|
+
|
31
|
+
module Kaltura
|
32
|
+
|
33
|
+
class KalturaAnswerCuePointOrderBy
|
34
|
+
CREATED_AT_ASC = "+createdAt"
|
35
|
+
PARTNER_SORT_VALUE_ASC = "+partnerSortValue"
|
36
|
+
START_TIME_ASC = "+startTime"
|
37
|
+
TRIGGERED_AT_ASC = "+triggeredAt"
|
38
|
+
UPDATED_AT_ASC = "+updatedAt"
|
39
|
+
CREATED_AT_DESC = "-createdAt"
|
40
|
+
PARTNER_SORT_VALUE_DESC = "-partnerSortValue"
|
41
|
+
START_TIME_DESC = "-startTime"
|
42
|
+
TRIGGERED_AT_DESC = "-triggeredAt"
|
43
|
+
UPDATED_AT_DESC = "-updatedAt"
|
44
|
+
end
|
45
|
+
|
46
|
+
class KalturaQuestionCuePointOrderBy
|
47
|
+
CREATED_AT_ASC = "+createdAt"
|
48
|
+
PARTNER_SORT_VALUE_ASC = "+partnerSortValue"
|
49
|
+
START_TIME_ASC = "+startTime"
|
50
|
+
TRIGGERED_AT_ASC = "+triggeredAt"
|
51
|
+
UPDATED_AT_ASC = "+updatedAt"
|
52
|
+
CREATED_AT_DESC = "-createdAt"
|
53
|
+
PARTNER_SORT_VALUE_DESC = "-partnerSortValue"
|
54
|
+
START_TIME_DESC = "-startTime"
|
55
|
+
TRIGGERED_AT_DESC = "-triggeredAt"
|
56
|
+
UPDATED_AT_DESC = "-updatedAt"
|
57
|
+
end
|
58
|
+
|
59
|
+
# A representation of an optional answer for question cue point
|
60
|
+
#
|
61
|
+
class KalturaOptionalAnswer < KalturaObjectBase
|
62
|
+
attr_accessor :key
|
63
|
+
attr_accessor :text
|
64
|
+
attr_accessor :weight
|
65
|
+
attr_accessor :is_correct
|
66
|
+
|
67
|
+
def weight=(val)
|
68
|
+
@weight = val.to_f
|
69
|
+
end
|
70
|
+
def is_correct=(val)
|
71
|
+
@is_correct = val.to_i
|
72
|
+
end
|
73
|
+
|
74
|
+
def from_xml(xml_element)
|
75
|
+
super
|
76
|
+
self.key = xml_element.elements['key'].text
|
77
|
+
self.text = xml_element.elements['text'].text
|
78
|
+
self.weight = xml_element.elements['weight'].text
|
79
|
+
self.is_correct = xml_element.elements['isCorrect'].text
|
80
|
+
end
|
81
|
+
|
82
|
+
end
|
83
|
+
|
84
|
+
class KalturaQuiz < KalturaObjectBase
|
85
|
+
attr_accessor :version
|
86
|
+
# Array of key value ui related objects
|
87
|
+
#
|
88
|
+
attr_accessor :ui_attributes
|
89
|
+
attr_accessor :show_result_on_answer
|
90
|
+
attr_accessor :show_correct_key_on_answer
|
91
|
+
attr_accessor :allow_answer_update
|
92
|
+
attr_accessor :show_correct_after_submission
|
93
|
+
attr_accessor :allow_download
|
94
|
+
attr_accessor :show_grade_after_submission
|
95
|
+
|
96
|
+
def version=(val)
|
97
|
+
@version = val.to_i
|
98
|
+
end
|
99
|
+
def show_result_on_answer=(val)
|
100
|
+
@show_result_on_answer = val.to_i
|
101
|
+
end
|
102
|
+
def show_correct_key_on_answer=(val)
|
103
|
+
@show_correct_key_on_answer = val.to_i
|
104
|
+
end
|
105
|
+
def allow_answer_update=(val)
|
106
|
+
@allow_answer_update = val.to_i
|
107
|
+
end
|
108
|
+
def show_correct_after_submission=(val)
|
109
|
+
@show_correct_after_submission = val.to_i
|
110
|
+
end
|
111
|
+
def allow_download=(val)
|
112
|
+
@allow_download = val.to_i
|
113
|
+
end
|
114
|
+
def show_grade_after_submission=(val)
|
115
|
+
@show_grade_after_submission = val.to_i
|
116
|
+
end
|
117
|
+
|
118
|
+
def from_xml(xml_element)
|
119
|
+
super
|
120
|
+
self.version = xml_element.elements['version'].text
|
121
|
+
self.ui_attributes = KalturaClientBase.object_from_xml(xml_element.elements['uiAttributes'], 'KalturaKeyValue')
|
122
|
+
self.show_result_on_answer = xml_element.elements['showResultOnAnswer'].text
|
123
|
+
self.show_correct_key_on_answer = xml_element.elements['showCorrectKeyOnAnswer'].text
|
124
|
+
self.allow_answer_update = xml_element.elements['allowAnswerUpdate'].text
|
125
|
+
self.show_correct_after_submission = xml_element.elements['showCorrectAfterSubmission'].text
|
126
|
+
self.allow_download = xml_element.elements['allowDownload'].text
|
127
|
+
self.show_grade_after_submission = xml_element.elements['showGradeAfterSubmission'].text
|
128
|
+
end
|
129
|
+
|
130
|
+
end
|
131
|
+
|
132
|
+
class KalturaAnswerCuePoint < KalturaCuePoint
|
133
|
+
attr_accessor :parent_id
|
134
|
+
attr_accessor :quiz_user_entry_id
|
135
|
+
attr_accessor :answer_key
|
136
|
+
attr_accessor :is_correct
|
137
|
+
# Array of string
|
138
|
+
#
|
139
|
+
attr_accessor :correct_answer_keys
|
140
|
+
attr_accessor :explanation
|
141
|
+
|
142
|
+
def is_correct=(val)
|
143
|
+
@is_correct = val.to_i
|
144
|
+
end
|
145
|
+
|
146
|
+
def from_xml(xml_element)
|
147
|
+
super
|
148
|
+
self.parent_id = xml_element.elements['parentId'].text
|
149
|
+
self.quiz_user_entry_id = xml_element.elements['quizUserEntryId'].text
|
150
|
+
self.answer_key = xml_element.elements['answerKey'].text
|
151
|
+
self.is_correct = xml_element.elements['isCorrect'].text
|
152
|
+
self.correct_answer_keys = KalturaClientBase.object_from_xml(xml_element.elements['correctAnswerKeys'], 'KalturaString')
|
153
|
+
self.explanation = xml_element.elements['explanation'].text
|
154
|
+
end
|
155
|
+
|
156
|
+
end
|
157
|
+
|
158
|
+
class KalturaQuestionCuePoint < KalturaCuePoint
|
159
|
+
# Array of key value answerKey->optionAnswer objects
|
160
|
+
#
|
161
|
+
attr_accessor :optional_answers
|
162
|
+
attr_accessor :hint
|
163
|
+
attr_accessor :question
|
164
|
+
attr_accessor :explanation
|
165
|
+
|
166
|
+
|
167
|
+
def from_xml(xml_element)
|
168
|
+
super
|
169
|
+
self.optional_answers = KalturaClientBase.object_from_xml(xml_element.elements['optionalAnswers'], 'KalturaOptionalAnswer')
|
170
|
+
self.hint = xml_element.elements['hint'].text
|
171
|
+
self.question = xml_element.elements['question'].text
|
172
|
+
self.explanation = xml_element.elements['explanation'].text
|
173
|
+
end
|
174
|
+
|
175
|
+
end
|
176
|
+
|
177
|
+
class KalturaQuizAdvancedFilter < KalturaSearchItem
|
178
|
+
attr_accessor :is_quiz
|
179
|
+
|
180
|
+
def is_quiz=(val)
|
181
|
+
@is_quiz = val.to_i
|
182
|
+
end
|
183
|
+
|
184
|
+
def from_xml(xml_element)
|
185
|
+
super
|
186
|
+
self.is_quiz = xml_element.elements['isQuiz'].text
|
187
|
+
end
|
188
|
+
|
189
|
+
end
|
190
|
+
|
191
|
+
class KalturaQuizListResponse < KalturaListResponse
|
192
|
+
attr_accessor :objects
|
193
|
+
|
194
|
+
|
195
|
+
def from_xml(xml_element)
|
196
|
+
super
|
197
|
+
self.objects = KalturaClientBase.object_from_xml(xml_element.elements['objects'], 'KalturaQuiz')
|
198
|
+
end
|
199
|
+
|
200
|
+
end
|
201
|
+
|
202
|
+
class KalturaQuizFilter < KalturaRelatedFilter
|
203
|
+
# This filter should be in use for retrieving only a specific quiz entry (identified by its entryId).
|
204
|
+
#
|
205
|
+
attr_accessor :entry_id_equal
|
206
|
+
# This filter should be in use for retrieving few specific quiz entries (string should include comma separated list of entryId strings).
|
207
|
+
#
|
208
|
+
attr_accessor :entry_id_in
|
209
|
+
|
210
|
+
|
211
|
+
def from_xml(xml_element)
|
212
|
+
super
|
213
|
+
self.entry_id_equal = xml_element.elements['entryIdEqual'].text
|
214
|
+
self.entry_id_in = xml_element.elements['entryIdIn'].text
|
215
|
+
end
|
216
|
+
|
217
|
+
end
|
218
|
+
|
219
|
+
class KalturaAnswerCuePointBaseFilter < KalturaCuePointFilter
|
220
|
+
attr_accessor :parent_id_equal
|
221
|
+
attr_accessor :parent_id_in
|
222
|
+
attr_accessor :quiz_user_entry_id_equal
|
223
|
+
attr_accessor :quiz_user_entry_id_in
|
224
|
+
|
225
|
+
|
226
|
+
def from_xml(xml_element)
|
227
|
+
super
|
228
|
+
self.parent_id_equal = xml_element.elements['parentIdEqual'].text
|
229
|
+
self.parent_id_in = xml_element.elements['parentIdIn'].text
|
230
|
+
self.quiz_user_entry_id_equal = xml_element.elements['quizUserEntryIdEqual'].text
|
231
|
+
self.quiz_user_entry_id_in = xml_element.elements['quizUserEntryIdIn'].text
|
232
|
+
end
|
233
|
+
|
234
|
+
end
|
235
|
+
|
236
|
+
class KalturaQuestionCuePointBaseFilter < KalturaCuePointFilter
|
237
|
+
attr_accessor :question_like
|
238
|
+
attr_accessor :question_multi_like_or
|
239
|
+
attr_accessor :question_multi_like_and
|
240
|
+
|
241
|
+
|
242
|
+
def from_xml(xml_element)
|
243
|
+
super
|
244
|
+
self.question_like = xml_element.elements['questionLike'].text
|
245
|
+
self.question_multi_like_or = xml_element.elements['questionMultiLikeOr'].text
|
246
|
+
self.question_multi_like_and = xml_element.elements['questionMultiLikeAnd'].text
|
247
|
+
end
|
248
|
+
|
249
|
+
end
|
250
|
+
|
251
|
+
class KalturaAnswerCuePointFilter < KalturaAnswerCuePointBaseFilter
|
252
|
+
|
253
|
+
|
254
|
+
def from_xml(xml_element)
|
255
|
+
super
|
256
|
+
end
|
257
|
+
|
258
|
+
end
|
259
|
+
|
260
|
+
class KalturaQuestionCuePointFilter < KalturaQuestionCuePointBaseFilter
|
261
|
+
|
262
|
+
|
263
|
+
def from_xml(xml_element)
|
264
|
+
super
|
265
|
+
end
|
266
|
+
|
267
|
+
end
|
268
|
+
|
269
|
+
|
270
|
+
# Allows user to handle quizzes
|
271
|
+
#
|
272
|
+
class KalturaQuizService < KalturaServiceBase
|
273
|
+
def initialize(client)
|
274
|
+
super(client)
|
275
|
+
end
|
276
|
+
|
277
|
+
# Allows to add a quiz to an entry
|
278
|
+
#
|
279
|
+
def add(entry_id, quiz)
|
280
|
+
kparams = {}
|
281
|
+
client.add_param(kparams, 'entryId', entry_id)
|
282
|
+
client.add_param(kparams, 'quiz', quiz)
|
283
|
+
client.queue_service_action_call('quiz_quiz', 'add', 'KalturaQuiz', kparams)
|
284
|
+
if (client.is_multirequest)
|
285
|
+
return nil
|
286
|
+
end
|
287
|
+
return client.do_queue()
|
288
|
+
end
|
289
|
+
|
290
|
+
# Allows to update a quiz
|
291
|
+
#
|
292
|
+
def update(entry_id, quiz)
|
293
|
+
kparams = {}
|
294
|
+
client.add_param(kparams, 'entryId', entry_id)
|
295
|
+
client.add_param(kparams, 'quiz', quiz)
|
296
|
+
client.queue_service_action_call('quiz_quiz', 'update', 'KalturaQuiz', kparams)
|
297
|
+
if (client.is_multirequest)
|
298
|
+
return nil
|
299
|
+
end
|
300
|
+
return client.do_queue()
|
301
|
+
end
|
302
|
+
|
303
|
+
# Allows to get a quiz
|
304
|
+
#
|
305
|
+
def get(entry_id)
|
306
|
+
kparams = {}
|
307
|
+
client.add_param(kparams, 'entryId', entry_id)
|
308
|
+
client.queue_service_action_call('quiz_quiz', 'get', 'KalturaQuiz', kparams)
|
309
|
+
if (client.is_multirequest)
|
310
|
+
return nil
|
311
|
+
end
|
312
|
+
return client.do_queue()
|
313
|
+
end
|
314
|
+
|
315
|
+
# List quiz objects by filter and pager
|
316
|
+
#
|
317
|
+
def list(filter=KalturaNotImplemented, pager=KalturaNotImplemented)
|
318
|
+
kparams = {}
|
319
|
+
client.add_param(kparams, 'filter', filter)
|
320
|
+
client.add_param(kparams, 'pager', pager)
|
321
|
+
client.queue_service_action_call('quiz_quiz', 'list', 'KalturaQuizListResponse', kparams)
|
322
|
+
if (client.is_multirequest)
|
323
|
+
return nil
|
324
|
+
end
|
325
|
+
return client.do_queue()
|
326
|
+
end
|
327
|
+
|
328
|
+
# creates a pdf from quiz object
|
329
|
+
# The Output type defines the file format in which the quiz will be generated
|
330
|
+
# Currently only PDF files are supported
|
331
|
+
#
|
332
|
+
def serve(entry_id, quiz_output_type)
|
333
|
+
kparams = {}
|
334
|
+
client.add_param(kparams, 'entryId', entry_id)
|
335
|
+
client.add_param(kparams, 'quizOutputType', quiz_output_type)
|
336
|
+
client.queue_service_action_call('quiz_quiz', 'serve', 'file', kparams)
|
337
|
+
return client.get_serve_url()
|
338
|
+
end
|
339
|
+
|
340
|
+
# sends a with an api request for pdf from quiz object
|
341
|
+
#
|
342
|
+
def get_url(entry_id, quiz_output_type)
|
343
|
+
kparams = {}
|
344
|
+
client.add_param(kparams, 'entryId', entry_id)
|
345
|
+
client.add_param(kparams, 'quizOutputType', quiz_output_type)
|
346
|
+
client.queue_service_action_call('quiz_quiz', 'getUrl', 'string', kparams)
|
347
|
+
if (client.is_multirequest)
|
348
|
+
return nil
|
349
|
+
end
|
350
|
+
return client.do_queue()
|
351
|
+
end
|
352
|
+
end
|
353
|
+
|
354
|
+
class KalturaClient < KalturaClientBase
|
355
|
+
attr_reader :quiz_service
|
356
|
+
def quiz_service
|
357
|
+
if (@quiz_service == nil)
|
358
|
+
@quiz_service = KalturaQuizService.new(self)
|
359
|
+
end
|
360
|
+
return @quiz_service
|
361
|
+
end
|
362
|
+
|
363
|
+
end
|
364
|
+
|
365
|
+
end
|
@@ -82,6 +82,13 @@ module Kaltura
|
|
82
82
|
def stop_processing_on_error=(val)
|
83
83
|
@stop_processing_on_error = to_b(val)
|
84
84
|
end
|
85
|
+
|
86
|
+
def from_xml(xml_element)
|
87
|
+
super
|
88
|
+
self.type = xml_element.elements['type'].text
|
89
|
+
self.stop_processing_on_error = xml_element.elements['stopProcessingOnError'].text
|
90
|
+
end
|
91
|
+
|
85
92
|
end
|
86
93
|
|
87
94
|
class KalturaScheduledTaskProfile < KalturaObjectBase
|
@@ -128,6 +135,24 @@ module Kaltura
|
|
128
135
|
def max_total_count_allowed=(val)
|
129
136
|
@max_total_count_allowed = val.to_i
|
130
137
|
end
|
138
|
+
|
139
|
+
def from_xml(xml_element)
|
140
|
+
super
|
141
|
+
self.id = xml_element.elements['id'].text
|
142
|
+
self.partner_id = xml_element.elements['partnerId'].text
|
143
|
+
self.name = xml_element.elements['name'].text
|
144
|
+
self.system_name = xml_element.elements['systemName'].text
|
145
|
+
self.description = xml_element.elements['description'].text
|
146
|
+
self.status = xml_element.elements['status'].text
|
147
|
+
self.object_filter_engine_type = xml_element.elements['objectFilterEngineType'].text
|
148
|
+
self.object_filter = KalturaClientBase.object_from_xml(xml_element.elements['objectFilter'], 'KalturaFilter')
|
149
|
+
self.object_tasks = KalturaClientBase.object_from_xml(xml_element.elements['objectTasks'], 'KalturaObjectTask')
|
150
|
+
self.created_at = xml_element.elements['createdAt'].text
|
151
|
+
self.updated_at = xml_element.elements['updatedAt'].text
|
152
|
+
self.last_execution_started_at = xml_element.elements['lastExecutionStartedAt'].text
|
153
|
+
self.max_total_count_allowed = xml_element.elements['maxTotalCountAllowed'].text
|
154
|
+
end
|
155
|
+
|
131
156
|
end
|
132
157
|
|
133
158
|
class KalturaConvertEntryFlavorsObjectTask < KalturaObjectTask
|
@@ -141,6 +166,13 @@ module Kaltura
|
|
141
166
|
def reconvert=(val)
|
142
167
|
@reconvert = to_b(val)
|
143
168
|
end
|
169
|
+
|
170
|
+
def from_xml(xml_element)
|
171
|
+
super
|
172
|
+
self.flavor_params_ids = xml_element.elements['flavorParamsIds'].text
|
173
|
+
self.reconvert = xml_element.elements['reconvert'].text
|
174
|
+
end
|
175
|
+
|
144
176
|
end
|
145
177
|
|
146
178
|
class KalturaDeleteEntryFlavorsObjectTask < KalturaObjectTask
|
@@ -154,14 +186,31 @@ module Kaltura
|
|
154
186
|
def delete_type=(val)
|
155
187
|
@delete_type = val.to_i
|
156
188
|
end
|
189
|
+
|
190
|
+
def from_xml(xml_element)
|
191
|
+
super
|
192
|
+
self.delete_type = xml_element.elements['deleteType'].text
|
193
|
+
self.flavor_params_ids = xml_element.elements['flavorParamsIds'].text
|
194
|
+
end
|
195
|
+
|
157
196
|
end
|
158
197
|
|
159
198
|
class KalturaDeleteEntryObjectTask < KalturaObjectTask
|
160
199
|
|
200
|
+
|
201
|
+
def from_xml(xml_element)
|
202
|
+
super
|
203
|
+
end
|
204
|
+
|
161
205
|
end
|
162
206
|
|
163
207
|
class KalturaDeleteLocalContentObjectTask < KalturaObjectTask
|
164
208
|
|
209
|
+
|
210
|
+
def from_xml(xml_element)
|
211
|
+
super
|
212
|
+
end
|
213
|
+
|
165
214
|
end
|
166
215
|
|
167
216
|
class KalturaModifyCategoriesObjectTask < KalturaObjectTask
|
@@ -175,6 +224,13 @@ module Kaltura
|
|
175
224
|
def add_remove_type=(val)
|
176
225
|
@add_remove_type = val.to_i
|
177
226
|
end
|
227
|
+
|
228
|
+
def from_xml(xml_element)
|
229
|
+
super
|
230
|
+
self.add_remove_type = xml_element.elements['addRemoveType'].text
|
231
|
+
self.category_ids = KalturaClientBase.object_from_xml(xml_element.elements['categoryIds'], 'KalturaIntegerValue')
|
232
|
+
end
|
233
|
+
|
178
234
|
end
|
179
235
|
|
180
236
|
class KalturaScheduledTaskJobData < KalturaJobData
|
@@ -188,6 +244,14 @@ module Kaltura
|
|
188
244
|
def reference_time=(val)
|
189
245
|
@reference_time = val.to_i
|
190
246
|
end
|
247
|
+
|
248
|
+
def from_xml(xml_element)
|
249
|
+
super
|
250
|
+
self.max_results = xml_element.elements['maxResults'].text
|
251
|
+
self.results_file_path = xml_element.elements['resultsFilePath'].text
|
252
|
+
self.reference_time = xml_element.elements['referenceTime'].text
|
253
|
+
end
|
254
|
+
|
191
255
|
end
|
192
256
|
|
193
257
|
class KalturaScheduledTaskProfileBaseFilter < KalturaFilter
|
@@ -233,11 +297,36 @@ module Kaltura
|
|
233
297
|
def last_execution_started_at_less_than_or_equal=(val)
|
234
298
|
@last_execution_started_at_less_than_or_equal = val.to_i
|
235
299
|
end
|
300
|
+
|
301
|
+
def from_xml(xml_element)
|
302
|
+
super
|
303
|
+
self.id_equal = xml_element.elements['idEqual'].text
|
304
|
+
self.id_in = xml_element.elements['idIn'].text
|
305
|
+
self.partner_id_equal = xml_element.elements['partnerIdEqual'].text
|
306
|
+
self.partner_id_in = xml_element.elements['partnerIdIn'].text
|
307
|
+
self.system_name_equal = xml_element.elements['systemNameEqual'].text
|
308
|
+
self.system_name_in = xml_element.elements['systemNameIn'].text
|
309
|
+
self.status_equal = xml_element.elements['statusEqual'].text
|
310
|
+
self.status_in = xml_element.elements['statusIn'].text
|
311
|
+
self.created_at_greater_than_or_equal = xml_element.elements['createdAtGreaterThanOrEqual'].text
|
312
|
+
self.created_at_less_than_or_equal = xml_element.elements['createdAtLessThanOrEqual'].text
|
313
|
+
self.updated_at_greater_than_or_equal = xml_element.elements['updatedAtGreaterThanOrEqual'].text
|
314
|
+
self.updated_at_less_than_or_equal = xml_element.elements['updatedAtLessThanOrEqual'].text
|
315
|
+
self.last_execution_started_at_greater_than_or_equal = xml_element.elements['lastExecutionStartedAtGreaterThanOrEqual'].text
|
316
|
+
self.last_execution_started_at_less_than_or_equal = xml_element.elements['lastExecutionStartedAtLessThanOrEqual'].text
|
317
|
+
end
|
318
|
+
|
236
319
|
end
|
237
320
|
|
238
321
|
class KalturaScheduledTaskProfileListResponse < KalturaListResponse
|
239
322
|
attr_accessor :objects
|
240
323
|
|
324
|
+
|
325
|
+
def from_xml(xml_element)
|
326
|
+
super
|
327
|
+
self.objects = KalturaClientBase.object_from_xml(xml_element.elements['objects'], 'KalturaScheduledTaskProfile')
|
328
|
+
end
|
329
|
+
|
241
330
|
end
|
242
331
|
|
243
332
|
class KalturaStorageExportObjectTask < KalturaObjectTask
|
@@ -245,10 +334,21 @@ module Kaltura
|
|
245
334
|
#
|
246
335
|
attr_accessor :storage_id
|
247
336
|
|
337
|
+
|
338
|
+
def from_xml(xml_element)
|
339
|
+
super
|
340
|
+
self.storage_id = xml_element.elements['storageId'].text
|
341
|
+
end
|
342
|
+
|
248
343
|
end
|
249
344
|
|
250
345
|
class KalturaScheduledTaskProfileFilter < KalturaScheduledTaskProfileBaseFilter
|
251
346
|
|
347
|
+
|
348
|
+
def from_xml(xml_element)
|
349
|
+
super
|
350
|
+
end
|
351
|
+
|
252
352
|
end
|
253
353
|
|
254
354
|
|
@@ -263,83 +363,83 @@ module Kaltura
|
|
263
363
|
#
|
264
364
|
def add(scheduled_task_profile)
|
265
365
|
kparams = {}
|
266
|
-
client.add_param(kparams, 'scheduledTaskProfile', scheduled_task_profile)
|
267
|
-
client.queue_service_action_call('scheduledtask_scheduledtaskprofile', 'add', kparams)
|
366
|
+
client.add_param(kparams, 'scheduledTaskProfile', scheduled_task_profile)
|
367
|
+
client.queue_service_action_call('scheduledtask_scheduledtaskprofile', 'add', 'KalturaScheduledTaskProfile', kparams)
|
268
368
|
if (client.is_multirequest)
|
269
|
-
return nil
|
369
|
+
return nil
|
270
370
|
end
|
271
|
-
return client.do_queue()
|
371
|
+
return client.do_queue()
|
272
372
|
end
|
273
373
|
|
274
374
|
# Retrieve a scheduled task profile by id
|
275
375
|
#
|
276
376
|
def get(id)
|
277
377
|
kparams = {}
|
278
|
-
client.add_param(kparams, 'id', id)
|
279
|
-
client.queue_service_action_call('scheduledtask_scheduledtaskprofile', 'get', kparams)
|
378
|
+
client.add_param(kparams, 'id', id)
|
379
|
+
client.queue_service_action_call('scheduledtask_scheduledtaskprofile', 'get', 'KalturaScheduledTaskProfile', kparams)
|
280
380
|
if (client.is_multirequest)
|
281
|
-
return nil
|
381
|
+
return nil
|
282
382
|
end
|
283
|
-
return client.do_queue()
|
383
|
+
return client.do_queue()
|
284
384
|
end
|
285
385
|
|
286
386
|
# Update an existing scheduled task profile
|
287
387
|
#
|
288
388
|
def update(id, scheduled_task_profile)
|
289
389
|
kparams = {}
|
290
|
-
client.add_param(kparams, 'id', id)
|
291
|
-
client.add_param(kparams, 'scheduledTaskProfile', scheduled_task_profile)
|
292
|
-
client.queue_service_action_call('scheduledtask_scheduledtaskprofile', 'update', kparams)
|
390
|
+
client.add_param(kparams, 'id', id)
|
391
|
+
client.add_param(kparams, 'scheduledTaskProfile', scheduled_task_profile)
|
392
|
+
client.queue_service_action_call('scheduledtask_scheduledtaskprofile', 'update', 'KalturaScheduledTaskProfile', kparams)
|
293
393
|
if (client.is_multirequest)
|
294
|
-
return nil
|
394
|
+
return nil
|
295
395
|
end
|
296
|
-
return client.do_queue()
|
396
|
+
return client.do_queue()
|
297
397
|
end
|
298
398
|
|
299
399
|
# Delete a scheduled task profile
|
300
400
|
#
|
301
401
|
def delete(id)
|
302
402
|
kparams = {}
|
303
|
-
client.add_param(kparams, 'id', id)
|
304
|
-
client.queue_service_action_call('scheduledtask_scheduledtaskprofile', 'delete', kparams)
|
403
|
+
client.add_param(kparams, 'id', id)
|
404
|
+
client.queue_service_action_call('scheduledtask_scheduledtaskprofile', 'delete', '', kparams)
|
305
405
|
if (client.is_multirequest)
|
306
|
-
return nil
|
406
|
+
return nil
|
307
407
|
end
|
308
|
-
return client.do_queue()
|
408
|
+
return client.do_queue()
|
309
409
|
end
|
310
410
|
|
311
411
|
# List scheduled task profiles
|
312
412
|
#
|
313
413
|
def list(filter=KalturaNotImplemented, pager=KalturaNotImplemented)
|
314
414
|
kparams = {}
|
315
|
-
client.add_param(kparams, 'filter', filter)
|
316
|
-
client.add_param(kparams, 'pager', pager)
|
317
|
-
client.queue_service_action_call('scheduledtask_scheduledtaskprofile', 'list', kparams)
|
415
|
+
client.add_param(kparams, 'filter', filter)
|
416
|
+
client.add_param(kparams, 'pager', pager)
|
417
|
+
client.queue_service_action_call('scheduledtask_scheduledtaskprofile', 'list', 'KalturaScheduledTaskProfileListResponse', kparams)
|
318
418
|
if (client.is_multirequest)
|
319
|
-
return nil
|
419
|
+
return nil
|
320
420
|
end
|
321
|
-
return client.do_queue()
|
421
|
+
return client.do_queue()
|
322
422
|
end
|
323
423
|
|
324
424
|
def request_dry_run(scheduled_task_profile_id, max_results=500)
|
325
425
|
kparams = {}
|
326
|
-
client.add_param(kparams, 'scheduledTaskProfileId', scheduled_task_profile_id)
|
327
|
-
client.add_param(kparams, 'maxResults', max_results)
|
328
|
-
client.queue_service_action_call('scheduledtask_scheduledtaskprofile', 'requestDryRun', kparams)
|
426
|
+
client.add_param(kparams, 'scheduledTaskProfileId', scheduled_task_profile_id)
|
427
|
+
client.add_param(kparams, 'maxResults', max_results)
|
428
|
+
client.queue_service_action_call('scheduledtask_scheduledtaskprofile', 'requestDryRun', 'int', kparams)
|
329
429
|
if (client.is_multirequest)
|
330
|
-
return nil
|
430
|
+
return nil
|
331
431
|
end
|
332
|
-
return client.do_queue()
|
432
|
+
return client.do_queue()
|
333
433
|
end
|
334
434
|
|
335
435
|
def get_dry_run_results(request_id)
|
336
436
|
kparams = {}
|
337
|
-
client.add_param(kparams, 'requestId', request_id)
|
338
|
-
client.queue_service_action_call('scheduledtask_scheduledtaskprofile', 'getDryRunResults', kparams)
|
437
|
+
client.add_param(kparams, 'requestId', request_id)
|
438
|
+
client.queue_service_action_call('scheduledtask_scheduledtaskprofile', 'getDryRunResults', 'KalturaObjectListResponse', kparams)
|
339
439
|
if (client.is_multirequest)
|
340
|
-
return nil
|
440
|
+
return nil
|
341
441
|
end
|
342
|
-
return client.do_queue()
|
442
|
+
return client.do_queue()
|
343
443
|
end
|
344
444
|
end
|
345
445
|
|
@@ -351,6 +451,7 @@ module Kaltura
|
|
351
451
|
end
|
352
452
|
return @scheduled_task_profile_service
|
353
453
|
end
|
454
|
+
|
354
455
|
end
|
355
456
|
|
356
457
|
end
|