Class ArchiveExportSpec
- java.lang.Object
-
- com.orchestranetworks.service.ArchiveExportSpec
-
public class ArchiveExportSpec extends Object
Defines the settings of an archive export.To be valid, an instance of this class must at least define an
Archivetarget. The actual content of the archive is specified as follows:Current dataspace or snapshot
If no change set has been specified by the method
setDifferencesBetweenHomes, the current dataspace or snapshot will be the one on which the procedure runsProcedureContext.doExportArchive(ArchiveExportSpec). Otherwise, the current dataspace or snapshot is the one on the right side ofDifferenceBetweenHomes.Selecting datasets
Only datasets added using
addInstancewill be exported.Including change sets
Calling the method
setDifferencesBetweenHomesadds the corresponding change set to the archive. If the resulting archive is then imported into another repository, the user performing the import will be able to specify which changes to merge.Furthermore, the actual archive content can be "optimized" using the method
setDifferencesWithMinimalContentsOnRight.
-
-
Constructor Summary
Constructors Constructor Description ArchiveExportSpec()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddInstance(AdaptationName aDataSetName, boolean exportAllDescendants)Adds a dataset to export.voidaddInstance(AdaptationName aDataSetName, InstanceContentSpec aHeader)Adds a dataset to export.ArchivegetArchive()Returns the target container for the export.DifferenceBetweenHomesgetDifferencesBetweenHomes()Returns the change set to include in the archive.booleanisDifferencesWithMinimalContentsOnRight()voidsetArchive(Archive archive)Specifies the target container for the export.voidsetDifferencesBetweenHomes(DifferenceBetweenHomes differencesBetweenHomes)Specifies the change set to include in the archive.voidsetDifferencesWithMinimalContentsOnRight(boolean minimal)Specifies whether the change set's right-side content is minimal in the archive.
-
-
-
Method Detail
-
addInstance
public void addInstance(AdaptationName aDataSetName, boolean exportAllDescendants)
Adds a dataset to export.- Parameters:
aDataSetName- reference of the dataset to export.exportAllDescendants- indicates whether the dataset's descendants are also to be exported.
-
addInstance
public void addInstance(AdaptationName aDataSetName, InstanceContentSpec aHeader)
Adds a dataset to export.- Parameters:
aDataSetName- reference of the dataset to export.aHeader- the header describing the behavior of thisArchiveExportSpec.
-
getArchive
public Archive getArchive()
Returns the target container for the export.
-
setArchive
public void setArchive(Archive archive)
Specifies the target container for the export.
-
getDifferencesBetweenHomes
public DifferenceBetweenHomes getDifferencesBetweenHomes()
Returns the change set to include in the archive.
-
setDifferencesBetweenHomes
public void setDifferencesBetweenHomes(DifferenceBetweenHomes differencesBetweenHomes)
Specifies the change set to include in the archive.- Throws:
IllegalArgumentException- ifdifferencesBetweenHomesis empty.
-
isDifferencesWithMinimalContentsOnRight
public boolean isDifferencesWithMinimalContentsOnRight()
-
setDifferencesWithMinimalContentsOnRight
public void setDifferencesWithMinimalContentsOnRight(boolean minimal)
Specifies whether the change set's right-side content is minimal in the archive. More precisely, ifminimalistrue, then when a table or a dataset has no differences, it is not exported. For large repositories with a relatively limited number of changes, this allows much better export performance and smaller archives.If set to
false(default), all the content on the right is included in the archive. This option is more costly, however the archive contains more information that can be imported into another repository whose life cycle does not require it to be in phase with the repository exporting the data.This method has no effect if no change set is specified (that is, if method
setDifferencesBetweenHomesis not called).
-
-