public class OpenMetadataAPIGenericBuilder extends Object
| Modifier and Type | Field and Description |
|---|---|
protected RepositoryErrorHandler |
errorHandler |
protected List<Classification> |
existingClassifications |
protected Map<String,Object> |
extendedProperties |
protected InstanceStatus |
instanceStatus |
protected Map<String,Classification> |
newClassifications |
protected InstanceProperties |
properties |
protected OMRSRepositoryHelper |
repositoryHelper |
protected String |
serverName |
protected String |
serviceName |
protected String |
typeGUID |
protected String |
typeName |
| Modifier | Constructor and Description |
|---|---|
protected |
OpenMetadataAPIGenericBuilder(String typeGUID,
String typeName,
Map<String,Object> extendedProperties,
InstanceStatus instanceStatus,
List<Classification> existingClassifications,
OMRSRepositoryHelper repositoryHelper,
String serviceName,
String serverName)
Constructor for type specific creates.
|
protected |
OpenMetadataAPIGenericBuilder(String typeGUID,
String typeName,
OMRSRepositoryHelper repositoryHelper,
String serviceName,
String serverName)
Constructor for working with classifications.
|
| Modifier and Type | Method and Description |
|---|---|
InstanceProperties |
getEntityClassificationProperties(String elementClassificationName,
String methodName)
Retrieve the requested classification and convert it to the OMRS format.
|
List<Classification> |
getEntityClassifications(String userId,
String methodName)
Return a list of entity classifications that can be stored in the metadata
repository.
|
InstanceAuditHeader |
getExistingEntityClassificationHeader(String elementClassificationName,
String methodName)
Retrieve the requested classification and convert it to the OMRS format.
|
InstanceProperties |
getInstanceProperties(String methodName)
Return the supplied bean properties in an InstanceProperties object.
|
InstanceStatus |
getInstanceStatus()
Return the status that this entity should be created with.
|
String |
getTypeGUID()
Return the bean's type id
|
String |
getTypeName()
Return the bean's type name
|
void |
setAnchors(String userId,
String anchorGUID,
String methodName)
Set up the Anchors classification for this entity.
|
void |
setClassification(Classification newClassification)
Add a classification to the entity.
|
void |
setLatestChange(String userId,
int latestChangeTargetOrdinal,
int latestChangeActionOrdinal,
String classificationName,
String attachmentGUID,
String attachmentTypeName,
String relationshipTypeName,
String actionDescription,
String methodName)
Set up the LatestChange classification for an anchor entity.
|
void |
setTemplateClassifications(String userId,
String externalSourceGUID,
String externalSourceName,
List<Classification> templateClassifications,
String methodName)
Set up the list of classifications from a template entity.
|
protected RepositoryErrorHandler errorHandler
protected OMRSRepositoryHelper repositoryHelper
protected String serviceName
protected String serverName
protected String typeGUID
protected String typeName
protected InstanceStatus instanceStatus
protected List<Classification> existingClassifications
protected Map<String,Classification> newClassifications
protected InstanceProperties properties
protected OpenMetadataAPIGenericBuilder(String typeGUID, String typeName, OMRSRepositoryHelper repositoryHelper, String serviceName, String serverName)
typeGUID - type GUID to use for the entitytypeName - type name to use for the entityrepositoryHelper - helper methodsserviceName - name of this OMASserverName - name of local serverprotected OpenMetadataAPIGenericBuilder(String typeGUID, String typeName, Map<String,Object> extendedProperties, InstanceStatus instanceStatus, List<Classification> existingClassifications, OMRSRepositoryHelper repositoryHelper, String serviceName, String serverName)
typeGUID - type GUID to use for the entitytypeName - type name to use for the entityextendedProperties - properties for the sub type (if any)instanceStatus - status to use on the requestexistingClassifications - classifications that are currently storedrepositoryHelper - helper methodsserviceName - name of this OMASserverName - name of local serverpublic void setClassification(Classification newClassification)
newClassification - classification object ready for the repositorypublic void setTemplateClassifications(String userId, String externalSourceGUID, String externalSourceName, List<Classification> templateClassifications, String methodName) throws InvalidParameterException
userId - calling userexternalSourceGUID - guid of the software server capability entity that represented the external source - null for localexternalSourceName - name of the software server capability entity that represented the external sourcetemplateClassifications - list of classifications from the templatemethodName - calling methodInvalidParameterException - the type of one of the classifications is not supportedpublic void setAnchors(String userId, String anchorGUID, String methodName) throws InvalidParameterException
userId - calling useranchorGUID - unique identifier of the anchor entity that this entity is linked to directly or indirectlymethodName - calling methodInvalidParameterException - anchors is not supported in the local repository, or any repository
connected by an open metadata repository cohortpublic void setLatestChange(String userId, int latestChangeTargetOrdinal, int latestChangeActionOrdinal, String classificationName, String attachmentGUID, String attachmentTypeName, String relationshipTypeName, String actionDescription, String methodName) throws InvalidParameterException
userId - calling userlatestChangeTargetOrdinal - ordinal for the LatestChangeTarget enum valuelatestChangeActionOrdinal - ordinal for the LatestChangeAction enum valueclassificationName - name of a changed classificationattachmentGUID - unique identifier of an entity attached to the anchorattachmentTypeName - type name of the attached entityrelationshipTypeName - relationship used to attach the entityactionDescription - human readable description of the changemethodName - calling methodInvalidParameterException - this classification is not supportedpublic String getTypeName()
public String getTypeGUID()
public InstanceStatus getInstanceStatus()
public InstanceProperties getInstanceProperties(String methodName) throws InvalidParameterException
methodName - name of the calling methodInvalidParameterException - there is a problem with the propertiespublic List<Classification> getEntityClassifications(String userId, String methodName) throws InvalidParameterException
userId - calling usermethodName - calling methodInvalidParameterException - the properties of the classification are flawedpublic InstanceAuditHeader getExistingEntityClassificationHeader(String elementClassificationName, String methodName) throws InvalidParameterException
elementClassificationName - name of the classification to retrieve/convertmethodName - calling methodInvalidParameterException - the classification name parameter is nullpublic InstanceProperties getEntityClassificationProperties(String elementClassificationName, String methodName) throws InvalidParameterException
elementClassificationName - name of the classification to retrieve/convertmethodName - calling methodInvalidParameterException - the classification name parameter is nullCopyright © 2018–2020 ODPi. All rights reserved.