Class ReadOnlyUtil
- java.lang.Object
-
- jetbrains.buildServer.serverSide.impl.ReadOnlyUtil
-
public class ReadOnlyUtil extends Object
-
-
Field Summary
Fields Modifier and Type Field Description static StringSTRICT_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 voidcheckModificationAllowed(SPersistentEntity entity)static voidcheckParameterModificationAllowed(SPersistentEntity entity, String paramName)voidcheckProjectFeatureModificationAllowed(SProject project, SProjectFeatureDescriptor feature)static voidcheckRemoveAllowed(SPersistentEntity entity)static DisposabledisableReadOnlyCheck()static voidfailIfStrictReadOnly(SPersistentEntity entity, ReadOnlyReason reason)ReadOnlyReasongetReadOnlyReason(SPersistentEntity entity)static booleanisCanBeMadeEditable(ReadOnlyReason reason)voidsetEditable(SPersistentEntity entity, boolean editable)static <T> TwithDisabledReadOnlyCheck(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)
-
-