com.sap.security.api

Interface IUserMaint

All Superinterfaces:
IPrincipal, IPrincipalMaint, IUser, Principal, Serializable

public interface IUserMaint
extends IUser, IPrincipalMaint

This interface extends IUser and provides write access to a user. It provides methods to change the user's attributes, to commit these changes to the user store or to roll them back (i.e. discard them) if appropriate. It is intended for administration of user profiles (including self-administration). It does not cover account, password and authorization management. The set-methods with boolean return values return true if the new value is different from the previous value. Calling set-methods with a value of null effectively removes an attribute.


Field Summary
 
Fields inherited from interface com.sap.security.api.IUser
DEFAULT_ACCESSIBILITY_LEVEL, SCREENREADER_ACCESSIBILITY_LEVEL, VERSIONSTRING
 
Fields inherited from interface com.sap.security.api.IPrincipal
BYTE_TYPE, CREATED_BY, DATASOURCE, DEFAULT_NAMESPACE, DEFAULT_RELATION_NAMESPACE, DESCRIPTION, DISPLAYNAME, LAST_MODIFIED_BY, PRINCIPAL_CREATION_DATE, PRINCIPAL_MODIFY_DATE, PRINCIPAL_RELATION_MEMBER_ATTRIBUTE, PRINCIPAL_RELATION_PARENT_ATTRIBUTE, STRING_TYPE, TRANSIENT_NAMESPACE, UNIQUE_NAME
 
Method Summary
 void addToGroup(String uniqueIdOfGroup)
          Deprecated. use IGroupFactory.addUserToGroup(String,String) instead
 void addToRole(String uniqueIdOfRole)
          Deprecated. use IRoleFactory.addUserToRole(String, String) instead
 void removeFromGroup(String uniqueIdOfGroup)
          Deprecated. use IGroupFactory.removeUserFromGroup(String, String) instead
 void removeFromRole(String uniqueIdOfRole)
          Deprecated. use IRoleFactory.removeUserFromRole(String, String) instead
 void setAccessibilityLevel(int accessibilityLevel)
          Set the user's accessibility level used for Screen Reader Support
 boolean setCellPhone(String cellphone)
          Sets the user's default cellphone number.
 boolean setCity(String city)
          Sets the user's city.
 boolean setCompany(String companyid)
          Sets the unique ID of the user's company.
 boolean setCountry(String country)
          Sets the ISO-3166 two-letter uppercase code of the country where the user lives.
 boolean setCurrency(String currency)
          Sets the three letter uppercase code of the user's currency, e.g.
 boolean setDepartment(String department)
          Sets the user's department.
 boolean setDisplayName(String displayName)
          Sets the user's display name.
 boolean setEmail(String email)
          Sets the user's default email address.
 boolean setFax(String fax)
          Sets the user's default fax number.
 boolean setFirstName(String firstname)
          Sets the user's first name.
 boolean setJobTitle(String jobtitle)
          Sets the user's job title, e.g.
 boolean setLastName(String lastname)
          Sets the user's last name.
 boolean setLocale(Locale locale)
          Sets the user's Locale; this determines e.g. the language in which text is displayed to the user's and the style that numbers are formated.
 boolean setPersonID(String personid)
          Sets the user's personID.
 boolean setSalutation(String salutation)
          Sets the user's salutation.
 boolean setState(String state)
          Sets the user's state or region.
 boolean setStreet(String street)
          Sets the user's street.
 boolean setTelephone(String telephone)
          Sets the user's default telephone number.
 boolean setTimeZone(TimeZone timezone)
          Sets the user's time zone.
 boolean setTitle(String title)
          Sets the user's academic title or title of nobility.
 boolean setZip(String zip)
          Sets the zip code of the user's city.
 
Methods inherited from interface com.sap.security.api.IUser
checkPermission, checkPermission, getAccessibilityLevel, getCellPhone, getCity, getCompany, getCountry, getCurrency, getDepartment, getEmail, getFax, getFirstName, getI18nFormatterFactory, getJobTitle, getLastName, getLocale, getParentGroups, getPersonID, getRoles, getSalutation, getState, getStreet, getTelephone, getTimeZone, getTitle, getTransientAttribute, getUid, getUniqueName, getUserAccounts, getUserAccountUniqueIDs, getUserFactory, getZip, hasPermission, hasPermission, isCompanyUser, isMemberOfGroup, isMemberOfRole, setTransientAttribute
 
Methods inherited from interface java.security.Principal
equals, getName, hashCode, toString
 
Methods inherited from interface com.sap.security.api.IPrincipalMaint
addAttributeValue, commit, isModified, removeAttributeValue, rollback, save, setAttribute, setBinaryAttribute
 
Methods inherited from interface com.sap.security.api.IPrincipal
created, equals, getAttribute, getAttributeNames, getAttributeNamespaces, getAttributeType, getBinaryAttribute, getDisplayName, getMessages, getParents, getUniqueID, hashCode, isExistenceChecked, isMutable, lastModified, refresh
 

Method Detail

setTitle

boolean setTitle(String title)
Sets the user's academic title or title of nobility.

Parameters:
title - String containing the user's title

setSalutation

boolean setSalutation(String salutation)
Sets the user's salutation. This may include academic titles.

Parameters:
salutation - String containing the user's salutation

setJobTitle

boolean setJobTitle(String jobtitle)
Sets the user's job title, e.g. Developer, Development Architect, Development Manager etc.

Parameters:
jobtitle - String containing the user's jobtitle

setDepartment

boolean setDepartment(String department)
Sets the user's department.

Parameters:
department - String containing the user's department

setDisplayName

boolean setDisplayName(String displayName)
Sets the user's display name.

Specified by:
setDisplayName in interface IPrincipalMaint
Parameters:
displayName - String containing the user's displayName

setFirstName

boolean setFirstName(String firstname)
Sets the user's first name. This may include one or more middle names.

Parameters:
firstname - String containing the user's firstname

setLastName

boolean setLastName(String lastname)
Sets the user's last name. This may include second names.

Parameters:
lastname - String containing the user's lastname

setStreet

boolean setStreet(String street)
Sets the user's street. This may include house numbers, street numbers etc.

Parameters:
street - String containing the user's street

setCity

boolean setCity(String city)
Sets the user's city.

Parameters:
city - String containing the user's city

setZip

boolean setZip(String zip)
Sets the zip code of the user's city.

Parameters:
zip - String containing the user's zip

setState

boolean setState(String state)
Sets the user's state or region.

Parameters:
state - String containing the user's state

setCountry

boolean setCountry(String country)
Sets the ISO-3166 two-letter uppercase code of the country where the user lives.

NOTE that this is independent from the country available via getCountry() of the user's Locale, since expatriate users may not have their Locale's country set to the country where they actually reside.

Parameters:
country - String containing the user's country

setLocale

boolean setLocale(Locale locale)
Sets the user's Locale; this determines e.g. the language in which text is displayed to the user's and the style that numbers are formated.

Parameters:
locale - String containing the user's locale object

setTimeZone

boolean setTimeZone(TimeZone timezone)
Sets the user's time zone.

Parameters:
timezone - String containing the user's timezone

setCurrency

boolean setCurrency(String currency)
Sets the three letter uppercase code of the user's currency, e.g. DEM, EUR or USD.

Parameters:
currency - String containing the user's currency

setTelephone

boolean setTelephone(String telephone)
Sets the user's default telephone number.

Parameters:
telephone - String containing the user's telephone

setCellPhone

boolean setCellPhone(String cellphone)
Sets the user's default cellphone number.

Parameters:
cellphone - String containing the user's cellphone

setFax

boolean setFax(String fax)
Sets the user's default fax number.

Parameters:
fax - String containing the user's fax

setEmail

boolean setEmail(String email)
Sets the user's default email address.

Parameters:
email - String containing the user's email

setPersonID

boolean setPersonID(String personid)
Sets the user's personID.

Parameters:
personid - The new personID to set.

setCompany

boolean setCompany(String companyid)
Sets the unique ID of the user's company.

Parameters:
companyid - String containing the user's companyid

setAccessibilityLevel

void setAccessibilityLevel(int accessibilityLevel)
                           throws UMException
Set the user's accessibility level used for Screen Reader Support

Parameters:
accessibilityLevel - String containing the user's accessibility level Valid values are following constants IUser.DEFAULT_ACCESSIBILITY_LEVEL or IUser.SCREENREADER_ACCESSIBILITY_LEVEL
Throws:
UMException

addToGroup

void addToGroup(String uniqueIdOfGroup)
                throws UMException
Deprecated. use IGroupFactory.addUserToGroup(String,String) instead

Assign this principal to a group identified by uniqueIdOfGroup. Implicitly a commit is done if you call this method because the membership of groups is stored in the group's object. Be aware that adding this user to a group is done independently of committing this IUserMaint changes to the user store or to roll them back.

Parameters:
uniqueIdOfGroup - id of the group
Throws:
UMException

removeFromGroup

void removeFromGroup(String uniqueIdOfGroup)
                     throws UMException
Deprecated. use IGroupFactory.removeUserFromGroup(String, String) instead

Unassign this principal from a group identified by uniqueIdOfGroup. Implicitly a commit is done if you call this method because the membership of groups is stored in the group's object data store. Be aware that removing this user from a group is done independently of committing this IUserMaint changes to the user store or to roll them back.

Parameters:
uniqueIdOfGroup - id of the group
Throws:
UMException

addToRole

void addToRole(String uniqueIdOfRole)
               throws UMException
Deprecated. use IRoleFactory.addUserToRole(String, String) instead

Assign this principal to a role identified by uniqueIdOfRole. Implicitly a commit is done if you call this method because the membership of roles is stored in the role's object. Be aware that adding this user to a role is done independently of committing this IUserMaint changes to the user store or to roll them back.

Parameters:
uniqueIdOfRole - uniqueId of a role
Throws:
UMException

removeFromRole

void removeFromRole(String uniqueIdOfRole)
                    throws UMException
Deprecated. use IRoleFactory.removeUserFromRole(String, String) instead

Unassign this principal from a role identified by uniqueIdOfRole. Implicitly a commit is done if you call this method because the membership of roles is stored in the role's object. Be aware that removing this user from a role is done independently of committing this IUserMaint changes to the user store or to roll them back.

Parameters:
uniqueIdOfRole - uniqueId of a role
Throws:
UMException
Access Rights

This class can be accessed from:


SC DC
[sap.com] ENGINEAPI [sap.com] com.sap.security.api.sda
[sap.com] ENGFACADE [sap.com] tc/je/usermanagement/api
[sap.com] CORE-TOOLS [sap.com] com.sap.engine.client.lib


Copyright 2010 SAP AG Complete Copyright Notice