Package org.openwms.core.uaa
Class UserController
java.lang.Object
org.openwms.core.http.AbstractWebController
org.openwms.core.uaa.UserController
@Validated
@Transactional
@MeasuredRestController
public class UserController
extends org.openwms.core.http.AbstractWebController
An UserController represents a RESTful access to 
Users. It is transactional by the means it is the outer application service
 facade that returns validated and completed User objects to its clients.- Author:
- Heiko Scherrer
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprivate final RoleMapperprivate final SecurityObjectMapperprivate final org.ameba.i18n.Translatorprivate final UserMapperprivate final UserService
- 
Constructor SummaryConstructorsConstructorDescriptionUserController(org.ameba.i18n.Translator translator, UserService userService, UserMapper userMapper, RoleMapper roleMapper, SecurityObjectMapper securityObjectMapper) 
- 
Method SummaryModifier and TypeMethodDescriptionprivate voidaddSelfLink(UserVO result) org.springframework.http.ResponseEntity<UserVO> org.springframework.http.ResponseEntity<Void> org.springframework.http.ResponseEntity<UserVO> findByPKey(String pKey) org.springframework.http.ResponseEntity<AuthenticatedUserVO> findByUsername(String username) org.springframework.http.ResponseEntity<List<SecurityObjectVO>> findGrantsForUser(String pKey) findRolesForUser(@NotEmpty String pKey) org.springframework.http.ResponseEntity<org.openwms.core.http.Index> index()org.springframework.http.ResponseEntity<UserVO> org.springframework.http.ResponseEntity<Void> org.springframework.http.ResponseEntity<UserVO> updatePassword(String pKey, @NotNull PasswordString password) Methods inherited from class org.openwms.core.http.AbstractWebControllerbuildNOKResponse, buildNOKResponseWithKey, buildOKResponse, buildResponse, buildResponse, getLocationForCreatedResource, getLocationURIForCreatedResource, handleBehaviorAwareException, handleBusinessRuntimeException, handleConstraintViolationException, handleException, handleHttpBusinessException, handleRemovalNotAllowedException, handleTechnicalRuntimeException, handleValidationException, illegalArgumentException, translate
- 
Field Details- 
translatorprivate final org.ameba.i18n.Translator translator
- 
userService
- 
userMapper
- 
roleMapper
- 
securityObjectMapper
 
- 
- 
Constructor Details- 
UserControllerpublic UserController(org.ameba.i18n.Translator translator, UserService userService, UserMapper userMapper, RoleMapper roleMapper, SecurityObjectMapper securityObjectMapper) 
 
- 
- 
Method Details- 
index@GetMapping("/users/index") @Transactional(propagation=NEVER) public org.springframework.http.ResponseEntity<org.openwms.core.http.Index> index()
- 
findByPKey
- 
findByUsername@GetMapping(value="/users", params="username") public org.springframework.http.ResponseEntity<AuthenticatedUserVO> findByUsername(@RequestParam("username") String username) 
- 
findAllUsers
- 
findGrantsForUser@GetMapping("/users/{pKey}/grants") public org.springframework.http.ResponseEntity<List<SecurityObjectVO>> findGrantsForUser(@PathVariable("pKey") String pKey) 
- 
findRolesForUser
- 
create@PostMapping("/users") @Validated(Create.class) public org.springframework.http.ResponseEntity<UserVO> create(@RequestBody @Valid @NotNull @Valid @NotNull UserVO vo, jakarta.servlet.http.HttpServletRequest req) 
- 
save@PutMapping("/users") @Validated(Modify.class) public org.springframework.http.ResponseEntity<UserVO> save(@RequestBody @Valid @NotNull @Valid @NotNull UserVO vo) 
- 
saveImage
- 
updatePassword@PostMapping("/users/{pKey}/password") public org.springframework.http.ResponseEntity<UserVO> updatePassword(@PathVariable("pKey") String pKey, @RequestBody @NotNull @NotNull PasswordString password) 
- 
delete
- 
addSelfLink
 
-