org.appng.appngizer.controller

## Class RoleController

- java.lang.Object
- - org.appng.appngizer.controller.ControllerBase
  - - org.appng.appngizer.controller.RoleController

-     @RestController
      public class RoleController
      extends ControllerBase

- - ### Field Summary

    - ### Fields inherited from class org.appng.appngizer.controller.ControllerBase

      `configurer, context, coreService, databaseService, session, templateService`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `RoleController()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected void` | `addPermissionsAndSave(String app, Role role, RoleImpl appRole)`
    `org.springframework.http.ResponseEntity<Role>` | `createRole(String app, Role role)`
    `org.springframework.http.ResponseEntity<Void>` | `deleteRole(String app, String name)`
    `org.springframework.http.ResponseEntity<Role>` | `getRole(String app, String name)`
    `org.springframework.http.ResponseEntity<Roles>` | `listRoles(String app)`
    `org.springframework.http.ResponseEntity<Role>` | `updateRole(String app, String name, Role role)`

    - ### Methods inherited from class org.appng.appngizer.controller.ControllerBase

      `getDatabaseStatus, getSharedSecret, onBusinessException, onConflictException, onConstraintViolationException`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### RoleController

          public RoleController()

  - ### Method Detail

    - #### listRoles

          @GetMapping(value="/application/{app}/role")
          public org.springframework.http.ResponseEntity<Roles> listRoles(@PathVariable(value="app")
                                                                                                                       String app)

    - #### getRole

          @GetMapping(value="/application/{app}/role/{name:.+}")
          public org.springframework.http.ResponseEntity<Role> getRole(@PathVariable(value="app")
                                                                                                                              String app,
                                                                                                                              @PathVariable(value="name")
                                                                                                                              String name)

    - #### createRole

          @PostMapping(value="/application/{app}/role")
          public org.springframework.http.ResponseEntity<Role> createRole(@PathVariable(value="app")
                                                                                                                        String app,
                                                                                                                        @RequestBody
                                                                                                                        Role role)

    - #### updateRole

          @PutMapping(value="/application/{app}/role/{name:.+}")
          public org.springframework.http.ResponseEntity<Role> updateRole(@PathVariable(value="app")
                                                                                                                                 String app,
                                                                                                                                 @PathVariable(value="name")
                                                                                                                                 String name,
                                                                                                                                 @RequestBody
                                                                                                                                 Role role)

    - #### addPermissionsAndSave

          protected void addPermissionsAndSave(String app,
                                               Role role,
                                               RoleImpl appRole)

    - #### deleteRole

          @DeleteMapping(value="/application/{app}/role/{name:.+}")
          public org.springframework.http.ResponseEntity<Void> deleteRole(@PathVariable(value="app")
                                                                                                                                    String app,
                                                                                                                                    @PathVariable(value="name")
                                                                                                                                    String name)
                                                                                                                             throws BusinessException

      Throws:
        `BusinessException`

Copyright © 2011–2023 aiticon GmbH. All rights reserved.