@PermitAll public abstract class PersonServiceBase extends com.whitestein.lsps.common.SecureAndLoggingService implements PersonService
PersonServiceBean nad PersonManagementServiceBean| Modifier and Type | Field and Description |
|---|---|
protected static java.lang.String |
ARGUMENT_PERSON_ID |
protected static java.lang.String |
ARGUMENT_SETTING_NAME |
| Constructor and Description |
|---|
PersonServiceBase() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
checkActivePersonWithLoginExists(java.lang.String loginName)
Answer whether active person for given loginName exists.
|
protected Person |
checkPersonWithIdExists(java.lang.String personId) |
void |
deleteSetting(java.lang.String personId,
java.lang.String settingName)
Deletes the given personal setting.
|
PersonList |
findPersons(PersonCriteria criteria)
Returns a PersonList with Persons defined by the given
personCriteria argument. |
Person |
getPerson(java.lang.String personId)
Returns a
Person instance if such person (identified by id) exists in the
application. |
Person |
getPersonByLogin(java.lang.String loginName)
Returns a
Person instance if such person (identified by login) exists in the
application. |
protected abstract PersonDao |
getPersonDao()
Returns person service dao.
|
PersonPicture |
getPersonPicture(java.lang.String personId)
Returns picture for person.
|
protected Person |
getPersonWithLogin(java.lang.String name) |
ByteData |
getSetting(java.lang.String personId,
java.lang.String settingName)
Returns the personal setting with the given name.
|
boolean |
hasPersonAnyRight(java.lang.String loginName,
java.util.List<java.lang.String> rights)
Answer whether person is active and has any of the given rights
|
void |
setPersonPicture(java.lang.String personId,
PersonPicture picture)
Sets picture for person.
|
void |
setSetting(java.lang.String personId,
java.lang.String settingName,
ByteData settingContent)
Sets the given personal setting.
|
protected static final java.lang.String ARGUMENT_PERSON_ID
protected static final java.lang.String ARGUMENT_SETTING_NAME
protected abstract PersonDao getPersonDao()
@RightsAllowed(value="Person:Read") public Person getPerson(java.lang.String personId)
PersonServicePerson instance if such person (identified by id) exists in the
application.getPerson in interface PersonServicepersonId - id of the person to findPerson instance if such person exists, otherwise null@RightsAllowed(value="Person:Read") public Person getPersonByLogin(java.lang.String loginName)
PersonServicePerson instance if such person (identified by login) exists in the
application.getPersonByLogin in interface PersonServiceloginName - login of the person to findPerson instance if such person exists in the application, otherwise nullpublic boolean checkActivePersonWithLoginExists(java.lang.String loginName)
PersonServicecheckActivePersonWithLoginExists in interface PersonServiceloginName - loginName of the person to find@RightsAllowed(value="Person:Read") public PersonList findPersons(PersonCriteria criteria)
PersonServicepersonCriteria argument.findPersons in interface PersonServicecriteria - PersonCriteria instance that specifies a paging and filtering criteria for
querying personspersonCriteria argument.@RightsAllowed(value="Person:Read") public ByteData getSetting(java.lang.String personId, java.lang.String settingName) throws PersonNotFoundException
PersonServicegetSetting in interface PersonServicepersonId - id name of the person for which the setting should be returnedsettingName - name of the settingPersonNotFoundException - if no person is found for the personId@RightsAllowed(value="Person:Read")
public void setSetting(java.lang.String personId,
java.lang.String settingName,
ByteData settingContent)
throws PersonNotFoundException
PersonServicesetSetting in interface PersonServicepersonId - id of the person for which the setting should be setsettingName - name of the settingsettingContent - setting contentPersonNotFoundException - if no person is found for the personId@RightsAllowed(value="Person:Read")
public void deleteSetting(java.lang.String personId,
java.lang.String settingName)
throws PersonNotFoundException
PersonServicedeleteSetting in interface PersonServicepersonId - id of the person for which the setting should be deletedsettingName - name of the settingPersonNotFoundException - if no person is found for the personId@RightsAllowed(value="Person:Read")
public boolean hasPersonAnyRight(java.lang.String loginName,
java.util.List<java.lang.String> rights)
PersonServicehasPersonAnyRight in interface PersonServiceloginName - login of the person to findrights - the rights person is required to have (at least one of them) or null if none is requiredpublic PersonPicture getPersonPicture(java.lang.String personId) throws PersonNotFoundException, PersonPictureException
PersonServicegetPersonPicture in interface PersonServicePersonNotFoundExceptionPersonPictureExceptionpublic void setPersonPicture(java.lang.String personId,
PersonPicture picture)
throws PersonNotFoundException,
PersonPictureException
PersonServicesetPersonPicture in interface PersonServicePersonNotFoundExceptionPersonPictureExceptionprotected Person checkPersonWithIdExists(java.lang.String personId) throws PersonNotFoundException
personId - PersonNotFoundExceptionprotected Person getPersonWithLogin(java.lang.String name) throws PersonNotFoundException
name - PersonNotFoundExceptionCopyright © 2007-2020 Whitestein Technologies. All Rights Reserved.