Class: Kaltura::KalturaRule

Inherits:
KalturaObjectBase show all
Defined in:
lib/kaltura_types.rb

Instance Attribute Summary collapse

Attributes inherited from KalturaObjectBase

#object_type, #related_objects

Instance Method Summary collapse

Methods inherited from KalturaObjectBase

#camelcase, #to_b, #to_params

Instance Attribute Details

#actionsObject

Actions to be performed by the player in case the rule is fulfilled



174
175
176
# File 'lib/kaltura_types.rb', line 174

def actions
  @actions
end

#conditionsObject

Conditions to validate the rule



177
178
179
# File 'lib/kaltura_types.rb', line 177

def conditions
  @conditions
end

#contextsObject

Indicates what contexts should be tested by this rule



180
181
182
# File 'lib/kaltura_types.rb', line 180

def contexts
  @contexts
end

#messageObject

Message to be thrown to the player in case the rule is fulfilled



171
172
173
# File 'lib/kaltura_types.rb', line 171

def message
  @message
end

#stop_processingObject

Indicates that this rule is enough and no need to continue checking the rest of the rules



183
184
185
# File 'lib/kaltura_types.rb', line 183

def stop_processing
  @stop_processing
end

Instance Method Details

#from_xml(xml_element) ⇒ Object



189
190
191
192
193
194
195
196
# File 'lib/kaltura_types.rb', line 189

def from_xml(xml_element)
	super
	self.message = xml_element.elements['message'].text
	self.actions = KalturaClientBase.object_from_xml(xml_element.elements['actions'], 'KalturaRuleAction')
	self.conditions = KalturaClientBase.object_from_xml(xml_element.elements['conditions'], 'KalturaCondition')
	self.contexts = KalturaClientBase.object_from_xml(xml_element.elements['contexts'], 'KalturaContextTypeHolder')
	self.stop_processing = xml_element.elements['stopProcessing'].text
end