Class AssetBuilder
java.lang.Object
org.odpi.openmetadata.commonservices.generichandlers.OpenMetadataAPIGenericBuilder
org.odpi.openmetadata.commonservices.generichandlers.ReferenceableBuilder
org.odpi.openmetadata.commonservices.generichandlers.AssetBuilder
- Direct Known Subclasses:
ProcessBuilder
AssetBuilder creates the parts of a root repository entity for an asset.
-
Field Summary
Fields inherited from class org.odpi.openmetadata.commonservices.generichandlers.ReferenceableBuilder
qualifiedName
Fields inherited from class org.odpi.openmetadata.commonservices.generichandlers.OpenMetadataAPIGenericBuilder
errorHandler, existingClassifications, extendedProperties, instanceStatus, newClassifications, repositoryHelper, serverName, serviceName, templateProperties, typeGUID, typeName
-
Constructor Summary
ModifierConstructorDescriptionprotected
AssetBuilder
(String qualifiedName, String name, String resourceName, String versionIdentifier, String technicalDescription, String deployedImplementationType, Map<String, String> additionalProperties, String typeGUID, String typeName, Map<String, Object> extendedProperties, InstanceStatus initialStatus, OMRSRepositoryHelper repositoryHelper, String serviceName, String serverName) Constructor supporting all entity properties.protected
AssetBuilder
(String qualifiedName, String name, String resourceName, String versionIdentifier, String technicalDescription, String deployedImplementationType, Map<String, String> additionalProperties, String typeGUID, String typeName, Map<String, Object> extendedProperties, OMRSRepositoryHelper repositoryHelper, String serviceName, String serverName) Constructor supporting all entity properties.protected
AssetBuilder
(String typeGUID, String typeName, OMRSRepositoryHelper repositoryHelper, String serviceName, String serverName) Subtype constructor used when working with classificationsprotected
AssetBuilder
(OMRSRepositoryHelper repositoryHelper, String serviceName, String serverName) Creation constructor used when working with classifications -
Method Summary
Modifier and TypeMethodDescriptiongetInstanceProperties
(String methodName) Return the supplied bean properties in an InstanceProperties object.protected void
setAssetOwnership
(String userId, String owner, int ownerType, String methodName) Set up the AssetOwnership classification for this entity.protected void
setAssetZones
(String userId, List<String> zoneMembership, String methodName) Set up the AssetZones classification for this entity.Methods inherited from class org.odpi.openmetadata.commonservices.generichandlers.ReferenceableBuilder
getMementoProperties, getQualifiedName, setMemento, setOwnershipClassification, setSecurityTags, setTemplate
Methods inherited from class org.odpi.openmetadata.commonservices.generichandlers.OpenMetadataAPIGenericBuilder
getEntityClassifications, getInstanceProperties, getInstanceStatus, getTypeGUID, getTypeName, isClassificationSet, setAnchors, setClassification, setEffectivityDates, setEffectivityDates, setTemplateClassifications, setTemplateSubstitute, updateInstanceProperties
-
Constructor Details
-
AssetBuilder
protected AssetBuilder(OMRSRepositoryHelper repositoryHelper, String serviceName, String serverName) Creation constructor used when working with classifications- Parameters:
repositoryHelper
- helper methodsserviceName
- name of this OMASserverName
- name of local server
-
AssetBuilder
protected AssetBuilder(String typeGUID, String typeName, OMRSRepositoryHelper repositoryHelper, String serviceName, String serverName) Subtype constructor used when working with classifications- Parameters:
typeGUID
- unique identifier for the type of this assettypeName
- unique name for the type of this assetrepositoryHelper
- helper methodsserviceName
- name of this OMASserverName
- name of local server
-
AssetBuilder
protected AssetBuilder(String qualifiedName, String name, String resourceName, String versionIdentifier, String technicalDescription, String deployedImplementationType, Map<String, String> additionalProperties, String typeGUID, String typeName, Map<String, Object> extendedProperties, OMRSRepositoryHelper repositoryHelper, String serviceName, String serverName) Constructor supporting all entity properties. (Classifications are added separately.)- Parameters:
qualifiedName
- unique namename
- new value for the nameresourceName
- the full name from the resourceversionIdentifier
- new value for the versionIdentifiertechnicalDescription
- new description for the assetdeployedImplementationType
- technology typeadditionalProperties
- additional propertiestypeGUID
- unique identifier for the type of this assettypeName
- unique name for the type of this assetextendedProperties
- properties from the subtyperepositoryHelper
- helper methodsserviceName
- name of this OMASserverName
- name of local server
-
AssetBuilder
protected AssetBuilder(String qualifiedName, String name, String resourceName, String versionIdentifier, String technicalDescription, String deployedImplementationType, Map<String, String> additionalProperties, String typeGUID, String typeName, Map<String, Object> extendedProperties, InstanceStatus initialStatus, OMRSRepositoryHelper repositoryHelper, String serviceName, String serverName) Constructor supporting all entity properties. (Classifications are added separately.)- Parameters:
qualifiedName
- unique namename
- new value for the nameresourceName
- the full name from the resourceversionIdentifier
- new value for the versionIdentifiertechnicalDescription
- new description for the assetdeployedImplementationType
- technology typeadditionalProperties
- additional propertiestypeGUID
- unique identifier for the type of this assettypeName
- unique name for the type of this assetextendedProperties
- properties from the subtypeinitialStatus
- status used to create the assetrepositoryHelper
- helper methodsserviceName
- name of this OMASserverName
- name of local server
-
-
Method Details
-
setAssetZones
protected void setAssetZones(String userId, List<String> zoneMembership, String methodName) throws InvalidParameterException Set up the AssetZones classification for this entity. This method overrides an previously defined AssetZones classification for this entity.- Parameters:
userId
- calling userzoneMembership
- list of zone names for the zones this asset is a member ofmethodName
- calling method- Throws:
InvalidParameterException
- AssetZones is not supported in the local repository, or any repository connected by an open metadata repository cohort
-
setAssetOwnership
protected void setAssetOwnership(String userId, String owner, int ownerType, String methodName) throws InvalidParameterException Set up the AssetOwnership classification for this entity. This method overrides an previously defined AssetOwnership classification for this entity.- Parameters:
userId
- calling userowner
- name of the owner.ownerType
- Enum ordinal for type of owner - 0=userId; 1= profileId; 99=other.methodName
- calling method- Throws:
InvalidParameterException
- AssetOwnership is not supported in the local repository, or any repository connected by an open metadata repository cohort
-
getInstanceProperties
Return the supplied bean properties in an InstanceProperties object.- Overrides:
getInstanceProperties
in classReferenceableBuilder
- Parameters:
methodName
- name of the calling method- Returns:
- InstanceProperties object
- Throws:
InvalidParameterException
- there is a problem with the properties
-