ConditionControl

class HPS.ConditionControl : HPS.Control

The ConditionControl class is a smart pointer that is tied to a database object. This class is used to set and unset conditions on a segment. A condition can be used to control when a style is applied, or to control when an included segment is included.

Public Functions

HPS.ConditionControl AddCondition (string in_condition)

Adds a condition to the collection of active conditions on this segment.

Param in_condition:
 the condition to enable.
Return:a reference to this object.
ConditionControl (HPS.ConditionControl in_that)

Initializes a control tied to the same object as in_that.

ConditionControl (HPS.SegmentKey in_seg)

Initializes a control tied to the segment in_seg.

override void Dispose ()
ulong GetCount ()

Retrieves the number of conditions set on this segment.

Return:The number of conditions set on this segment.
override HPS.Type ObjectType ()

This function returns the type the object, as declared (if the object is derived, this does not give the true type of the derived object).

Return:The declared type of the object in question, which may differ from the true, underlying type.
HPS.ConditionControl SetCondition (string in_condition)

Sets a condition as the only active condition on this segment, replacing any existing conditions.

Param in_condition:
 the condition to enable.
Return:a reference to this object.
HPS.ConditionControl SetConditions (string[] in_conditions)

Sets a collection of conditions as the only active conditions on this segment, replacing any existing conditions.

Param in_conditions:
 An array of conditions to enable.
Return:a reference to this object.
bool ShowCondition (string in_condition)

Queries the existence of one condition on this segment.

Param in_condition:
 The condition in question.
Return:true if the setting is valid, false otherwise.
bool ShowConditions (out string[] out_conditions)
HPS.ConditionControl UnsetCondition (string in_condition)

Removes a specified condition from the active conditions on this segment.

Param in_condition:
 The condition to remove.
Return:a reference to this object.
HPS.ConditionControl UnsetEverything ()

Unsets all conditions on this segment.

Return:a reference to this object.