ICCTriggerTypeBuilder interface
Description
You can supply a variety of parameters to DevOps Code ClearCase® to specify how a trigger type operates. The ICCTriggerTypeBuilder interface allows client code to set one or more of these parameters and then use the Create method to create a new trigger type or the Replace method to replace an existing trigger type.
Inheritance

Read-write properties
- DebugPrinting
Gets and sets whether debug printing happens when the trigger fires
- ExemptUsersStringArray
Gets and sets the users for whom this trigger type does not fire
- Firing
Gets and sets the trigger type firing order, which is either before (pre-op) or after (post-op) the operation
- KindOfTrigger
Gets and sets the kind of trigger for this trigger type
- Name (default property)
Gets and sets the name of this trigger type
Read-only properties
- ActionsArray
Gets an array of action and value pairs for this trigger type (that is, a type that is followed by one or two values)
- InclusionsArray
Gets the inclusion list for this type trigger type
- NumberOfActions
Gets the number of actions for this trigger type
- NumberOfExemptUsers
Gets the number of users for whom this trigger type does not fire
- NumberOfInclusions
Gets the number of inclusions for this type trigger type
- NumberOfOperationKinds
Gets the number of operations kinds which fire this trigger type
- NumberOfRestrictions
Gets the number of restrictions for this element trigger type
- OperationKindsArray
Gets an array of kinds of operations which fire this trigger type
- RestrictionsArray
Gets the restriction list for this element trigger type
- VOB
Gets the VOB that contains this trigger type
Methods
- AddExecAction
Adds an exec string action
- AddExecUNIXAction
Adds an exec string action that runs on Linux or the UNIX system
- AddExecWinAction
Adds an exec string action that runs on the Windows system
- AddMkattrAction
Adds a make attribute action
- AddMkhlinkFromAction
Adds a make hyperlink 'from' action
- AddMkhlinkToAction
Adds a make hyperlink 'to' action
- AddMklabelAction
Adds a make label action
- Create
Creates the new trigger type
- FireOn
Adds a kind of operation that fires this trigger type
- IncludeOn
Adds an item to the type inclusion list for this type trigger type
- RemoveAction
Removes the numbered action from trigger firing actions
- RemoveInclusion
Removes the item from the type inclusion list for this type trigger type
- RemoveOperationKind
Sets the trigger type not to fire on this kind of operation
- RemoveRestriction
Removes the item from the type restriction list for this element trigger type
- Replace
Redefines the trigger type that is represented by this trigger type builder
- RestrictBy
Adds the item to the type restriction list for this element trigger type
Examples
Creation
ActionsArray
Gets an array of action and value pairs for this trigger type (that is, a type that is followed by one or two values)
Category
Read-only property
VB syntax
Property ActionsArray As Variant
Visual C++ syntax
_variant_t GetActionsArray();
Return value
An array of Variants that contains CCTriggerActionType values. Use the array index to specify the action for RemoveAction to remove.
AddExecAction
Adds an exec string action
Category
Method
VB syntax
Sub AddExecAction(Action As String)
Visual C++ syntax
HRESULT AddExecAction(_bstr_t Action);
- Parameter
- Description
- Action
- The command line to execute when the trigger fires.
AddExecUNIXAction
Adds an exec string action that runs on Linux or the UNIX system
Category
Method
VB syntax
Sub AddExecUNIXAction(Action As String)
Visual C++ syntax
HRESULT AddExecUNIXAction(_bstr_t Action);
- Parameter
- Description
- Action
- The command line to execute when the trigger fires on Linux or the UNIX system.
AddExecWinAction
Adds an exec string action that runs on the Windows system
Category
Method
VB syntax
Sub AddExecWinAction(Action As String)
Visual C++ syntax
HRESULT AddExecWinAction(_bstr_t Action);
- Parameter
- Description
- Action
- The command line to execute when the trigger fires on a Windows system.
AddMkattrAction
Adds a make attribute action
Category
Method
VB syntax
Sub AddMkattrAction(pAttributeType As CCAttributeType, Value As Variant)
Visual C++ syntax
HRESULT AddMkattrAction( ICCAttributeType* pAttributeType, const _variant_t& Value);
- Parameter
- Description
- pAttributeType
- The attribute type to apply when the trigger fires.
- Value
- The value to give the new attribute. Value's type must match the attribute type's ValueType.
AddMkhlinkFromAction
Adds a make hyperlink 'from' action
Category
Method
VB syntax
Sub AddMkhlinkFromAction(pHyperlinkType As CCHyperlinkType, FromPath As String)
Visual C++ syntax
HRESULT AddMkhlinkFromAction( ICCHyperlinkType* pHyperlinkType, _bstr_t FromPath);
- Parameter
- Description
- pHyperlinkType
- The hyperlink type to apply when the trigger fires.
- FromPath
- The path to the "from" object of the new hyperlink.
AddMkhlinkToAction
Adds a make hyperlink 'to' action
Category
Method
VB syntax
Sub AddMkhlinkToAction(pHyperlinkType As CCHyperlinkType, ToPath As String)
Visual C++ syntax
HRESULT AddMkhlinkToAction( ICCHyperlinkType* pHyperlinkType, _bstr_t ToPath);
- Parameter
- Description
- pHyperlinkType
- The hyperlink type to apply when the trigger fires.
- ToPath
- The path to the "to" object of the new hyperlink.
AddMklabelAction
Adds a make label action
Category
Method
VB syntax
Sub AddMklabelAction(pLabelType As CCLabelType)
Visual C++ syntax
HRESULT AddMklabelAction(ICCLabelType* pLabelType);
- Parameter
- Description
- pLabelType
- The label type to apply when the trigger fires.
Create
Creates the new trigger type
Category
Method
VB syntax
Function Create([ Comment As String ="" ]) As CCTriggerType
Visual C++ syntax
ICCTriggerTypePtr Create(_bstr_t Comment);
- Parameter
- Description
- Comment
- Optional in Visual Basic. A comment to associate with the history record for this Create operation.
Remarks
Before the trigger type builder can be used to create a trigger type, it must have one or more operations, one or more actions, and Name must be set. In addition, type triggers must have one or more restrictions.
DebugPrinting
Gets and sets whether debug printing happens when the trigger fires
Category
Read-write property
VB syntax
Property DebugPrinting As Boolean
Visual C++ syntax
VARIANT_BOOL GetDebugPrinting(); void PutDebugPrinting(VARIANT_BOOL NewDebugPrinting);
- Parameter
- Description
- NewDebugPrinting
- Visual C++ only. True to enable debug printing when the trigger fires; False to disable debug printing when this trigger fires.
Remarks
DebugPrinting is for debugging purposes only. The debug output goes to stdout. To see the output, you must test the trigger from the command line. When you finish debugging, disable debug printing to avoid confusing those invoking the trigger
Member of: ICCTriggerTypeBuilder interface
ExemptUsersStringArray
Gets and sets the users for whom this trigger type does not fire
Category
Read-write property
VB syntax
Property ExemptUsersStringArray As Variant
Visual C++ syntax
_variant_t GetExemptUsersStringArray(); void PutExemptUsersStringArray(const _variant_t& NewExemptUsersStringArray);
- Parameter
- Description
- NewExemptUsersStringArray
- Visual C++ only. An array of Variants that contains String values representing the names of users exempted from the firing of triggers for this new trigger type.
Remarks
An array of Variants that contains String values represents the names of users exempted from the firing of triggers for this trigger type.
FireOn
Adds a kind of operation that fires this trigger type
Category
Method
VB syntax
Sub FireOn(OperationKind As CCTriggerOperationKind)
Visual C++ syntax
HRESULT FireOn(CCTriggerOperationKind OperationKind);
- Parameter
- Description
- OperationKind
- The DevOps Code ClearCase operation that causes the trigger to fire. Must be one of the valid CCTriggerOperationKind values.
Firing
Gets and sets the trigger type firing order, which is either before (pre-op) or after (post-op) the operation
Category
Read-write property
VB syntax
Property Firing As CCTriggerFiring
Visual C++ syntax
CCTriggerFiring GetFiring(); void PutFiring(CCTriggerFiring NewFiring);
- Parameter
- Description
- NewFiring
- Visual C++ only. The trigger type firing order. Must be one of the valid CCTriggerFiring values.
Remarks
A CCTriggerFiring value specifies when the trigger will fire.
Member of: ICCTriggerTypeBuilder interface
IncludeOn
Adds an item to the type inclusion list for this type trigger type
Category
Method
VB syntax
Sub IncludeOn(InclusionType As Variant)
Visual C++ syntax
HRESULT IncludeOn(const _variant_t& InclusionType);
- Parameter
- Description
- InclusionType
- The item to add to the inclusion list. Specify a CCTriggerTypesAll value for all metadata types of a particular kind (for example, all attribute types), an object pointer for a specific metadata type (for example, a particular ICCAttributeType), or a String value for a specific element type (for example, text_file).
See also
Member of: ICCTriggerTypeBuilder interface
InclusionsArray
Gets the inclusion list for this type trigger type
Category
Read-only property
VB syntax
Property InclusionsArray As Variant
Visual C++ syntax
_variant_t GetInclusionArray();
Return value
An array of Variants that represents the inclusion list, containing CCTriggerTypeAll values, object pointers, or String values. A CCTriggerTypesAll value is returned for all metadata types of a particular kind (for example, all attribute types), an object pointer for a specific metadata type (for example, a particular CCAttributeType), or a String value for the name of a specific element type (for example, "text_file").
KindOfTrigger
Gets and sets the kind of trigger for this trigger type
Category
Read-write property
VB syntax
Property KindOfTrigger As CCKindOfTrigger
Visual C++ syntax
CCKindOfTrigger GetKindOfTrigger(); void PutKindOfTrigger(CCKindOfTrigger NewKind);
- Parameter
- Description
- NewKind
- Visual C++ only. The kind of trigger. Must be one of the valid CCKindOfTrigger values.
Remarks
A CCKindOfTrigger value specifies the kind of trigger.
Member of: ICCTriggerTypeBuilder interface
Name
Gets and sets the name of this trigger type
Category
Read-write property
VB syntax
Property Name As String
Visual C++ syntax
_bstr_t GetName(); void PutName(_bstr_t NewName);
- Parameter
- Description
- NewName
- Visual C++ only. The new name for the trigger type.
Remarks
You cannot use the ICCTriggerTypeBuilder interface to rename a trigger. Once you set the Name of a trigger type builder, you can only use that builder to create a new trigger type, and not to replace an existing one.
Member of: ICCTriggerTypeBuilder interface
NumberOfActions
Gets the number of actions for this trigger type
Category
Read-only property
VB syntax
Property NumberOfActions As Long
Visual C++ syntax
long GetNumberOfActions();
NumberOfExemptUsers
Gets the number of users for whom this trigger type does not fire
Category
Read-only property
VB syntax
Property NumberOfExemptUsers As Long
Visual C++ syntax
long GetNumberOfExemptUsers();
NumberOfInclusions
Gets the number of inclusions for this type trigger type
Category
Read-Only Property
VB syntax
Property NumberOfInclusions As Long
Visual C++ syntax
long GetNumberOfInclusions();
NumberOfOperationKinds
Gets the number of operations kinds which fire this trigger type
Category
Read-only property
VB syntax
Property NumberOfOperationKinds As Long
Visual C++ syntax
long GetNumberOfOperationKinds();
NumberOfRestrictions
Gets the number of restrictions for this element trigger type
Category
Read-only property
VB syntax
Property NumberOfRestrictions As Long
Visual C++ syntax
long GetNumberOfRestrictions();
OperationKindsArray
Gets an array of kinds of operations which fire this trigger type
Category
Read-only property
VB syntax
Property OperationKindsArray As Variant
Visual C++ syntax
_variant_t GetOperationKindsArray();
Return value
An array of Variants that contains CCTriggerOperationKind values.
See also
Member of: ICCTriggerTypeBuilder interface
RemoveAction
Removes the numbered action from trigger firing actions
Category
Method
VB syntax
Sub RemoveAction(Index As Long)
Visual C++ syntax
HRESULT RemoveAction(long Index);
- Parameter
- Description
- Index
- The 0-based index into the array of trigger type actions, as returned by ActionsArray.
RemoveInclusion
Removes the item from the type inclusion list for this type trigger type
Category
Method
VB syntax
Sub RemoveInclusion(InclusionType As Variant)
Visual C++ syntax
HRESULT RemoveInclusion(const _variant_t& InclusionType);
- Parameter
- Description
- InclusionType
- The item to remove from the inclusion list. Specify a CCTriggerTypesAll value for all metadata types of a particular kind (for example, all attribute types), an object pointer for a specific metadata type (for example, a particular ICCAttributeType), or a String value for a specific element type (for example, "text_file").
RemoveOperationKind
Sets the trigger type not to fire on this kind of operation
Category
Method
VB syntax
Sub RemoveOperationKind(OperationKind As CCTriggerOperationKind)
Visual C++ syntax
HRESULT RemoveOperationKind(CCTriggerOperationKind OperationKind);
- Parameter
- Description
- OperationKind
- The operation kind to remove from the list of operations for which a trigger fires. Must be one of the valid CCTriggerOperationKind values.
See also
Member of: ICCTriggerTypeBuilder interface
RemoveRestriction
Removes the item from the type restriction list for this element trigger type
Category
Method
VB syntax
Sub RemoveRestriction(RestrictionType As Variant)
Visual C++ syntax
HRESULT RemoveRestriction(const _variant_t& RestrictionType);
- Parameter
- Description
- RestrictionType
- The item to remove from the restriction list. Specify an object pointer for a specific metadata type (for example, a particular ICCAttributeType) or a String value for a specific element type (for example, "text_file").
See also
Member of: ICCTriggerTypeBuilder interface
Replace
Redefines the trigger type that is represented by this trigger type builder
Category
Method
VB syntax
Function Replace([ Comment As String = "" ]) As CCTriggerType
Visual C++ syntax
ICCTriggerTypePtr Replace(_bstr_t Comment);
- Parameter
- Description
- Comment
- Optional in Visual Basic. A comment to associate with the history record for this Replace operation.
Remarks
The trigger type must exist before it can be replaced.
You cannot rename a trigger using the ICCTriggerTypeBuilder interface. Once you set the Name of a trigger type builder, you can only use that builder to create a new trigger type, and not to replace an existing one.
RestrictBy
Adds the item to the type restriction list for this element trigger type
Category
Method
VB syntax
Sub RestrictBy(RestrictionType As Variant)
Visual C++ syntax
HRESULT RestrictBy(const _variant_t& RestrictionType);
- Parameter
- Description
- RestrictionType
- The item to add to the restriction list. Specify an object pointer for a specific metadata type (for example, a particular ICCAttributeType) or a String value for a specific element type (for example, "text_file").
See also
Member of: ICCTriggerTypeBuilder interface
RestrictionsArray
Gets the restriction list for this element trigger type
Category
Read-only property
VB syntax
Property RestrictionsArray As Variant
Visual C++ syntax
_variant_t GetRestrictionsArray();
Return value
An array of Variants that represents the restriction list, containing object pointers or String values. An object pointer is returned for a specific metadata type (for example, a particular CCAttributeType), or a String value for the name of a specific element type (for example, "text_file").
See also
Member of: ICCTriggerTypeBuilder interface
VOB
Gets the VOB that contains this trigger type
Category
Read-only property
VB syntax
Property VOB As CCVOB