Package com.telenordigital.nbiot
Class ImmutableMember
- java.lang.Object
-
- com.telenordigital.nbiot.ImmutableMember
-
- All Implemented Interfaces:
Member
@ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable public final class ImmutableMember extends Object implements Member
Immutable implementation ofMember.Use the builder to create immutable instances:
new ImmutableMember.Builder().
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classImmutableMember.BuilderBuilds instances of typeImmutableMember.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description StringauthType()The user's authTypeStringavatarURL()The user's avatarURLStringconnectID()The user's connectIDstatic ImmutableMembercopyOf(Member instance)Creates an immutable copy of aMembervalue.Stringemail()The user's emailbooleanequals(Object another)This instance is equal to all instances ofImmutableMemberthat have equal attribute values.StringgitHubLogin()The user's gitHubLogininthashCode()Computes a hash code from attributes:userID,role,name,email,phone,verifiedEmail,verifiedPhone,connectID,gitHubLogin,authType,avatarURL.Stringname()The user's nameStringphone()The user's phoneStringrole()The user's roleStringtoString()Prints the immutable valueMemberwith attribute values.StringuserID()The user's IDbooleanverifiedEmail()The user's verifiedEmailbooleanverifiedPhone()The user's verifiedPhoneImmutableMemberwithAuthType(String value)Copy the current immutable object by setting a value for theauthTypeattribute.ImmutableMemberwithAvatarURL(String value)Copy the current immutable object by setting a value for theavatarURLattribute.ImmutableMemberwithConnectID(String value)Copy the current immutable object by setting a value for theconnectIDattribute.ImmutableMemberwithEmail(String value)Copy the current immutable object by setting a value for theemailattribute.ImmutableMemberwithGitHubLogin(String value)Copy the current immutable object by setting a value for thegitHubLoginattribute.ImmutableMemberwithName(String value)Copy the current immutable object by setting a value for thenameattribute.ImmutableMemberwithPhone(String value)Copy the current immutable object by setting a value for thephoneattribute.ImmutableMemberwithRole(String value)Copy the current immutable object by setting a value for theroleattribute.ImmutableMemberwithUserID(String value)Copy the current immutable object by setting a value for theuserIDattribute.ImmutableMemberwithVerifiedEmail(boolean value)Copy the current immutable object by setting a value for theverifiedEmailattribute.ImmutableMemberwithVerifiedPhone(boolean value)Copy the current immutable object by setting a value for theverifiedPhoneattribute.
-
-
-
Method Detail
-
verifiedEmail
public boolean verifiedEmail()
The user's verifiedEmail- Specified by:
verifiedEmailin interfaceMember
-
verifiedPhone
public boolean verifiedPhone()
The user's verifiedPhone- Specified by:
verifiedPhonein interfaceMember
-
gitHubLogin
@Nullable public String gitHubLogin()
The user's gitHubLogin- Specified by:
gitHubLoginin interfaceMember
-
withUserID
public final ImmutableMember withUserID(@Nullable String value)
Copy the current immutable object by setting a value for theuserIDattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for userID (can benull)- Returns:
- A modified copy of the
thisobject
-
withRole
public final ImmutableMember withRole(@Nullable String value)
Copy the current immutable object by setting a value for theroleattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for role (can benull)- Returns:
- A modified copy of the
thisobject
-
withName
public final ImmutableMember withName(@Nullable String value)
Copy the current immutable object by setting a value for thenameattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for name (can benull)- Returns:
- A modified copy of the
thisobject
-
withEmail
public final ImmutableMember withEmail(@Nullable String value)
Copy the current immutable object by setting a value for theemailattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for email (can benull)- Returns:
- A modified copy of the
thisobject
-
withPhone
public final ImmutableMember withPhone(@Nullable String value)
Copy the current immutable object by setting a value for thephoneattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for phone (can benull)- Returns:
- A modified copy of the
thisobject
-
withVerifiedEmail
public final ImmutableMember withVerifiedEmail(boolean value)
Copy the current immutable object by setting a value for theverifiedEmailattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for verifiedEmail- Returns:
- A modified copy of the
thisobject
-
withVerifiedPhone
public final ImmutableMember withVerifiedPhone(boolean value)
Copy the current immutable object by setting a value for theverifiedPhoneattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for verifiedPhone- Returns:
- A modified copy of the
thisobject
-
withConnectID
public final ImmutableMember withConnectID(@Nullable String value)
Copy the current immutable object by setting a value for theconnectIDattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for connectID (can benull)- Returns:
- A modified copy of the
thisobject
-
withGitHubLogin
public final ImmutableMember withGitHubLogin(@Nullable String value)
Copy the current immutable object by setting a value for thegitHubLoginattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for gitHubLogin (can benull)- Returns:
- A modified copy of the
thisobject
-
withAuthType
public final ImmutableMember withAuthType(@Nullable String value)
Copy the current immutable object by setting a value for theauthTypeattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for authType (can benull)- Returns:
- A modified copy of the
thisobject
-
withAvatarURL
public final ImmutableMember withAvatarURL(@Nullable String value)
Copy the current immutable object by setting a value for theavatarURLattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for avatarURL (can benull)- Returns:
- A modified copy of the
thisobject
-
equals
public boolean equals(@Nullable Object another)
This instance is equal to all instances ofImmutableMemberthat have equal attribute values.
-
hashCode
public int hashCode()
Computes a hash code from attributes:userID,role,name,email,phone,verifiedEmail,verifiedPhone,connectID,gitHubLogin,authType,avatarURL.
-
toString
public String toString()
Prints the immutable valueMemberwith attribute values.
-
copyOf
public static ImmutableMember copyOf(Member instance)
Creates an immutable copy of aMembervalue. 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
-
-