authentication

package
v1.3.4 Latest Latest
Warning

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

Go to latest
Published: Jun 17, 2021 License: NCSA Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const LoginOKCode int = 200

LoginOKCode is the HTTP code returned for type LoginOK

View Source
const LogoutOKCode int = 200

LogoutOKCode is the HTTP code returned for type LogoutOK

View Source
const SignupOKCode int = 200

SignupOKCode is the HTTP code returned for type SignupOK

View Source
const UpdateOKCode int = 200

UpdateOKCode is the HTTP code returned for type UpdateOK

View Source
const UserInfoOKCode int = 200

UserInfoOKCode is the HTTP code returned for type UserInfoOK

Variables

This section is empty.

Functions

This section is empty.

Types

type Login

type Login struct {
	Context *middleware.Context
	Handler LoginHandler
}

Login swagger:route POST /auth/login Authentication login

Login to MLModelScope platform

func NewLogin

func NewLogin(ctx *middleware.Context, handler LoginHandler) *Login

NewLogin creates a new http.Handler for the login operation

func (*Login) ServeHTTP

func (o *Login) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type LoginHandler

type LoginHandler interface {
	Handle(LoginParams, *models.User) middleware.Responder
}

LoginHandler interface for that can handle valid login params

type LoginHandlerFunc

type LoginHandlerFunc func(LoginParams, *models.User) middleware.Responder

LoginHandlerFunc turns a function with the right signature into a login handler

func (LoginHandlerFunc) Handle

func (fn LoginHandlerFunc) Handle(params LoginParams, principal *models.User) middleware.Responder

Handle executing the request and returning a response

type LoginOK

type LoginOK struct {

	/*
	  In: Body
	*/
	Payload *models.DlframeworkLoginResponse `json:"body,omitempty"`
}

LoginOK login o k

swagger:response loginOK

func NewLoginOK

func NewLoginOK() *LoginOK

NewLoginOK creates LoginOK with default headers values

func (*LoginOK) SetPayload

func (o *LoginOK) SetPayload(payload *models.DlframeworkLoginResponse)

SetPayload sets the payload to the login o k response

func (*LoginOK) WithPayload

func (o *LoginOK) WithPayload(payload *models.DlframeworkLoginResponse) *LoginOK

WithPayload adds the payload to the login o k response

func (*LoginOK) WriteResponse

func (o *LoginOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type LoginParams

type LoginParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`
}

LoginParams contains all the bound params for the login operation typically these are obtained from a http.Request

swagger:parameters Login

func NewLoginParams

func NewLoginParams() LoginParams

NewLoginParams creates a new LoginParams object no default values defined in spec.

func (*LoginParams) BindRequest

func (o *LoginParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewLoginParams() beforehand.

type LoginURL

type LoginURL struct {
	// contains filtered or unexported fields
}

LoginURL generates an URL for the login operation

func (*LoginURL) Build

func (o *LoginURL) Build() (*url.URL, error)

Build a url path and query string

func (*LoginURL) BuildFull

func (o *LoginURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*LoginURL) Must

func (o *LoginURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*LoginURL) SetBasePath

func (o *LoginURL) SetBasePath(bp string)

SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

func (*LoginURL) String

func (o *LoginURL) String() string

String returns the string representation of the path with query string

func (*LoginURL) StringFull

func (o *LoginURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*LoginURL) WithBasePath

func (o *LoginURL) WithBasePath(bp string) *LoginURL

WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

type Logout

type Logout struct {
	Context *middleware.Context
	Handler LogoutHandler
}

Logout swagger:route POST /auth/logout Authentication logout

Logout from MLModelScope platform

func NewLogout

func NewLogout(ctx *middleware.Context, handler LogoutHandler) *Logout

NewLogout creates a new http.Handler for the logout operation

func (*Logout) ServeHTTP

func (o *Logout) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type LogoutHandler

type LogoutHandler interface {
	Handle(LogoutParams) middleware.Responder
}

LogoutHandler interface for that can handle valid logout params

type LogoutHandlerFunc

type LogoutHandlerFunc func(LogoutParams) middleware.Responder

LogoutHandlerFunc turns a function with the right signature into a logout handler

func (LogoutHandlerFunc) Handle

Handle executing the request and returning a response

type LogoutOK

type LogoutOK struct {

	/*
	  In: Body
	*/
	Payload *models.DlframeworkLogoutResponse `json:"body,omitempty"`
}

LogoutOK logout o k

swagger:response logoutOK

func NewLogoutOK

func NewLogoutOK() *LogoutOK

NewLogoutOK creates LogoutOK with default headers values

func (*LogoutOK) SetPayload

func (o *LogoutOK) SetPayload(payload *models.DlframeworkLogoutResponse)

SetPayload sets the payload to the logout o k response

func (*LogoutOK) WithPayload

func (o *LogoutOK) WithPayload(payload *models.DlframeworkLogoutResponse) *LogoutOK

WithPayload adds the payload to the logout o k response

func (*LogoutOK) WriteResponse

func (o *LogoutOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type LogoutParams

type LogoutParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`
}

LogoutParams contains all the bound params for the logout operation typically these are obtained from a http.Request

swagger:parameters Logout

func NewLogoutParams

func NewLogoutParams() LogoutParams

NewLogoutParams creates a new LogoutParams object no default values defined in spec.

func (*LogoutParams) BindRequest

func (o *LogoutParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewLogoutParams() beforehand.

type LogoutURL

type LogoutURL struct {
	// contains filtered or unexported fields
}

LogoutURL generates an URL for the logout operation

func (*LogoutURL) Build

func (o *LogoutURL) Build() (*url.URL, error)

Build a url path and query string

func (*LogoutURL) BuildFull

func (o *LogoutURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*LogoutURL) Must

func (o *LogoutURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*LogoutURL) SetBasePath

func (o *LogoutURL) SetBasePath(bp string)

SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

func (*LogoutURL) String

func (o *LogoutURL) String() string

String returns the string representation of the path with query string

func (*LogoutURL) StringFull

func (o *LogoutURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*LogoutURL) WithBasePath

func (o *LogoutURL) WithBasePath(bp string) *LogoutURL

WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

type Signup

type Signup struct {
	Context *middleware.Context
	Handler SignupHandler
}

Signup swagger:route POST /auth/signup Authentication signup

Signup to MLModelScope platform

func NewSignup

func NewSignup(ctx *middleware.Context, handler SignupHandler) *Signup

NewSignup creates a new http.Handler for the signup operation

func (*Signup) ServeHTTP

func (o *Signup) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type SignupHandler

type SignupHandler interface {
	Handle(SignupParams) middleware.Responder
}

SignupHandler interface for that can handle valid signup params

type SignupHandlerFunc

type SignupHandlerFunc func(SignupParams) middleware.Responder

SignupHandlerFunc turns a function with the right signature into a signup handler

func (SignupHandlerFunc) Handle

Handle executing the request and returning a response

type SignupOK

type SignupOK struct {

	/*
	  In: Body
	*/
	Payload *models.DlframeworkSignupResponse `json:"body,omitempty"`
}

SignupOK signup o k

swagger:response signupOK

func NewSignupOK

func NewSignupOK() *SignupOK

NewSignupOK creates SignupOK with default headers values

func (*SignupOK) SetPayload

func (o *SignupOK) SetPayload(payload *models.DlframeworkSignupResponse)

SetPayload sets the payload to the signup o k response

func (*SignupOK) WithPayload

func (o *SignupOK) WithPayload(payload *models.DlframeworkSignupResponse) *SignupOK

WithPayload adds the payload to the signup o k response

func (*SignupOK) WriteResponse

func (o *SignupOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type SignupParams

type SignupParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`

	/*
	  Required: true
	  In: body
	*/
	Body *models.DlframeworkSignup
}

SignupParams contains all the bound params for the signup operation typically these are obtained from a http.Request

swagger:parameters Signup

func NewSignupParams

func NewSignupParams() SignupParams

NewSignupParams creates a new SignupParams object no default values defined in spec.

func (*SignupParams) BindRequest

func (o *SignupParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewSignupParams() beforehand.

type SignupURL

type SignupURL struct {
	// contains filtered or unexported fields
}

SignupURL generates an URL for the signup operation

func (*SignupURL) Build

func (o *SignupURL) Build() (*url.URL, error)

Build a url path and query string

func (*SignupURL) BuildFull

func (o *SignupURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*SignupURL) Must

func (o *SignupURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*SignupURL) SetBasePath

func (o *SignupURL) SetBasePath(bp string)

SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

func (*SignupURL) String

func (o *SignupURL) String() string

String returns the string representation of the path with query string

func (*SignupURL) StringFull

func (o *SignupURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*SignupURL) WithBasePath

func (o *SignupURL) WithBasePath(bp string) *SignupURL

WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

type Update

type Update struct {
	Context *middleware.Context
	Handler UpdateHandler
}

Update swagger:route POST /auth/update Authentication update

Update User Info on MLModelScope platform

func NewUpdate

func NewUpdate(ctx *middleware.Context, handler UpdateHandler) *Update

NewUpdate creates a new http.Handler for the update operation

func (*Update) ServeHTTP

func (o *Update) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type UpdateHandler

type UpdateHandler interface {
	Handle(UpdateParams, *models.User) middleware.Responder
}

UpdateHandler interface for that can handle valid update params

type UpdateHandlerFunc

type UpdateHandlerFunc func(UpdateParams, *models.User) middleware.Responder

UpdateHandlerFunc turns a function with the right signature into a update handler

func (UpdateHandlerFunc) Handle

func (fn UpdateHandlerFunc) Handle(params UpdateParams, principal *models.User) middleware.Responder

Handle executing the request and returning a response

type UpdateOK

type UpdateOK struct {

	/*
	  In: Body
	*/
	Payload *models.DlframeworkUpdateResponse `json:"body,omitempty"`
}

UpdateOK update o k

swagger:response updateOK

func NewUpdateOK

func NewUpdateOK() *UpdateOK

NewUpdateOK creates UpdateOK with default headers values

func (*UpdateOK) SetPayload

func (o *UpdateOK) SetPayload(payload *models.DlframeworkUpdateResponse)

SetPayload sets the payload to the update o k response

func (*UpdateOK) WithPayload

func (o *UpdateOK) WithPayload(payload *models.DlframeworkUpdateResponse) *UpdateOK

WithPayload adds the payload to the update o k response

func (*UpdateOK) WriteResponse

func (o *UpdateOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type UpdateParams

type UpdateParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`
}

UpdateParams contains all the bound params for the update operation typically these are obtained from a http.Request

swagger:parameters Update

func NewUpdateParams

func NewUpdateParams() UpdateParams

NewUpdateParams creates a new UpdateParams object no default values defined in spec.

func (*UpdateParams) BindRequest

func (o *UpdateParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewUpdateParams() beforehand.

type UpdateURL

type UpdateURL struct {
	// contains filtered or unexported fields
}

UpdateURL generates an URL for the update operation

func (*UpdateURL) Build

func (o *UpdateURL) Build() (*url.URL, error)

Build a url path and query string

func (*UpdateURL) BuildFull

func (o *UpdateURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*UpdateURL) Must

func (o *UpdateURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*UpdateURL) SetBasePath

func (o *UpdateURL) SetBasePath(bp string)

SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

func (*UpdateURL) String

func (o *UpdateURL) String() string

String returns the string representation of the path with query string

func (*UpdateURL) StringFull

func (o *UpdateURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*UpdateURL) WithBasePath

func (o *UpdateURL) WithBasePath(bp string) *UpdateURL

WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

type UserInfo

type UserInfo struct {
	Context *middleware.Context
	Handler UserInfoHandler
}

UserInfo swagger:route GET /auth/userinfo Authentication userInfo

Get User's information

func NewUserInfo

func NewUserInfo(ctx *middleware.Context, handler UserInfoHandler) *UserInfo

NewUserInfo creates a new http.Handler for the user info operation

func (*UserInfo) ServeHTTP

func (o *UserInfo) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type UserInfoHandler

type UserInfoHandler interface {
	Handle(UserInfoParams) middleware.Responder
}

UserInfoHandler interface for that can handle valid user info params

type UserInfoHandlerFunc

type UserInfoHandlerFunc func(UserInfoParams) middleware.Responder

UserInfoHandlerFunc turns a function with the right signature into a user info handler

func (UserInfoHandlerFunc) Handle

Handle executing the request and returning a response

type UserInfoOK

type UserInfoOK struct {

	/*
	  In: Body
	*/
	Payload *models.DlframeworkUserInfoResponse `json:"body,omitempty"`
}

UserInfoOK user info o k

swagger:response userInfoOK

func NewUserInfoOK

func NewUserInfoOK() *UserInfoOK

NewUserInfoOK creates UserInfoOK with default headers values

func (*UserInfoOK) SetPayload

func (o *UserInfoOK) SetPayload(payload *models.DlframeworkUserInfoResponse)

SetPayload sets the payload to the user info o k response

func (*UserInfoOK) WithPayload

func (o *UserInfoOK) WithPayload(payload *models.DlframeworkUserInfoResponse) *UserInfoOK

WithPayload adds the payload to the user info o k response

func (*UserInfoOK) WriteResponse

func (o *UserInfoOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type UserInfoParams

type UserInfoParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`
}

UserInfoParams contains all the bound params for the user info operation typically these are obtained from a http.Request

swagger:parameters UserInfo

func NewUserInfoParams

func NewUserInfoParams() UserInfoParams

NewUserInfoParams creates a new UserInfoParams object no default values defined in spec.

func (*UserInfoParams) BindRequest

func (o *UserInfoParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewUserInfoParams() beforehand.

type UserInfoURL

type UserInfoURL struct {
	// contains filtered or unexported fields
}

UserInfoURL generates an URL for the user info operation

func (*UserInfoURL) Build

func (o *UserInfoURL) Build() (*url.URL, error)

Build a url path and query string

func (*UserInfoURL) BuildFull

func (o *UserInfoURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*UserInfoURL) Must

func (o *UserInfoURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*UserInfoURL) SetBasePath

func (o *UserInfoURL) SetBasePath(bp string)

SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

func (*UserInfoURL) String

func (o *UserInfoURL) String() string

String returns the string representation of the path with query string

func (*UserInfoURL) StringFull

func (o *UserInfoURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*UserInfoURL) WithBasePath

func (o *UserInfoURL) WithBasePath(bp string) *UserInfoURL

WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

Jump to

Keyboard shortcuts

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