| MainSynchronizeTwoWayReferenceFull Method |
Method will synchronize the values of a two-way reference between two data object types. For all objects of the two dataobjectypes.
Example: in an ITIL scenario we operate with incidents and problems between which there is a relation.
To model the scenario in OE we have two dataobjecttypes - one for incidents and one for problems.
OE doesn't support two-way relations so to accomodate we create two reference properties called
"related problems" (placed on the incident type) and "related incidents" (placed on the problem type).
To ensure that they are synchronized this method is called whenever either an incident or a problem is created or updated.
Codemethod usage | |
---|
Designed to be used in a process only (Yes/No) | No |
Action Object (data object type) | ActionObject |
Namespace:
Omada.OE.UtilityCodeAssembly
Assembly:
Omada.OE.UtilityCodeAssembly (in Omada.OE.UtilityCodeAssembly.dll) Version: 15.0.0.0
Syntaxpublic bool SynchronizeTwoWayReferenceFull(
CodeMethodInvokeContext context,
string forwardDataObjectTypeUIdStr,
string forwardRefPropertySysName,
string backwardDataObjectTypeUIdStr,
string backwardsRefPropertySysName
)
Parameters
- context
- Type: Omada.OE.ModelCodeMethodInvokeContext
An invoke context object.
- forwardDataObjectTypeUIdStr
- Type: SystemString
DataObjecttype UID for forward synchronisation.
- forwardRefPropertySysName
- Type: SystemString
Id of a reference property, that is present on the dataobjecttype of the updated dataobject (ex. an incident).
The dataobjects (ex. problems) that are referred in the property must have (another) reference property
that points backwards to the changed dataobject.
- backwardDataObjectTypeUIdStr
- Type: SystemString
DataObject type UID for Backward synchronisation.
- backwardsRefPropertySysName
- Type: SystemString
Id of a reference property, that is present on the dataobjecttype of the referred dataobjects (ex. problems).
The reference property must point back to the referring dataobjecttype (ex. incidents).
Return Value
Type:
Boolean
See Also