Class AddRolesToUsersServiceImpl
java.lang.Object
com.skava.auth.service.impl.userrole.AddRolesToUsersServiceImpl
- All Implemented Interfaces:
AddRolesToUsersService
,com.skava.core.EcommService<AddRolesToUsersRequest,
com.skava.core.ResponseModel>
This service class implements AddRolesToUsersService and handles the add user to role service request,
process it and save the details in DB. It also implements business logic required to add user to requested role.
- Version:
- $Id: $Id
- Author:
- Infosys Equinox
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected org.springframework.context.MessageSource
message source for message localization. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionList<com.skava.core.validation.ValidatorComponent>
This method return the list of validation components to validate the request of user's role addition.com.skava.core.ResponseModel
process
(AddRolesToUsersRequest input) This method process the user's role addition request and adds roles to users whether given request is valid.saveAllUserAttribute
(List<UserRole> userRoles) This method saves the all the user role details into the database.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.skava.core.EcommService
getValidateException, getValidator
-
Field Details
-
messageSource
@Autowired protected org.springframework.context.MessageSource messageSourcemessage source for message localization.
-
-
Constructor Details
-
AddRolesToUsersServiceImpl
public AddRolesToUsersServiceImpl()The class constructor.
-
-
Method Details
-
process
@SendEvent(eventType="authservice/userrole/create", identifier="request_userRoles.userId") public com.skava.core.ResponseModel process(AddRolesToUsersRequest input) This method process the user's role addition request and adds roles to users whether given request is valid.- Specified by:
process
in interfacecom.skava.core.EcommService<AddRolesToUsersRequest,
com.skava.core.ResponseModel> - Parameters:
input
- aAddRolesToUsersRequest
object.- Returns:
- a
ResponseModel
object.
-
getValidator
This method return the list of validation components to validate the request of user's role addition.- Specified by:
getValidator
in interfacecom.skava.core.EcommService<AddRolesToUsersRequest,
com.skava.core.ResponseModel> - Returns:
- a
List
ofValidatorComponent
objects.
-
saveAllUserAttribute
This method saves the all the user role details into the database.
-