Class: Kaltura::KalturaWidgetService

Inherits:
KalturaServiceBase show all
Defined in:
lib/kaltura_client.rb

Overview

widget service for full widget management

Instance Attribute Summary

Attributes inherited from KalturaServiceBase

#client

Instance Method Summary collapse

Constructor Details

#initialize(client) ⇒ KalturaWidgetService

Returns a new instance of KalturaWidgetService.



5873
5874
5875
# File 'lib/kaltura_client.rb', line 5873

def initialize(client)
	super(client)
end

Instance Method Details

#add(widget) ⇒ KalturaWidget

Add new widget, can be attached to entry or kshow SourceWidget is ignored.

Returns:



5880
5881
5882
5883
5884
5885
5886
5887
5888
# File 'lib/kaltura_client.rb', line 5880

def add(widget)
	kparams = {}
	client.add_param(kparams, 'widget', widget)
	client.queue_service_action_call('widget', 'add', 'KalturaWidget', kparams)
	if (client.is_multirequest)
		return nil
	end
	return client.do_queue()
end

#clone(widget) ⇒ KalturaWidget

Add widget based on existing widget. Must provide valid sourceWidgetId

Returns:



5893
5894
5895
5896
5897
5898
5899
5900
5901
# File 'lib/kaltura_client.rb', line 5893

def clone(widget)
	kparams = {}
	client.add_param(kparams, 'widget', widget)
	client.queue_service_action_call('widget', 'clone', 'KalturaWidget', kparams)
	if (client.is_multirequest)
		return nil
	end
	return client.do_queue()
end

#get(id) ⇒ KalturaWidget

Get widget by id

Returns:



5905
5906
5907
5908
5909
5910
5911
5912
5913
# File 'lib/kaltura_client.rb', line 5905

def get(id)
	kparams = {}
	client.add_param(kparams, 'id', id)
	client.queue_service_action_call('widget', 'get', 'KalturaWidget', kparams)
	if (client.is_multirequest)
		return nil
	end
	return client.do_queue()
end

#list(filter = KalturaNotImplemented, pager = KalturaNotImplemented) ⇒ KalturaWidgetListResponse

Retrieve a list of available widget depends on the filter given



5917
5918
5919
5920
5921
5922
5923
5924
5925
5926
# File 'lib/kaltura_client.rb', line 5917

def list(filter=KalturaNotImplemented, pager=KalturaNotImplemented)
	kparams = {}
	client.add_param(kparams, 'filter', filter)
	client.add_param(kparams, 'pager', pager)
	client.queue_service_action_call('widget', 'list', 'KalturaWidgetListResponse', kparams)
	if (client.is_multirequest)
		return nil
	end
	return client.do_queue()
end

#update(id, widget) ⇒ KalturaWidget

Update existing widget

Returns:



5930
5931
5932
5933
5934
5935
5936
5937
5938
5939
# File 'lib/kaltura_client.rb', line 5930

def update(id, widget)
	kparams = {}
	client.add_param(kparams, 'id', id)
	client.add_param(kparams, 'widget', widget)
	client.queue_service_action_call('widget', 'update', 'KalturaWidget', kparams)
	if (client.is_multirequest)
		return nil
	end
	return client.do_queue()
end