@OpenApiAll
public interface ILockProjectService
Modifier and Type | Method and Description |
---|---|
boolean |
canBeDecompositionLocked(IProject project)
Check if project decomposition can be locked by current user
|
boolean |
canBeDecompositionUnlocked(IProject project)
Check if project decomposition can be unlocked by current user
|
boolean |
canBeLocked(Element element)
Check if given element can be locked by current user.
|
boolean |
canBeLocked(ModuleUsage moduleUsage)
Check if given usage can be locked by current user.
|
boolean |
canBeOptionsLocked(IProject project,
java.lang.String options)
Check if options can be locked.
|
boolean |
canBeOptionsUnlocked(IProject project,
java.lang.String options)
Check if options can be unlocked.
|
boolean |
canBeUnlocked(Element element)
Check if given element can be unlocked by current user.
|
boolean |
canBeUnlocked(ModuleUsage moduleUsage)
Check if given usage can be unlocked by current user.
|
LockInfo |
getDecompositionLock(IProject project)
Return decomposition lock
|
java.util.Collection<Element> |
getLockedBy(java.lang.String user)
Collect all elements locked by given user
|
java.util.Collection<Element> |
getLockedByMe()
Collect all elements locked by current user
|
java.util.Collection<Element> |
getLockedElements()
Returns collection of locked elements.
|
java.util.Collection<java.lang.String> |
getLockedElementUsers()
Returns collection of locked elements owners in the server.
|
java.util.Collection<ModuleUsage> |
getLockedModules()
Collect all usages locked by any user
|
LockInfo |
getLockInfo(Element element)
Return lock information on given element
|
LockInfo |
getLockInfo(ModuleUsage moduleUsage)
Return lock information on given usage
|
java.util.Collection<ModuleUsage> |
getModulesLockedBy(java.lang.String user)
Collect all usages locked by given user
|
java.util.Collection<ModuleUsage> |
getModulesLockedByMe()
Collect all usages locked by current user
|
LockInfo |
getOptionsLock(IProject project,
java.lang.String options)
Get options lock data.
|
boolean |
hasLockedElements()
Check if project has some locked data
|
boolean |
hasPermissionToLock(Element element)
Check permissions for element.
|
boolean |
isDecompositionLocked(IProject project)
Check if decomposition model is locked
|
boolean |
isDecompositionLockedByMe(IProject project)
Checks for decomposition model lock
|
boolean |
isLocked(Element element)
Check if element is locked
|
boolean |
isLocked(ModuleUsage moduleUsage)
Check if usage is locked
|
boolean |
isLockedBy(Element element,
java.lang.String user)
Check if given element is locked by a user
|
boolean |
isLockedByMe(Element element)
Check if the given element has lock on it, and this lock owner is current user.
|
boolean |
isLockedByMe(ModuleUsage moduleUsage)
Check if the given usage has lock on it, and this lock owner is current user.
|
boolean |
isOptionsLocked(IProject project,
java.lang.String options)
Check if given options are locked.
|
boolean |
isOptionsLockedByMe(IProject project,
java.lang.String options)
Check if options locked by current user.
|
boolean |
lockElements(java.util.Collection<? extends Element> elements,
boolean lockRecursively,
ProgressStatus status)
Lock given elements.
|
boolean |
lockElements(java.util.Collection<? extends Element> elements,
ProgressStatus status)
Lock given elements.
|
boolean |
lockModules(java.util.Collection<ModuleUsage> moduleUsages,
boolean checkForNewVersion,
ProgressStatus status)
Lock given usages.
|
void |
setCacheOptionsLock(boolean value)
Sets whether options lock should be cached or not.
|
boolean |
setDecompositionLockedByMe(IProject project,
boolean locked,
ProgressStatus status)
Lock/Unlock decomposition model.
|
boolean |
setOptionsLockedByMe(IProject project,
java.lang.String options,
boolean locked,
ProgressStatus status)
Lock/unlock options.
|
boolean |
unlockElements(java.util.Collection<? extends Element> elements,
boolean unlockRecursively,
ProgressStatus status)
Unlock given elements.
|
boolean |
unlockElements(java.util.Collection<? extends Element> elements,
boolean unlockRecursively,
ProgressStatus status,
boolean unlockOnlyMyLocks)
Unlock given elements.
|
boolean |
unlockElements(java.util.Collection<? extends Element> elements,
boolean unlockRecursively,
ProgressStatus status,
java.util.Collection<Element> elementsToUnlock,
boolean unlockOnlyMyLocks)
Unlock given elements.
|
boolean |
unlockElements(java.util.Collection<? extends Element> elements,
ProgressStatus status)
Unlock given elements.
|
boolean |
unlockElements(java.util.Collection<? extends Element> elements,
ProgressStatus status,
boolean unlockOnlyMyLocks)
Unlock given elements.
|
boolean |
unlockModules(java.util.Collection<ModuleUsage> moduleUsages,
ProgressStatus status)
Unlock given usages.
|
void |
updateLocks(ProgressStatus status)
Update local information about locks from server.
|
boolean isLocked(@Nonnull Element element)
element
- elementboolean hasLockedElements()
boolean isLockedBy(@Nonnull Element element, @Nonnull java.lang.String user)
element
- elementuser
- user@CheckForNull LockInfo getLockInfo(@Nonnull Element element)
element
- elementLockInfo getLockInfo(@Nonnull ModuleUsage moduleUsage)
moduleUsage
- module usageboolean isLocked(@Nonnull ModuleUsage moduleUsage)
moduleUsage
- usageboolean isLockedByMe(@Nonnull Element element)
element
- element to check for locked user.boolean isLockedByMe(@Nonnull ModuleUsage moduleUsage)
moduleUsage
- usage to check for locked user.@Nonnull java.util.Collection<Element> getLockedBy(@Nonnull java.lang.String user)
user
- user@Nonnull java.util.Collection<Element> getLockedByMe()
java.util.Collection<ModuleUsage> getModulesLockedBy(@CheckForNull java.lang.String user)
user
- userjava.util.Collection<ModuleUsage> getModulesLockedByMe()
java.util.Collection<ModuleUsage> getLockedModules()
boolean canBeLocked(@Nonnull Element element)
element
- elementboolean canBeUnlocked(@Nonnull Element element)
element
- elementboolean canBeLocked(@Nonnull ModuleUsage moduleUsage)
moduleUsage
- usageboolean canBeUnlocked(@Nonnull ModuleUsage moduleUsage)
moduleUsage
- usageboolean lockElements(@Nonnull java.util.Collection<? extends Element> elements, boolean lockRecursively, @CheckForNull ProgressStatus status)
elements
- elementslockRecursively
- lock children recursivelystatus
- progress statusboolean lockElements(@Nonnull java.util.Collection<? extends Element> elements, @CheckForNull ProgressStatus status)
elements
- elementsstatus
- progress statusboolean unlockElements(@Nonnull java.util.Collection<? extends Element> elements, boolean unlockRecursively, @CheckForNull ProgressStatus status, boolean unlockOnlyMyLocks)
elements
- elementsunlockRecursively
- children recursivelystatus
- progress statusunlockOnlyMyLocks
- unlock only my locked elements (used for ESI projects)boolean unlockElements(@Nonnull java.util.Collection<? extends Element> elements, boolean unlockRecursively, @CheckForNull ProgressStatus status, java.util.Collection<Element> elementsToUnlock, boolean unlockOnlyMyLocks)
elements
- elementsunlockRecursively
- children recursivelystatus
- progress statuselementsToUnlock
- elements to unlockunlockOnlyMyLocks
- unlock only my locked elements (used for ESI projects)boolean unlockModules(@Nonnull java.util.Collection<ModuleUsage> moduleUsages, @CheckForNull ProgressStatus status)
moduleUsages
- elementsstatus
- progress statusboolean lockModules(@Nonnull java.util.Collection<ModuleUsage> moduleUsages, boolean checkForNewVersion, @CheckForNull ProgressStatus status)
moduleUsages
- elementscheckForNewVersion
- check if new project version exists on server before lockingstatus
- progress statusvoid updateLocks(@CheckForNull ProgressStatus status)
status
- progress@Nonnull java.util.Collection<Element> getLockedElements()
@Nonnull java.util.Collection<java.lang.String> getLockedElementUsers()
boolean isDecompositionLockedByMe(@Nonnull IProject project)
project
- project which decomposition model is lockedboolean isDecompositionLocked(@Nonnull IProject project)
project
- projectboolean setDecompositionLockedByMe(@Nonnull IProject project, boolean locked, @CheckForNull ProgressStatus status)
project
- project which decomposition model is lockedlocked
- new lock valuestatus
- progress statusLockInfo getDecompositionLock(IProject project)
project
- projectboolean canBeDecompositionLocked(IProject project)
project
- projectboolean canBeDecompositionUnlocked(IProject project)
project
- projectboolean isOptionsLocked(@Nonnull IProject project, @Nonnull java.lang.String options)
project
- project.options
- options.boolean isOptionsLockedByMe(@Nonnull IProject project, @Nonnull java.lang.String options)
project
- project.options
- options.boolean canBeOptionsLocked(@Nonnull IProject project, @Nonnull java.lang.String options)
project
- project.options
- options.boolean canBeOptionsUnlocked(IProject project, @Nonnull java.lang.String options)
project
- project.options
- options.boolean setOptionsLockedByMe(@Nonnull IProject project, @Nonnull java.lang.String options, boolean locked, @CheckForNull ProgressStatus status)
project
- project.options
- optionlocked
- true to lock, false to unlockstatus
- status.@CheckForNull LockInfo getOptionsLock(@Nonnull IProject project, @Nonnull java.lang.String options)
project
- projectoptions
- optionsvoid setCacheOptionsLock(boolean value)
value
- if true then options lock should be cached on the first call.boolean unlockElements(java.util.Collection<? extends Element> elements, ProgressStatus status, boolean unlockOnlyMyLocks)
elements
- elementsstatus
- progress statusunlockOnlyMyLocks
- unlock only my locked elements (used for ESI projects)boolean unlockElements(@Nonnull java.util.Collection<? extends Element> elements, boolean unlockRecursively, @CheckForNull ProgressStatus status)
elements
- elementsunlockRecursively
- children recursivelystatus
- progress statusboolean unlockElements(@Nonnull java.util.Collection<? extends Element> elements, @CheckForNull ProgressStatus status)
elements
- elementsstatus
- progress statusboolean hasPermissionToLock(Element element)
element
- element to check