com.cumulocity.rest.representation.user
Class CurrentUserRepresentation
java.lang.Object
com.cumulocity.rest.representation.BaseResourceRepresentation
com.cumulocity.rest.representation.user.CurrentUserRepresentation
- All Implemented Interfaces:
- ResourceRepresentation
public class CurrentUserRepresentation
- extends BaseResourceRepresentation
This class intentionally is not extending UserRepresentation
, although
CurrentUser
extends User
.
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.
CurrentUserRepresentation
public CurrentUserRepresentation()
getId
@JSONProperty(ignoreIfNull=true)
public String getId()
getUserName
@JSONProperty(ignoreIfNull=true)
public String getUserName()
setUserName
public void setUserName(String userName)
getPassword
@JSONProperty(ignoreIfNull=true)
public String getPassword()
setPassword
public void setPassword(String password)
getFirstName
@JSONProperty(ignoreIfNull=true)
public String getFirstName()
setFirstName
public void setFirstName(String firstName)
getLastName
@JSONProperty(ignoreIfNull=true)
public String getLastName()
setLastName
public void setLastName(String lastName)
getPhone
@JSONProperty(ignoreIfNull=true)
public String getPhone()
setPhone
public void setPhone(String phone)
getEmail
@JSONProperty(ignoreIfNull=true)
public String getEmail()
setEmail
public void setEmail(String email)
setId
public void setId(String id)
getEffectiveRoles
@JSONProperty(ignoreIfNull=true)
public List<RoleRepresentation> getEffectiveRoles()
setEffectiveRoles
public void setEffectiveRoles(List<RoleRepresentation> effectiveRoles)
Copyright © 2013 (C) Cumulocity GmbH. All Rights Reserved.