Class EgeriaBaseArchiveWriter
java.lang.Object
org.odpi.openmetadata.repositoryservices.archiveutilities.OMRSArchiveWriter
org.odpi.openmetadata.samples.archiveutilities.EgeriaBaseArchiveWriter
- Direct Known Subclasses:
CocoBusinessSystemsArchiveWriter,CocoClinicalTrialsArchiveWriter,CocoComboArchiveWriter,CocoGovernanceEnginesArchiveWriter,CocoGovernanceProgramArchiveWriter,CocoOrganizationArchiveWriter,CocoSustainabilityArchiveWriter,ContentPackBaseArchiveWriter
CocoBaseArchiveWriter provides a base class for utilities creating a physical open metadata archive file containing definitions for
Coco Pharmaceuticals.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected OMRSArchiveBuilderprotected final Stringprotected final Stringprotected GovernanceArchiveHelperprotected static final Stringprotected final Stringprotected static final OpenMetadataArchiveTypeprotected final Dateprotected static final Stringprotected static final Stringprotected static final String -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedEgeriaBaseArchiveWriter(String archiveGUID, String archiveName, String archiveDescription, Date creationDate, String archiveFileName) Constructor for an archive.protectedEgeriaBaseArchiveWriter(String archiveGUID, String archiveName, String archiveDescription, Date creationDate, String archiveFileName, OpenMetadataArchive[] additionalDependencies) Constructor for an archive. -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddValidMetadataValue(String displayName, String description, String propertyName, String typeName, String mapName, String preferredValue) Add a new valid value to an open metadata valid value set.protected voidaddValidMetadataValue(String suppliedGUID, String displayName, String description, String propertyName, String dataType, String typeName, String mapName, String preferredValue, Map<String, String> additionalProperties) Add a new valid value to an open metadata valid value set.abstract voidImplemented by subclass to add the content.Returns the open metadata archive containing new metadata entities.protected StringgetParentSet(String requestedGUID, String typeName, String propertyName, String mapName) Find or create the parent set for a valid value.voidsetArchiveBuilder(OMRSArchiveBuilder archiveBuilder, GovernanceArchiveHelper archiveHelper) Provide an alternative archive builder.voidGenerates and writes out the open metadata archive created in the builder.voidwriteOpenMetadataArchive(String folderName) Generates and writes out the open metadata archive created in the builder.Methods inherited from class org.odpi.openmetadata.repositoryservices.archiveutilities.OMRSArchiveWriter
getOpenMetadataArchiveFileConnection, writeOpenMetadataArchive, writeOpenMetadataArchive
-
Field Details
-
archiveLicense
- See Also:
-
archiveType
-
originatorName
- See Also:
-
guidMapFileName
- See Also:
-
versionName
- See Also:
-
archiveBuilder
-
archiveHelper
-
archiveGUID
-
archiveName
-
creationDate
-
archiveFileName
-
-
Constructor Details
-
EgeriaBaseArchiveWriter
protected EgeriaBaseArchiveWriter(String archiveGUID, String archiveName, String archiveDescription, Date creationDate, String archiveFileName) Constructor for an archive.- Parameters:
archiveGUID- unique identifier of the archivearchiveName- name of the archivearchiveDescription- description of archivecreationDate- date/time this archive writer ranarchiveFileName- name of file to write archive to
-
EgeriaBaseArchiveWriter
protected EgeriaBaseArchiveWriter(String archiveGUID, String archiveName, String archiveDescription, Date creationDate, String archiveFileName, OpenMetadataArchive[] additionalDependencies) Constructor for an archive.- Parameters:
archiveGUID- unique identifier of the archivearchiveName- name of the archivearchiveDescription- description of archivecreationDate- date/time this archive writer ranarchiveFileName- name of file to write archive toadditionalDependencies- archive that this archive is dependent on
-
-
Method Details
-
setArchiveBuilder
public void setArchiveBuilder(OMRSArchiveBuilder archiveBuilder, GovernanceArchiveHelper archiveHelper) Provide an alternative archive builder. Used when consolidating archives.- Parameters:
archiveBuilder- new archive builder
-
getOpenMetadataArchive
Returns the open metadata archive containing new metadata entities.- Returns:
- populated open metadata archive object
-
getArchiveContent
public abstract void getArchiveContent()Implemented by subclass to add the content. -
getParentSet
protected String getParentSet(String requestedGUID, String typeName, String propertyName, String mapName) Find or create the parent set for a valid value.- Parameters:
requestedGUID- optional guid for the valid valuetypeName- name of the type (can be null)propertyName- name of the property (can be null)mapName- name of the mapName (can be null)- Returns:
- unique identifier (guid) of the parent set
-
addValidMetadataValue
protected void addValidMetadataValue(String displayName, String description, String propertyName, String typeName, String mapName, String preferredValue) Add a new valid value to an open metadata valid value set.- Parameters:
displayName- human-readable namedescription- description of the valuepropertyName- name of propertytypeName- type name - if values only apply to one typemapName- name of property if stored in a mappreferredValue- preferred value to use
-
addValidMetadataValue
protected void addValidMetadataValue(String suppliedGUID, String displayName, String description, String propertyName, String dataType, String typeName, String mapName, String preferredValue, Map<String, String> additionalProperties) Add a new valid value to an open metadata valid value set.- Parameters:
suppliedGUID- predefined guiddisplayName- human-readable namedescription- description of the valuepropertyName- name of propertydataType- type of propertytypeName- type name - if values only apply to one typemapName- name of property if stored in a mappreferredValue- preferred value to useadditionalProperties- additional properties or null
-
writeOpenMetadataArchive
public void writeOpenMetadataArchive()Generates and writes out the open metadata archive created in the builder. -
writeOpenMetadataArchive
Generates and writes out the open metadata archive created in the builder.- Parameters:
folderName- name of the folder to add the archive into
-