Documentation ¶
Overview ¶
Package rest provides a gateway to the underlying grpc service
Index ¶
- type UserHandler
- func (s *UserHandler) DeleteUser(req *restful.Request, rsp *restful.Response)
- func (s *UserHandler) Filter() func(string) string
- func (s *UserHandler) GetUser(req *restful.Request, rsp *restful.Response)
- func (s *UserHandler) PoliciesForUserId(ctx context.Context, resourceId string, resourceClient interface{}) (policies []*service2.ResourcePolicy, e error)
- func (s *UserHandler) PutRoles(req *restful.Request, rsp *restful.Response)
- func (s *UserHandler) PutUser(req *restful.Request, rsp *restful.Response)
- func (s *UserHandler) SearchUsers(req *restful.Request, rsp *restful.Response)
- func (s *UserHandler) SwaggerTags() []string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type UserHandler ¶
type UserHandler struct { RuntimeCtx context.Context resources.ResourceProviderHandler }
func NewUserHandler ¶
func NewUserHandler(ctx context.Context) *UserHandler
func (*UserHandler) DeleteUser ¶
func (s *UserHandler) DeleteUser(req *restful.Request, rsp *restful.Response)
DeleteUser removes a user or group from the repository.
func (*UserHandler) Filter ¶
func (s *UserHandler) Filter() func(string) string
Filter returns a function to filter the swagger path.
func (*UserHandler) GetUser ¶
func (s *UserHandler) GetUser(req *restful.Request, rsp *restful.Response)
GetUser finds a user by her login, answering to rest endpoint GET:/a/user/{Login}.
func (*UserHandler) PoliciesForUserId ¶
func (s *UserHandler) PoliciesForUserId(ctx context.Context, resourceId string, resourceClient interface{}) (policies []*service2.ResourcePolicy, e error)
PoliciesForUserId retrieves policies for a given UserId.
func (*UserHandler) PutRoles ¶
func (s *UserHandler) PutRoles(req *restful.Request, rsp *restful.Response)
PutRoles updates an existing user with the passed list of roles.
func (*UserHandler) PutUser ¶
func (s *UserHandler) PutUser(req *restful.Request, rsp *restful.Response)
PutUser creates or updates a User if calling client has sufficient permissions.
func (*UserHandler) SearchUsers ¶
func (s *UserHandler) SearchUsers(req *restful.Request, rsp *restful.Response)
SearchUsers performs a paginated query to the user repository. Warning: in the returned result, users and groups are stored in two distinct arrays.
func (*UserHandler) SwaggerTags ¶
func (s *UserHandler) SwaggerTags() []string
SwaggerTags list the names of the service tags declared in the swagger json implemented by this service.