Class UserUpdateProfileContext
- java.lang.Object
-
- org.keycloak.authentication.requiredactions.util.UserUpdateProfileContext
-
- All Implemented Interfaces:
UpdateProfileContext
public class UserUpdateProfileContext extends Object implements UpdateProfileContext
- Author:
- Marek Posolda
-
-
Constructor Summary
Constructors Constructor Description UserUpdateProfileContext(RealmModel realm, UserModel user)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Map<String,List<String>>getAttributes()Stream<String>getAttributeStream(String key)Obtains all values associated with the specified attribute name.StringgetEmail()StringgetFirstAttribute(String name)StringgetFirstName()StringgetLastName()StringgetUsername()UserProfileContextgetUserProfileContext()booleanisEditEmailAllowed()booleanisEditUsernameAllowed()voidsetAttribute(String key, List<String> value)voidsetEmail(String email)voidsetFirstName(String firstName)voidsetLastName(String lastName)voidsetSingleAttribute(String name, String value)voidsetUsername(String username)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.keycloak.authentication.requiredactions.util.UpdateProfileContext
getAttribute
-
-
-
-
Constructor Detail
-
UserUpdateProfileContext
public UserUpdateProfileContext(RealmModel realm, UserModel user)
-
-
Method Detail
-
isEditUsernameAllowed
public boolean isEditUsernameAllowed()
- Specified by:
isEditUsernameAllowedin interfaceUpdateProfileContext
-
getUserProfileContext
public UserProfileContext getUserProfileContext()
- Specified by:
getUserProfileContextin interfaceUpdateProfileContext
-
getUsername
public String getUsername()
- Specified by:
getUsernamein interfaceUpdateProfileContext
-
setUsername
public void setUsername(String username)
- Specified by:
setUsernamein interfaceUpdateProfileContext
-
isEditEmailAllowed
public boolean isEditEmailAllowed()
- Specified by:
isEditEmailAllowedin interfaceUpdateProfileContext
-
getEmail
public String getEmail()
- Specified by:
getEmailin interfaceUpdateProfileContext
-
setEmail
public void setEmail(String email)
- Specified by:
setEmailin interfaceUpdateProfileContext
-
getFirstName
public String getFirstName()
- Specified by:
getFirstNamein interfaceUpdateProfileContext
-
setFirstName
public void setFirstName(String firstName)
- Specified by:
setFirstNamein interfaceUpdateProfileContext
-
getLastName
public String getLastName()
- Specified by:
getLastNamein interfaceUpdateProfileContext
-
setLastName
public void setLastName(String lastName)
- Specified by:
setLastNamein interfaceUpdateProfileContext
-
getAttributes
public Map<String,List<String>> getAttributes()
- Specified by:
getAttributesin interfaceUpdateProfileContext
-
setSingleAttribute
public void setSingleAttribute(String name, String value)
- Specified by:
setSingleAttributein interfaceUpdateProfileContext
-
setAttribute
public void setAttribute(String key, List<String> value)
- Specified by:
setAttributein interfaceUpdateProfileContext
-
getFirstAttribute
public String getFirstAttribute(String name)
- Specified by:
getFirstAttributein interfaceUpdateProfileContext
-
getAttributeStream
public Stream<String> getAttributeStream(String key)
Description copied from interface:UpdateProfileContextObtains all values associated with the specified attribute name.- Specified by:
getAttributeStreamin interfaceUpdateProfileContext- Parameters:
key- the name of the attribute.- Returns:
- a non-null
Streamof attribute values.
-
-