Package io.dialob.security.uaa.spi.model
Class ImmutableUaaGroup.Member
- java.lang.Object
-
- io.dialob.security.uaa.spi.model.ImmutableUaaGroup.Member
-
- All Implemented Interfaces:
UaaGroup.Member
- Enclosing class:
- ImmutableUaaGroup
@Immutable public static final class ImmutableUaaGroup.Member extends Object implements UaaGroup.Member
Immutable implementation ofUaaGroup.Member.Use the builder to create immutable instances:
ImmutableUaaGroup.Member.builder().
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classImmutableUaaGroup.Member.BuilderBuilds instances of typeMember.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ImmutableUaaGroup.Member.Builderbuilder()Creates a builder forMember.static ImmutableUaaGroup.MembercopyOf(UaaGroup.Member instance)Creates an immutable copy of aUaaGroup.Membervalue.booleanequals(Object another)This instance is equal to all instances ofMemberthat have equal attribute values.StringgetOrigin()StringgetType()StringgetValue()inthashCode()Computes a hash code from attributes:value,type,origin.StringtoString()Prints the immutable valueMemberwith attribute values.ImmutableUaaGroup.MemberwithOrigin(String value)Copy the current immutable object by setting a value for theoriginattribute.ImmutableUaaGroup.MemberwithType(String value)Copy the current immutable object by setting a value for thetypeattribute.ImmutableUaaGroup.MemberwithValue(String value)Copy the current immutable object by setting a value for thevalueattribute.
-
-
-
Method Detail
-
getValue
public String getValue()
- Specified by:
getValuein interfaceUaaGroup.Member- Returns:
- The value of the
valueattribute
-
getType
public String getType()
- Specified by:
getTypein interfaceUaaGroup.Member- Returns:
- The value of the
typeattribute
-
getOrigin
public String getOrigin()
- Specified by:
getOriginin interfaceUaaGroup.Member- Returns:
- The value of the
originattribute
-
withValue
public final ImmutableUaaGroup.Member withValue(String value)
Copy the current immutable object by setting a value for thevalueattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for value (can benull)- Returns:
- A modified copy of the
thisobject
-
withType
public final ImmutableUaaGroup.Member withType(String value)
Copy the current immutable object by setting a value for thetypeattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for type (can benull)- Returns:
- A modified copy of the
thisobject
-
withOrigin
public final ImmutableUaaGroup.Member withOrigin(String value)
Copy the current immutable object by setting a value for theoriginattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for origin (can benull)- Returns:
- A modified copy of the
thisobject
-
equals
public boolean equals(@Nullable Object another)This instance is equal to all instances ofMemberthat have equal attribute values.
-
hashCode
public int hashCode()
Computes a hash code from attributes:value,type,origin.
-
toString
public String toString()
Prints the immutable valueMemberwith attribute values.
-
copyOf
public static ImmutableUaaGroup.Member copyOf(UaaGroup.Member instance)
Creates an immutable copy of aUaaGroup.Membervalue. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.- Parameters:
instance- The instance to copy- Returns:
- A copied immutable Member instance
-
builder
public static ImmutableUaaGroup.Member.Builder builder()
Creates a builder forMember.ImmutableUaaGroup.Member.builder() .value(String | null) // nullablevalue.type(String | null) // nullabletype.origin(String | null) // nullableorigin.build();- Returns:
- A new Member builder
-
-