public final class CRMUserAttributesService extends Object implements fr.paris.lutece.portal.service.security.UserAttributesService
Modifier and Type | Method and Description |
---|---|
void |
create(int nIdCRMUser,
String strUserAttributeKey,
String strUserAttributeValue)
Create a new user attribute
|
String |
getAttribute(String strUserId,
String strAttribute) |
Map<String,String> |
getAttributes(int nIdCRMUser)
Get the user attributes from a given id crm user
|
Map<String,String> |
getAttributes(String strUserId) |
static CRMUserAttributesService |
getService()
Get the instance of CRMUserAttributesService
|
List<String> |
getUserAttributeKeyLabels(Locale locale)
Gets the user attribute key labels.
|
List<String> |
getUserAttributeKeys()
Get the list of user attribute keys defined in crm.properties
|
boolean |
isAttributeValueInUse(String strAttributeValue,
String strUserAttributeKey)
Check if a value of an attribute is used by a user for a given attribute key
|
void |
remove(int nIdCRMUser)
Remove the user attributes of the crm user
|
void |
setCRMUserService(CRMUserService crmUserService)
Set the CRMUserService
|
public static CRMUserAttributesService getService()
CRMUserAttributesService
public void setCRMUserService(CRMUserService crmUserService)
crmUserService
- the CRMUserServicepublic String getAttribute(String strUserId, String strAttribute)
getAttribute
in interface fr.paris.lutece.portal.service.security.UserAttributesService
public Map<String,String> getAttributes(String strUserId)
getAttributes
in interface fr.paris.lutece.portal.service.security.UserAttributesService
public Map<String,String> getAttributes(int nIdCRMUser)
nIdCRMUser
- the id crm userpublic void remove(int nIdCRMUser)
nIdCRMUser
- the id crm userpublic void create(int nIdCRMUser, String strUserAttributeKey, String strUserAttributeValue)
nIdCRMUser
- the id crm userstrUserAttributeKey
- the user attribute keystrUserAttributeValue
- the user attribute valuepublic List<String> getUserAttributeKeys()
public List<String> getUserAttributeKeyLabels(Locale locale)
locale
- the localepublic boolean isAttributeValueInUse(String strAttributeValue, String strUserAttributeKey)
strUserAttributeValue
- The value of the attributestrUserAttributeKey
- The key of the attributeCopyright © 2019 City of Paris. All rights reserved.