Class ReadOnlyUtil
- java.lang.Object
-
- jetbrains.buildServer.serverSide.impl.ReadOnlyUtil
-
public class ReadOnlyUtil extends Object
-
-
Field Summary
Fields Modifier and Type Field Description static String
STRICT_READ_ONLY_PROP
-
Constructor Summary
Constructors Constructor Description ReadOnlyUtil(VersionedSettingsManager versionedSettingsManager)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static void
checkModificationAllowed(SPersistentEntity entity)
static void
checkParameterModificationAllowed(SPersistentEntity entity, String paramName)
void
checkProjectFeatureModificationAllowed(SProject project, SProjectFeatureDescriptor feature)
static void
checkRemoveAllowed(SPersistentEntity entity)
static Disposable
disableReadOnlyCheck()
static void
failIfStrictReadOnly(SPersistentEntity entity, ReadOnlyReason reason)
ReadOnlyReason
getReadOnlyReason(SPersistentEntity entity)
static boolean
isCanBeMadeEditable(ReadOnlyReason reason)
void
setEditable(SPersistentEntity entity, boolean editable)
static <T> T
withDisabledReadOnlyCheck(Supplier<T> runnable)
-
-
-
Field Detail
-
STRICT_READ_ONLY_PROP
public static final String STRICT_READ_ONLY_PROP
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ReadOnlyUtil
public ReadOnlyUtil(@NotNull VersionedSettingsManager versionedSettingsManager)
-
-
Method Detail
-
getReadOnlyReason
@Nullable public ReadOnlyReason getReadOnlyReason(@NotNull SPersistentEntity entity)
-
checkModificationAllowed
public static void checkModificationAllowed(@NotNull SPersistentEntity entity)
-
checkRemoveAllowed
public static void checkRemoveAllowed(@NotNull SPersistentEntity entity)
-
checkParameterModificationAllowed
public static void checkParameterModificationAllowed(@NotNull SPersistentEntity entity, @NotNull String paramName)
-
checkProjectFeatureModificationAllowed
public void checkProjectFeatureModificationAllowed(@NotNull SProject project, @NotNull SProjectFeatureDescriptor feature)
-
isCanBeMadeEditable
public static boolean isCanBeMadeEditable(@NotNull ReadOnlyReason reason)
-
failIfStrictReadOnly
public static void failIfStrictReadOnly(@NotNull SPersistentEntity entity, @NotNull ReadOnlyReason reason)
-
setEditable
public void setEditable(@NotNull SPersistentEntity entity, boolean editable)
-
disableReadOnlyCheck
@NotNull public static Disposable disableReadOnlyCheck()
-
withDisabledReadOnlyCheck
public static <T> T withDisabledReadOnlyCheck(@NotNull Supplier<T> runnable)
-
-