rest

package
v3.0.0-rc4+incompatible Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 18, 2021 License: AGPL-3.0 Imports: 28 Imported by: 0

Documentation

Overview

Package rest provides a gateway to the underlying grpc service

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type UserHandler

type UserHandler struct {
	resources.ResourceProviderHandler
}

func NewUserHandler

func NewUserHandler() *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 added in v1.4.0

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.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL