user

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Apr 10, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package user package is to manage the context of user information

Package user package is to manage the context of user information

Package user package is to manage the context of user information

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetBaseUserInfoFromReq

func GetBaseUserInfoFromReq(req *restful.Request) *metav1alpha1.GitUserBaseInfo

GetBaseUserInfoFromReq get the base userinfo from the request object

func UserInfoFilter

func UserInfoFilter(req *restful.Request, res *restful.Response, chain *restful.FilterChain)

UserInfoFilter is to parse the user login information from the request header into userinfo, and store it in the context

func UserInfoFrom

func UserInfoFrom(ctx context.Context) (metav1alpha1.UserInfo, bool)

UserInfoFrom returns the value of the userinfo key on the ctx

func UserInfoValue

func UserInfoValue(ctx context.Context) (result metav1alpha1.UserInfo)

UserInfoValue returns the value of the userinfo key on the ctx, or the empty string if none

func WithUserInfo

func WithUserInfo(parent context.Context, userinfo metav1alpha1.UserInfo) context.Context

WithUserInfo returns a copy of parent in which the userinfo value is set

Types

This section is empty.

Directories

Path Synopsis
Package matching contains useful functionality for matching users
Package matching contains useful functionality for matching users

Jump to

Keyboard shortcuts

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