class Kaltura::KalturaAttachmentAssetService
Retrieve information and invoke actions on attachment Asset
Public Class Methods
new(client)
click to toggle source
Calls superclass method
Kaltura::KalturaServiceBase::new
# File lib/kaltura_plugins/kaltura_attachment_client_plugin.rb, line 157 def initialize(client) super(client) end
Public Instance Methods
add(entry_id, attachment_asset)
click to toggle source
Add attachment asset @return [KalturaAttachmentAsset]
# File lib/kaltura_plugins/kaltura_attachment_client_plugin.rb, line 163 def add(entry_id, attachment_asset) kparams = {} client.add_param(kparams, 'entryId', entry_id) client.add_param(kparams, 'attachmentAsset', attachment_asset) client.queue_service_action_call('attachment_attachmentasset', 'add', 'KalturaAttachmentAsset', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
delete(attachment_asset_id)
click to toggle source
@return []
# File lib/kaltura_plugins/kaltura_attachment_client_plugin.rb, line 175 def delete(attachment_asset_id) kparams = {} client.add_param(kparams, 'attachmentAssetId', attachment_asset_id) client.queue_service_action_call('attachment_attachmentasset', 'delete', '', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
get(attachment_asset_id)
click to toggle source
@return [KalturaAttachmentAsset]
# File lib/kaltura_plugins/kaltura_attachment_client_plugin.rb, line 186 def get(attachment_asset_id) kparams = {} client.add_param(kparams, 'attachmentAssetId', attachment_asset_id) client.queue_service_action_call('attachment_attachmentasset', 'get', 'KalturaAttachmentAsset', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
get_remote_paths(id)
click to toggle source
Get remote storage existing paths for the asset @return [KalturaRemotePathListResponse]
# File lib/kaltura_plugins/kaltura_attachment_client_plugin.rb, line 198 def get_remote_paths(id) kparams = {} client.add_param(kparams, 'id', id) client.queue_service_action_call('attachment_attachmentasset', 'getRemotePaths', 'KalturaRemotePathListResponse', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
get_url(id, storage_id=KalturaNotImplemented)
click to toggle source
Get download URL for the asset @return [string]
# File lib/kaltura_plugins/kaltura_attachment_client_plugin.rb, line 210 def get_url(id, storage_id=KalturaNotImplemented) kparams = {} client.add_param(kparams, 'id', id) client.add_param(kparams, 'storageId', storage_id) client.queue_service_action_call('attachment_attachmentasset', 'getUrl', 'string', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
list(filter=KalturaNotImplemented, pager=KalturaNotImplemented)
click to toggle source
List attachment Assets by filter and pager @return [KalturaAttachmentAssetListResponse]
# File lib/kaltura_plugins/kaltura_attachment_client_plugin.rb, line 223 def list(filter=KalturaNotImplemented, pager=KalturaNotImplemented) kparams = {} client.add_param(kparams, 'filter', filter) client.add_param(kparams, 'pager', pager) client.queue_service_action_call('attachment_attachmentasset', 'list', 'KalturaAttachmentAssetListResponse', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
serve(attachment_asset_id, serve_options=KalturaNotImplemented)
click to toggle source
Serves attachment by its id @return [file]
# File lib/kaltura_plugins/kaltura_attachment_client_plugin.rb, line 236 def serve(attachment_asset_id, serve_options=KalturaNotImplemented) kparams = {} client.add_param(kparams, 'attachmentAssetId', attachment_asset_id) client.add_param(kparams, 'serveOptions', serve_options) client.queue_service_action_call('attachment_attachmentasset', 'serve', 'file', kparams) return client.get_serve_url() end
set_content(id, content_resource)
click to toggle source
Update content of attachment asset @return [KalturaAttachmentAsset]
# File lib/kaltura_plugins/kaltura_attachment_client_plugin.rb, line 246 def set_content(id, content_resource) kparams = {} client.add_param(kparams, 'id', id) client.add_param(kparams, 'contentResource', content_resource) client.queue_service_action_call('attachment_attachmentasset', 'setContent', 'KalturaAttachmentAsset', kparams) if (client.is_multirequest) return nil end return client.do_queue() end
update(id, attachment_asset)
click to toggle source
Update attachment asset @return [KalturaAttachmentAsset]
# File lib/kaltura_plugins/kaltura_attachment_client_plugin.rb, line 259 def update(id, attachment_asset) kparams = {} client.add_param(kparams, 'id', id) client.add_param(kparams, 'attachmentAsset', attachment_asset) client.queue_service_action_call('attachment_attachmentasset', 'update', 'KalturaAttachmentAsset', kparams) if (client.is_multirequest) return nil end return client.do_queue() end