Class CurrentUserRepresentation
java.lang.Object
com.cumulocity.rest.representation.BaseResourceRepresentation
com.cumulocity.rest.representation.AbstractExtensibleRepresentation
com.cumulocity.rest.representation.user.CurrentUserRepresentation
- All Implemented Interfaces:
ResourceRepresentation,org.svenson.DynamicProperties
This class intentionally is not extending
UserRepresentation.
Current user resource provides information required by client (application) for normal operation.
One example is effective list of roles. Without building this list on server side, client would have to explicitly go
through associated roles/groups, possibly with pagination operations. It is both difficult, and not possible if
ROLE_USER_MANAGEMENT_READ role is not present.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetEmail()getId()Deprecated.org.joda.time.DateTimegetPhone()voidsetEffectiveRoles(List<RoleRepresentation> effectiveRoles) voidvoidsetFirstName(String firstName) voidvoidsetLastName(String lastName) voidsetLastPasswordChange(Date lastPasswordChange) Deprecated.voidsetLastPasswordChangeDateTime(org.joda.time.DateTime lastPasswordChange) voidsetPassword(String password) voidvoidsetShouldResetPassword(Boolean shouldResetPassword) voidsetUserName(String userName) Methods inherited from class com.cumulocity.rest.representation.AbstractExtensibleRepresentation
get, get, getAttrs, getProperty, hasProperty, propertyNames, removeProperty, set, set, set, setAttrs, setPropertyMethods inherited from class com.cumulocity.rest.representation.BaseResourceRepresentation
getSelf, getSelfDecoded, setSelf, toJSON, toString
-
Constructor Details
-
CurrentUserRepresentation
public CurrentUserRepresentation()
-
-
Method Details
-
getId
-
getUserName
-
setUserName
-
getPassword
-
setPassword
-
getFirstName
-
setFirstName
-
getLastName
-
setLastName
-
getPhone
-
setPhone
-
getEmail
-
setEmail
-
setId
-
getEffectiveRoles
@JSONProperty(ignoreIfNull=true) @JSONTypeHint(RoleRepresentation.class) public List<RoleRepresentation> getEffectiveRoles() -
setEffectiveRoles
-
getShouldResetPassword
-
setShouldResetPassword
-
getLastPasswordChange
@JSONProperty(value="deprecated_LastPasswordChange", ignore=true) @Deprecated public Date getLastPasswordChange()Deprecated. -
setLastPasswordChange
Deprecated. -
getLastPasswordChangeDateTime
@JSONProperty(value="lastPasswordChange", ignoreIfNull=true) @JSONConverter(type=DateTimeConverter.class) public org.joda.time.DateTime getLastPasswordChangeDateTime() -
setLastPasswordChangeDateTime
public void setLastPasswordChangeDateTime(org.joda.time.DateTime lastPasswordChange)
-