HP Operations Manager for Windows

OV_ServiceTypeDefinition::AddAntecedentServiceType()
OV_ServiceTypeDefinition::AddAntecedentServiceType_Trans()


boolean AddAntecedentServiceType(
[in] string AntecedentGUID,
[in] string PropRuleId)
boolean AddAntecedentServiceType_Trans(
[in] string TransId,
[in] string AntecedentGUID,
[in] string PropRuleId)

Parameters

TransId
Transaction ID returned from OV_Transaction::Start().
AntecedentGUID
The GUID property of the instance of OV_ServiceTypeDefinition on which this service type depends. If the service type does not exist, the method fails with MDLAPI_E_SERVICETYPE_NOT_EXIST.
PropRuleId
The MsgPropRuleId property of this service type dependency.

Calling Convention

These methods can be called only from a WMI instance object.

Description

Adds a dependency relationship between this service type and the specified service type (instance of OV_ServiceTypeDefinition).

Before dependency is created, verify the following: - This service type is already dependent on the specified service type. - The specified service type is the parent (not just immediately) of this service type. - The dependency cycle is detected in the service type model. If the service type dependency cycle is detected, the method fails with MDLAPI_E_SVC_TYPE_DEP_CYCLE_DETECTED..

Return Value

False if the relationship already exists (this service type is already dependent on the specified service type).

Extended Status Codes

MDLAPI_E_SERVICETYPE_NOT_EXIST
Service type does not exist.
MDLAPI_E_SVC_TYPE_DEP_CYCLE_DETECTED
Specified operation cannot be executed because a service type dependency cycle has been detected.
MDLAPI_E_PROPRULE_NOT_EXIST
Message propagation rule does not exist.
MDLAPI_E_TRANSACTION_NOT_EXIST
Transaction with the specified ID does not exist.