Record Class OtherPrivilegesLimitations.Limitation
java.lang.Object
java.lang.Record
com.evolveum.midpoint.security.api.OtherPrivilegesLimitations.Limitation
- All Implemented Interfaces:
ShortDumpable
,Serializable
,Cloneable
- Enclosing class:
- OtherPrivilegesLimitations
public static record OtherPrivilegesLimitations.Limitation(@NotNull Collection<OtherPrivilegesLimitations.Type> allowedTypes)
extends Record
implements ShortDumpable, Serializable, Cloneable
Represents limitation to a given target (i.e. through a given assignment path or paths). Mutable.
- See Also:
-
Constructor Summary
ConstructorDescriptionLimitation
(@NotNull Collection<OtherPrivilegesLimitations.Type> allowedTypes) Creates an instance of aLimitation
record class. -
Method Summary
Modifier and TypeMethodDescriptionallow
(@NotNull OtherPrivilegesLimitations.Limitation limitation) allow
(@NotNull OtherPrivilegesLimitations.Type limitationType) @NotNull Collection<OtherPrivilegesLimitations.Type>
Returns the value of theallowedTypes
record component.boolean
allows
(@NotNull OtherPrivilegesLimitations.Type limitationType) protected OtherPrivilegesLimitations.Limitation
clone()
final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.void
restrict
(@Nullable OtherPrivilegesLimitationType bean) void
Show the content of the object intended for diagnostics.toString()
Returns a string representation of this record class.Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.evolveum.midpoint.util.ShortDumpable
shortDump, shortDumpLazily
-
Constructor Details
-
Limitation
Creates an instance of aLimitation
record class.- Parameters:
allowedTypes
- the value for theallowedTypes
record component
-
-
Method Details
-
allowingAll
-
allowingNone
-
restrict
-
clone
-
allow
@VisibleForTesting public OtherPrivilegesLimitations.Limitation allow(@NotNull @NotNull OtherPrivilegesLimitations.Type limitationType) -
allow
public OtherPrivilegesLimitations.Limitation allow(@NotNull @NotNull OtherPrivilegesLimitations.Limitation limitation) -
allows
-
shortDump
Description copied from interface:ShortDumpable
Show the content of the object intended for diagnostics. This method is supposed to append a compact, human-readable output in a single line. Unlike toString() method, there is no requirement to identify the actual class or type of the object. It is assumed that the class/type will be obvious from the context in which the output is used.- Specified by:
shortDump
in interfaceShortDumpable
- Parameters:
sb
- StringBuilder to which to a compact one-line content of the object intended for diagnostics by system administrator should be appended.
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object)
. -
allowedTypes
Returns the value of theallowedTypes
record component.- Returns:
- the value of the
allowedTypes
record component
-