Class AssociationService
All the WebServices methods have return type String - meaning if the method is execution is successful, then it will return a string in the form of JSON or XML String based on the outputFormat parameter given by the user.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateAssociation(String userName, String password, String outputFormat, String association) Creates the association for the given association object.createAssociations(String userName, String password, String outputFormat, String associations) Creates the associations for the given list of association objects.deleteAssociation(String userName, String password, String outputFormat, int associationId) Deletes the association with the specified associationId.deleteAssociations(String userName, String password, String outputFormat, String associationIds) Deletes the associations with the specified list of associationIds.deleteAssociationsByObjectType(String userName, String password, String outputFormat, int objectId, int objectTypeId) Deletes the associations with the specified objectId and objectTypeId.getAssociation(String userName, String password, String outputFormat, int associationId, boolean fillInfo) Returns the association object for the specified associationId.getAssociations(String userName, String password, String outputFormat, String associationIds, boolean fillInfo) Returns the list association objects for the specified list of associationIds.getAssociationsByObjectType(String userName, String password, String outputFormat, int objectId, int objectTypeId, boolean fillInfo) Returns the list association objects for the specified objectId and objectTypeId.Specifying the objectId and objectTypeId is mandatory.updateAssociation(String userName, String password, String outputFormat, String association) Updates the association for the given association object.updateAssociations(String userName, String password, String outputFormat, String associations) Updates the associations for the given list of association objects.
-
Constructor Details
-
AssociationService
public AssociationService()
-
-
Method Details
-
createAssociation
public String createAssociation(String userName, String password, String outputFormat, String association) Creates the association for the given association object. Specifying the sourceObjectId, sourceObjectTypeId, targetObjectId, targetObjectTypeId are mandatory, while creating the association.
OutputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.- Parameters:
userName- Stringpassword- StringoutputFormat- String- Valid values: JSON or XMLassociation- String- Returns:
- String - If association is created successfully, it will return
requestStatus object consisting of request success flag, status message
and userObject etc... in the form of JSON or XML String.
Sample 'Association' JSON :
{
"id": 0,
"sourceObjectId": 0,
"sourceObjectTypeId": 0,
"targetObjectId": 0,
"targetObjectTypeId": 0,
"qualifierObjectId": 0,
"qualifierObjectTypeId": 0,
"fields": {},
"relationship":{
"id": "",
"masterId": "",
"titleForward": "",
"titleReverse": "",
"description":"",
"definedBy": "SYSTEM",
"relationshipType": "FORWARD"
}
} - Since:
- 12.0
-
createAssociations
public String createAssociations(String userName, String password, String outputFormat, String associations) Creates the associations for the given list of association objects. Specifying the sourceObjectId, sourceObjectTypeId, targetObjectId, targetObjectTypeId in each association object are mandatory, while creating the associations.
OutputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.- Parameters:
userName- Stringpassword- StringoutputFormat- String- Valid values: JSON or XMLassociations- String- Returns:
- String - If associations are created successfully, it will return
requestStatus object consisting of request success flag, status message
and userObject etc... in the form of JSON or XML String.
Sample 'Associations' JSON :
[
{
"id": 0,
"sourceObjectId": 0,
"sourceObjectTypeId": 0,
"targetObjectId": 0,
"targetObjectTypeId": 0,
"qualifierObjectId": 0,
"qualifierObjectTypeId": 0,
"fields": {},
"relationship":{
"id": "",
"masterId": "",
"titleForward": "",
"titleReverse": "",
"description":"",
"definedBy": "SYSTEM",
"relationshipType": "FORWARD"
}
},
{
" id": 0,
"sourceObjectId": 0,
"sourceObjectTypeId": 0,
"targetObjectId": 0,
"targetObjectTypeId": 0,
"qualifierObjectId": 0,
"qualifierObjectTypeId": 0,
"fields": {},
"relationship":{
"id": "",
"masterId": "",
"titleForward": "",
"titleReverse": "",
"description":"",
"definedBy": "SYSTEM",
"relationshipType": "FORWARD"
}
}
] - Since:
- 12.0
-
updateAssociation
public String updateAssociation(String userName, String password, String outputFormat, String association) Updates the association for the given association object. Specifying the sourceObjectId, sourceObjectTypeId, targetObjectId, targetObjectTypeId are mandatory, to update the association.
OutputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.- Parameters:
userName- Stringpassword- StringoutputFormat- String- Valid values: JSON or XMLassociation-- Returns:
- String - If association is updated successfully, it will return
requestStatus object consisting of request success flag, status message
and userObject etc... in the form of JSON or XML String.
Sample 'Association' JSON :
{
"id": 0,
"sourceObjectId": 0,
"sourceObjectTypeId": 0,
"targetObjectId": 0,
"targetObjectTypeId": 0,
"qualifierObjectId": 0,
"qualifierObjectTypeId": 0,
"fields": {},
"relationship":{
"id": "",
"masterId": "",
"titleForward": "",
"titleReverse": "",
"description":"",
"definedBy": "SYSTEM",
"relationshipType": "FORWARD"
}
} - Since:
- 12.0
-
updateAssociations
public String updateAssociations(String userName, String password, String outputFormat, String associations) Updates the associations for the given list of association objects. Specifying the sourceObjectId, sourceObjectTypeId, targetObjectId, targetObjectTypeId in each association object are mandatory, to update the associations.
OutputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.- Parameters:
userName- Stringpassword- StringoutputFormat- String- Valid values: JSON or XMLassociations- String - List of association objects- Returns:
- String - If associations are updated successfully, it will return
requestStatus object consisting of request success flag, status message
and userObject etc... in the form of JSON or XML String.
Sample 'Associations' JSON :
[
{
"id": 0,
"sourceObjectId": 0,
"sourceObjectTypeId": 0,
"targetObjectId": 0,
"targetObjectTypeId": 0,
"qualifierObjectId": 0,
"qualifierObjectTypeId": 0,
"fields": {},
"relationship":{
"id": "",
"masterId": "",
"titleForward": "",
"titleReverse": "",
"description":"",
"definedBy": "SYSTEM",
"relationshipType": "FORWARD"
}
},
{
" id": 0,
"sourceObjectId": 0,
"sourceObjectTypeId": 0,
"targetObjectId": 0,
"targetObjectTypeId": 0,
"qualifierObjectId": 0,
"qualifierObjectTypeId": 0,
"fields": {},
"relationship":{
"id": "",
"masterId": "",
"titleForward": "",
"titleReverse": "",
"description":"",
"definedBy": "SYSTEM",
"relationshipType": "FORWARD"
}
}
] - Since:
- 12.0
-
deleteAssociation
public String deleteAssociation(String userName, String password, String outputFormat, int associationId) Deletes the association with the specified associationId. Specifying the associationId is mandatory to delete a particular association.
If the association is deleted all its associated data will also be deleted.
OutputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.- Parameters:
userName- Stringpassword- StringoutputFormat- String- Valid values: JSON or XMLassociationId- int- Returns:
- String - If association is deleted successfully, it will return requestStatus object consisting of request success flag, status message and userObject etc... in the form of JSON or XML String.
- Since:
- 12.0
-
deleteAssociations
public String deleteAssociations(String userName, String password, String outputFormat, String associationIds) Deletes the associations with the specified list of associationIds. Specifying the associationIds list is mandatory.
If the associations are deleted all its associated data will also be deleted.
OutputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.- Parameters:
userName- Stringpassword- StringoutputFormat- String- Valid values: JSON or XMLassociationIds- String - List- Returns:
- String - If associations are deleted successfully, it will return requestStatus object consisting of request success flag, status message and userObject etc... in the form of JSON or XML String.
- Since:
- 12.0
-
deleteAssociationsByObjectType
public String deleteAssociationsByObjectType(String userName, String password, String outputFormat, int objectId, int objectTypeId) Deletes the associations with the specified objectId and objectTypeId. Specifying the objectId and objectTypeId are mandatory.
If the associations are deleted all its associated data will also be deleted.
OutputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.- Parameters:
userName- Stringpassword- StringoutputFormat- String- Valid values: JSON or XMLobjectId- intobjectTypeId- int- Returns:
- String - If associations are deleted successfully, it will return requestStatus object consisting of request success flag, status message and userObject etc... in the form of JSON or XML String.
- Since:
- 12.0
-
getAssociation
public String getAssociation(String userName, String password, String outputFormat, int associationId, boolean fillInfo) Returns the association object for the specified associationId. Specifying the associationId is mandatory. FillInfo takes the values as true or false. If fillInfo is true it returns the association object filled with source and target object details. If it is false it return only the association details.
It returns all the details like association name, description, auditHistory details etc..
OutputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.- Parameters:
userName- Stringpassword- StringoutputFormat- String- Valid values: JSON or XMLassociationId- intfillInfo- boolean- Returns:
- String - Association object in the form of JSON or XML.
- Since:
- 12.0
-
getAssociations
public String getAssociations(String userName, String password, String outputFormat, String associationIds, boolean fillInfo) Returns the list association objects for the specified list of associationIds. Specifying the list of associationIds is mandatory.
FillInfo takes the values as true or false. If fillInfo is true it returns the association object filled with source and target object details. If it is false it return only the association details.
It returns all the details like association name, description, auditHistory details etc..
OutputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.- Parameters:
userName- Stringpassword- StringoutputFormat- String- Valid values: JSON or XMLassociationIds- String - ListfillInfo- boolean- Returns:
- String - List of Association objects in the form of JSON or XML.
- Since:
- 12.0
-
getAssociationsByObjectType
public String getAssociationsByObjectType(String userName, String password, String outputFormat, int objectId, int objectTypeId, boolean fillInfo) Returns the list association objects for the specified objectId and objectTypeId.Specifying the objectId and objectTypeId is mandatory.
FillInfo takes the values as true or false. If fillInfo is true it returns the association object filled with source and target object details. If it is false it return only the association details.
It returns all the details like association name, description, auditHistory details etc..
OutputFormat can be either JSON or XML. If outputFormat is not specified, by default the method will return the JSON String.- Parameters:
userName- Stringpassword- StringoutputFormat- String- Valid values: JSON or XMLobjectId- intobjectTypeId- intfillInfo- boolean- Returns:
- String - List of Association objects in the form of JSON or XML.
- Since:
- 12.0
-