ilog.rules.teamserver.model
Interface IlrBaselineManagementFacility
-
- All Known Subinterfaces:
- IlrSession
public interface IlrBaselineManagementFacility
Baseline management services for a Decision Center session.- See Also:
IlrSession
-
-
Method Summary
Methods Modifier and Type Method and Description boolean
addToBaseline(IlrElementHandle element, IlrBaseline baseline)
Adds the given element to the baseline.boolean
changeVersionInBaseline(IlrElementHandle element, IlrElementVersion version, IlrBaseline baseline)
Deprecated.Equivalent function no longer available.IlrBaseline
cloneToBranch(IlrBaseline baselineSource, java.lang.String name)
Deprecated.UsecloneToBranch(IlrBaseline baselineSource, String name, boolean includeDependencies)
(with includeDependencies = false) instead.IlrBranch
cloneToBranch(IlrBaseline baselineSource, java.lang.String name, boolean includeDependencies)
Copies the given baseline and converts it to a branch.IlrBaseline
copyBaseline(IlrBaseline baselineSource, java.lang.String name)
Copies the content of the given baseline to a new one.IlrBaseline
createBaseline(IlrBranch parentBranch, java.lang.String name, java.lang.String documentation, boolean includeDependencies, IlrBaselineKind baselineKind)
Creates a new baseline (snapshot) in the given branch.IlrBaseline
createBaselineFromCurrentState(java.lang.String name)
Deprecated.UsecreateBaselineFromCurrentState(String name, String documentation)
instead.IlrBaseline
createBaselineFromCurrentState(java.lang.String name, boolean includeDependencies, IlrBaselineKind baselineKind)
Deprecated.UsecreateBaselineFromCurrentState(String name, String documentation, boolean includeDependencies, IlrBaselineKind baselineKind)
instead.IlrBaseline
createBaselineFromCurrentState(java.lang.String name, java.lang.String documentation)
Creates a baseline for the current baseline of the working project.IlrBaseline
createBaselineFromCurrentState(java.lang.String name, java.lang.String documentation, boolean includeDependencies, IlrBaselineKind baselineKind)
Creates a baseline for the current baseline of the working project.IlrBranch
createBranchFromCurrentState(java.lang.String name, boolean includeDependencies)
Creates a branch for the current baseline of the working project.IlrBaseline
createSnapshotFromBaselineEvent(java.lang.String snapshotName, java.lang.String documentation, IlrElementHandle eventHandle)
Creates a new snapshot that references all elements that were available at the time the given baseline event was created.IlrBaseline
createSnapshotFromElement(java.lang.String snapshotName, java.lang.String documentation, IlrElementHandle projectEltHandle)
Deprecated.Creates a snapshot that references all elements that were available at the time the given element handle was updated. New methodcreateSnapshotFromElementVersion()
should be used instead of this one. This new method can handle deleting of elements, which is not the case withcreateSnapshotFromElement()
.IlrBaseline
createSnapshotFromElementVersion(java.lang.String snapshotName, java.lang.String documentation, IlrElementVersion eltVersion)
Creates a new snapshot that references all elements that were available at the time the given element version was created.void
deleteBaseline(IlrBaseline baseline, boolean includeDependencies)
Deletes a baseline.boolean
deleteFromBranch(IlrElementHandle element, IlrBaseline baseline)
java.util.List<IlrElementHandle>
findArtifactsCausingMergeConflicts(IlrBranch selectedBaseline)
Deprecated.should use BranchHelper.getMergeOperations(IlrSession session, IlrBaseline lhsBranch, IlrBaseline rhsBranch) instead Returns the list of elements from the selected baseline that are in conflict when attempting a merge with the working baseline. If the working baseline isnull
, the finder uses the current baseline of the project of the selected baseline.java.util.List<IlrElementHandle>
findArtifactsDeletedReadyToMerge(IlrBranch selectedBaseline)
Deprecated.should use BranchHelper.getMergeOperations(IlrSession session, IlrBaseline lhsBranch, IlrBaseline rhsBranch) instead Returns the list of elements that were deleted in the selected baseline, and deleted or not modified in the working baseline.java.util.List<IlrElementHandle>
findArtifactsReadyToMerge(IlrBranch selectedBaseline)
Deprecated.should use BranchHelper.getMergeOperations(IlrSession session, IlrBaseline lhsBranch, IlrBaseline rhsBranch) instead Returns the list of elements from the selected baseline that can be safely merged with the working baseline without conflict. If the working baseline isnull
, the finder uses the current baseline of the project of the selected baseline. It returns the list of elements that were modified in the selected branch, and not modified in the working baseline. It does not return elements that were deleted in the selected or in the working baselines.java.util.List
getBaselinesForVersion(IlrElementVersion version)
Gets the baselines that reference the given element version.boolean
removeFromBaseline(IlrElementHandle element, IlrBaseline baseline)
Deprecated.Make sure the baseline is not frozen, and then usedeleteFromBranch()
.void
restoreBaseline(IlrBaseline baseline)
Deprecated.UserestoreBaseline(String name, String comment)
instead.void
restoreBaseline(IlrBaseline baseline, java.lang.String comment)
Restores the given baseline.
-
-
-
Method Detail
-
addToBaseline
boolean addToBaseline(IlrElementHandle element, IlrBaseline baseline) throws IlrObjectNotFoundException, IlrPermissionException, IlrFrozenBaselineException
Adds the given element to the baseline. This baseline must be a deployment baseline, or a baseline migrated from an older release of Decision Center. The element must be a project element and must belong to the baseline. To add an element to a branch, useIlrSessionHelper.copyElementFromWorkingBaselineToBranch()
orIlrSessionHelper.copyElementFromSourceBaselineToTargetBranch()
.- Throws:
IlrObjectNotFoundException
- If the given element cannot be found in the database.IlrPermissionException
- If the user is neither a configuration manager nor an administrator.IlrFrozenBaselineException
- If the baseline is frozen and thus cannot be updated.- Parameters:
element
- Handle on the element to add.baseline
- The baseline to update.- Returns:
false
If the baseline cannot be updated.
-
findArtifactsDeletedReadyToMerge
java.util.List<IlrElementHandle> findArtifactsDeletedReadyToMerge(IlrBranch selectedBaseline) throws IlrObjectNotFoundException, IlrPermissionException, IlrFrozenBaselineException, IlrInvalidElementException
Deprecated. should use BranchHelper.getMergeOperations(IlrSession session, IlrBaseline lhsBranch, IlrBaseline rhsBranch) instead Returns the list of elements that were deleted in the selected baseline, and deleted or not modified in the working baseline.- Throws:
IlrFrozenBaselineException
- If the working baseline is not frozen.IlrInvalidElementException
- If a baseline with the same name already exists.IlrObjectNotFoundException
IlrPermissionException
- Parameters:
selectedBaseline
- The selected baseline.- Returns:
- The list of elements.
-
findArtifactsReadyToMerge
java.util.List<IlrElementHandle> findArtifactsReadyToMerge(IlrBranch selectedBaseline) throws IlrFrozenBaselineException, IlrObjectNotFoundException, IlrPermissionException, IlrInvalidElementException
Deprecated. should use BranchHelper.getMergeOperations(IlrSession session, IlrBaseline lhsBranch, IlrBaseline rhsBranch) instead Returns the list of elements from the selected baseline that can be safely merged with the working baseline without conflict. If the working baseline isnull
, the finder uses the current baseline of the project of the selected baseline. It returns the list of elements that were modified in the selected branch, and not modified in the working baseline. It does not return elements that were deleted in the selected or in the working baselines.- Throws:
IlrFrozenBaselineException
- If the working baseline is not frozen.IlrObjectNotFoundException
- If the given element cannot be found in the database.IlrPermissionException
- If the user is neither a configuration manager nor an administrator.IlrInvalidElementException
- If a baseline with the same name already exists.- Parameters:
selectedBaseline
- The selected baseline.- Returns:
- The list of elements.
-
findArtifactsCausingMergeConflicts
java.util.List<IlrElementHandle> findArtifactsCausingMergeConflicts(IlrBranch selectedBaseline) throws IlrFrozenBaselineException, IlrObjectNotFoundException, IlrPermissionException, IlrInvalidElementException
Deprecated. should use BranchHelper.getMergeOperations(IlrSession session, IlrBaseline lhsBranch, IlrBaseline rhsBranch) instead Returns the list of elements from the selected baseline that are in conflict when attempting a merge with the working baseline. If the working baseline isnull
, the finder uses the current baseline of the project of the selected baseline.- Throws:
IlrFrozenBaselineException
- If the working baseline is not frozen.IlrObjectNotFoundException
- If the given element cannot be found in the database.IlrPermissionException
- If the user is neither a configuration manager nor an administrator.IlrInvalidElementException
- If a baseline with the same name already exists.- Parameters:
selectedBaseline
- The selected baseline.- Returns:
- The list of elements.
-
deleteFromBranch
boolean deleteFromBranch(IlrElementHandle element, IlrBaseline baseline) throws IlrApplicationException
- Throws:
IlrApplicationException
-
removeFromBaseline
boolean removeFromBaseline(IlrElementHandle element, IlrBaseline baseline) throws IlrObjectNotFoundException, IlrPermissionException, IlrFrozenBaselineException
Deprecated. Make sure the baseline is not frozen, and then usedeleteFromBranch()
.Removes the given element from the baseline. This baseline must not be a current baseline. The element must be a project element and must belong to the baseline.- Throws:
IlrObjectNotFoundException
- If the given element cannot be found in the database.IlrPermissionException
- If the user is neither a configuration manager nor an administrator.IlrFrozenBaselineException
- If the baseline is frozen and thus cannot be updated.- Parameters:
element
- Handle on the element to remove.baseline
- The baseline to update.- Returns:
false
if the baseline cannot be updated.
-
changeVersionInBaseline
boolean changeVersionInBaseline(IlrElementHandle element, IlrElementVersion version, IlrBaseline baseline) throws IlrObjectNotFoundException, IlrPermissionException, IlrFrozenBaselineException
Deprecated. Equivalent function no longer available.Changes the version of an element in a baseline. This baseline must not be a current baseline. The element must be a project element and must belong to the baseline.- Throws:
IlrObjectNotFoundException
- If the given element cannot be found in the database.IlrPermissionException
- If the user is neither a configuration manager nor an administrator.IlrFrozenBaselineException
- If the baseline is frozen and thus cannot be updated.- Parameters:
element
- Handle on the element to remove.version
- The new version of the element the baseline should refer to.baseline
- The baseline to update.- Returns:
false
if the baseline cannot be updated.
-
createBaselineFromCurrentState
IlrBaseline createBaselineFromCurrentState(java.lang.String name) throws IlrApplicationException
Deprecated. UsecreateBaselineFromCurrentState(String name, String documentation)
instead.Creates a baseline for the current baseline of the working project. This is a snapshot of the current state of the project.- Throws:
IlrObjectNotFoundException
- If the given element cannot be found in the database.IlrPermissionException
- If the user is neither a configuration manager nor an administrator.IlrBaselineNotCurrentException
- If the working baseline is not the current one.IlrInvalidElementException
- If a baseline with the same name already exists.IlrActivityObjectLockedException
IlrApplicationException
- Parameters:
name
- The name of the baseline to create.- Returns:
- The created baseline.
-
createBaselineFromCurrentState
IlrBaseline createBaselineFromCurrentState(java.lang.String name, java.lang.String documentation) throws IlrApplicationException
Creates a baseline for the current baseline of the working project. This is a snapshot of the current state of the project.- Throws:
IlrObjectNotFoundException
- If the given element cannot be found in the database.IlrPermissionException
- If the user is neither a configuration manager nor an administrator.IlrBaselineNotCurrentException
- If the working baseline is not the current one.IlrInvalidElementException
- If a baseline with the same name already exists.IlrActivityObjectLockedException
IlrApplicationException
- Parameters:
name
- The name of the baseline to create.documentation
- Text to describe the new baseline.- Returns:
- The created baseline.
-
createBaselineFromCurrentState
IlrBaseline createBaselineFromCurrentState(java.lang.String name, boolean includeDependencies, IlrBaselineKind baselineKind) throws IlrApplicationException
Deprecated. UsecreateBaselineFromCurrentState(String name, String documentation, boolean includeDependencies, IlrBaselineKind baselineKind)
instead.Creates a baseline for the current baseline of the working project. This is a snapshot of the current state of the project.- Throws:
IlrObjectNotFoundException
- If the given element cannot be found in the database.IlrPermissionException
- If the user is neither a configuration manager nor an administrator.IlrFrozenBaselineException
- If the working baseline is not frozen.IlrInvalidElementException
- If a baseline with the same name already exists.IlrActivityObjectLockedException
IlrApplicationException
- Parameters:
name
- The name of the baseline to create.includeDependencies
- Iftrue
, a baseline with the same name will also be created for all dependent projects.- Returns:
- The created baseline.
-
createBaselineFromCurrentState
IlrBaseline createBaselineFromCurrentState(java.lang.String name, java.lang.String documentation, boolean includeDependencies, IlrBaselineKind baselineKind) throws IlrApplicationException
Creates a baseline for the current baseline of the working project. This is a snapshot of the current state of the project.- Throws:
IlrObjectNotFoundException
- If the given element cannot be found in the database.IlrPermissionException
- If the user is neither a configuration manager nor an administrator.IlrFrozenBaselineException
- If the working baseline is not frozen.IlrInvalidElementException
- If a baseline with the same name already exists.IlrActivityObjectLockedException
IlrApplicationException
- Parameters:
name
- The name of the baseline to create.documentation
- Text to describe the new baseline.includeDependencies
- Iftrue
, a baseline with the same name will also be created for all dependent projects.- Returns:
- The created baseline.
-
createBaseline
IlrBaseline createBaseline(IlrBranch parentBranch, java.lang.String name, java.lang.String documentation, boolean includeDependencies, IlrBaselineKind baselineKind) throws IlrApplicationException
Creates a new baseline (snapshot) in the given branch.- Throws:
IlrApplicationException
- Parameters:
parentBranch
- The branch in which the new baseline will get created.name
- The name of the baseline to create.documentation
- Text to describe the new baseline.baselineKind
- The type of baseline to create.includeDependencies
- Iftrue
, a baseline with the same name and same kind will also be created for all dependent branches.- Returns:
- The created branch.
-
createBranchFromCurrentState
IlrBranch createBranchFromCurrentState(java.lang.String name, boolean includeDependencies) throws IlrApplicationException
Creates a branch for the current baseline of the working project.- Throws:
IlrObjectNotFoundException
- If the given element cannot be found in the database.IlrPermissionException
- If the user is neither a configuration manager nor an administrator.IlrFrozenBaselineException
- If the working baseline is not frozen.IlrInvalidElementException
- If a baseline with the same name already exists.IlrActivityObjectLockedException
IlrApplicationException
- Parameters:
name
- The name of the branch to create.includeDependencies
- Iftrue
, a baseline with the same name will also be created for all dependent projects.- Returns:
- The created branch.
-
createSnapshotFromElement
IlrBaseline createSnapshotFromElement(java.lang.String snapshotName, java.lang.String documentation, IlrElementHandle projectEltHandle) throws ilog.rules.teamserver.model.IlrAPIException, IlrApplicationException
Deprecated. Creates a snapshot that references all elements that were available at the time the given element handle was updated. New methodcreateSnapshotFromElementVersion()
should be used instead of this one. This new method can handle deleting of elements, which is not the case withcreateSnapshotFromElement()
.- Throws:
IlrInvalidElementException
- If a snapshot with the same name already exists or if the handle is not a project element handle.ilog.rules.teamserver.model.IlrAPIException
ilog.rules.teamserver.model.IlrTransactionStoppedException
IlrKnownUUIDException
IlrObjectNotFoundException
- If the given element cannot be found in the database.IlrPermissionException
- If the user is neither a configuration manager nor an administrator.IlrActivityObjectLockedException
IlrApplicationException
- Parameters:
documentation
- The text to describe the new snapshot.
-
createSnapshotFromElementVersion
IlrBaseline createSnapshotFromElementVersion(java.lang.String snapshotName, java.lang.String documentation, IlrElementVersion eltVersion) throws ilog.rules.teamserver.model.IlrAPIException, IlrApplicationException
Creates a new snapshot that references all elements that were available at the time the given element version was created.- Throws:
IlrInvalidElementException
- If a snapshot with the same name already exists or if the handle is not a project element handle.IlrPermissionException
IlrObjectNotFoundException
IlrKnownUUIDException
ilog.rules.teamserver.model.IlrTransactionStoppedException
ilog.rules.teamserver.model.IlrAPIException
IlrActivityObjectLockedException
IlrApplicationException
- Parameters:
snapshotName
-documentation
-eltVersion
- An element version.- Returns:
- The snapshot.
-
createSnapshotFromBaselineEvent
IlrBaseline createSnapshotFromBaselineEvent(java.lang.String snapshotName, java.lang.String documentation, IlrElementHandle eventHandle) throws ilog.rules.teamserver.model.IlrAPIException, IlrApplicationException
Creates a new snapshot that references all elements that were available at the time the given baseline event was created. Each update of a baseline generate a system event. Use one of those events to create the snapshot.- Throws:
IlrInvalidElementException
IlrPermissionException
IlrObjectNotFoundException
IlrKnownUUIDException
ilog.rules.teamserver.model.IlrTransactionStoppedException
ilog.rules.teamserver.model.IlrAPIException
IlrActivityObjectLockedException
IlrApplicationException
- Parameters:
snapshotName
-documentation
-eventHandle
- A baseline event handle- Returns:
- The snapshot.
-
deleteBaseline
void deleteBaseline(IlrBaseline baseline, boolean includeDependencies) throws IlrApplicationException
Deletes a baseline.- Throws:
IlrObjectNotFoundException
- If the given element cannot be found in the database.IlrPermissionException
- If the user is neither a configuration manager nor an administrator.IlrFrozenBaselineException
- If the baseline is frozen and thus cannot be updated.IlrActivityObjectLockedException
ilog.rules.teamserver.model.IlrAPIException
IlrApplicationException
- Parameters:
baseline
- The baseline to delete.includeDependencies
- Iftrue
, all dependent baselines with the same name will also be deleted.
-
getBaselinesForVersion
java.util.List getBaselinesForVersion(IlrElementVersion version)
Gets the baselines that reference the given element version.- Parameters:
version
- The element version to test.- Returns:
- A list of
IlrElementSummary
objects, instance ofbrm.Baseline
.
-
restoreBaseline
void restoreBaseline(IlrBaseline baseline) throws IlrApplicationException
Deprecated. UserestoreBaseline(String name, String comment)
instead.Restores the given baseline. This replaces the content of the current baseline with the element versions referenced by the given baseline. This operation creates new versions of the elements, which are copies of the versions referenced in the baseline.- Throws:
IlrCannotDeleteException
- If some of the elements of the current baseline are not in the restored baseline and cannot be deleted.IlrPermissionException
- If the security on the elements of the current baseline prevents the restore operation.IlrObjectNotFoundException
- If the given baseline cannot be found.IlrObjectLockedException
- If one object of the current baseline is locked and cannot be deleted or overwritten.IlrFolderLockedException
- If a rule package of the working baseline is locked.IlrFrozenBaselineException
- If the working baseline is not frozen.IlrInvalidElementException
- If some of the elements to restore cause a duplicate conflict with a new element added into the current baseline.IlrActivityObjectLockedException
IlrApplicationException
- Parameters:
baseline
- The baseline to restore.
-
restoreBaseline
void restoreBaseline(IlrBaseline baseline, java.lang.String comment) throws IlrApplicationException
Restores the given baseline. This replaces the content of the current baseline with the element versions referenced by the given baseline. This operation creates new versions of the elements, which are copies of the versions referenced in the baseline.- Throws:
IlrCannotDeleteException
- If some of the elements of the current baseline are not in the restored baseline and cannot be deleted.IlrPermissionException
- If the security on the elements of the current baseline prevents the restore operation.IlrObjectNotFoundException
- If the given baseline cannot be found.IlrObjectLockedException
- If one object of the current baseline is locked and cannot be deleted or overwritten.IlrFolderLockedException
- If a rule package of the working baseline is locked.IlrFrozenBaselineException
- If the working baseline is not frozen.IlrInvalidElementException
- If some of the elements to restore cause a duplicate conflict with a new element added into the current baseline.IlrActivityObjectLockedException
IlrApplicationException
- Parameters:
baseline
- The baseline to restore.comment
- User-provided comment (optional) to describe the reason for this restore.
-
copyBaseline
IlrBaseline copyBaseline(IlrBaseline baselineSource, java.lang.String name) throws IlrApplicationException
Copies the content of the given baseline to a new one.- Throws:
IlrObjectNotFoundException
- If the source baseline cannot be found in the database.IlrPermissionException
- If the user is neither a configuration manager nor an administrator.IlrInvalidElementException
- If a baseline with the same name already exists.IlrActivityObjectLockedException
IlrApplicationException
- Parameters:
baselineSource
- The baseline to copy.name
- The name of the new baseline.- Returns:
- The new baseline.
-
cloneToBranch
IlrBaseline cloneToBranch(IlrBaseline baselineSource, java.lang.String name) throws IlrApplicationException
Deprecated. UsecloneToBranch(IlrBaseline baselineSource, String name, boolean includeDependencies)
(with includeDependencies = false) instead.Copies the given baseline and converts it to a branch.- Throws:
IlrApplicationException
- If an error occurred when converting the baseline.- Parameters:
baselineSource
- The baseline to copy.name
- The name of the new branch.- Returns:
- The branch.
-
cloneToBranch
IlrBranch cloneToBranch(IlrBaseline baselineSource, java.lang.String name, boolean includeDependencies) throws IlrApplicationException
Copies the given baseline and converts it to a branch.- Throws:
IlrApplicationException
- If an error occurred when converting the baseline.- Parameters:
baselineSource
- The baseline to copy.name
- The name of the new branch.includeDependencies
- Iftrue
, all dependent baselines with the same name will also be cloned with the given name. Iffalse
, the new branch is created with the same dependencies as the original baseline.
- Returns:
- The branch.
-
-