bootstrapping

package
v0.0.0-...-b1a38c4 Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2024 License: Apache-2.0 Imports: 47 Imported by: 0

Documentation

Overview

Package bootstrapping provides primitives to interact with the openapi HTTP API.

Code generated by github.com/deepmap/oapi-codegen/v2 version v2.0.1-0.20240123090344-d326c01d279a DO NOT EDIT.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetKinOpenApi3Document

func GetKinOpenApi3Document() (*openapi3.T, error)

func GetKinOpenApi3DocumentMust

func GetKinOpenApi3DocumentMust() *openapi3.T

func NewBootstrappingInfoRequestRequest

func NewBootstrappingInfoRequestRequest(server string) (*http.Request, error)

NewBootstrappingInfoRequestRequest generates requests for BootstrappingInfoRequest

func RegisterHandlers

func RegisterHandlers(router gin.IRouter, si ServerInterface)

RegisterHandlers creates http.Handler with routing matching OpenAPI spec.

func RegisterHandlersWithOptions

func RegisterHandlersWithOptions(router gin.IRouter, si ServerInterface, options GinServerOptions)

RegisterHandlersWithOptions creates http.Handler with additional options

Types

type BootstrappingInfo

type BootstrappingInfo struct {
	// Links Map of link objects where the keys are the link relations defined in 3GPP TS 29.510 clause 6.4.6.3.3
	Links map[string]externalRef0.LinksValueSchema `json:"_links"`

	// Status Overal status of the NRF
	Status               *Status                `json:"status,omitempty"`
	AdditionalProperties map[string]interface{} `json:"-"`
}

BootstrappingInfo Information returned by NRF in the bootstrapping response message

func (BootstrappingInfo) Get

func (a BootstrappingInfo) Get(fieldName string) (value interface{}, found bool)

Getter for additional properties for BootstrappingInfo. Returns the specified element and whether it was found

func (BootstrappingInfo) MarshalJSON

func (a BootstrappingInfo) MarshalJSON() ([]byte, error)

Override default JSON handling for BootstrappingInfo to handle AdditionalProperties

func (*BootstrappingInfo) Set

func (a *BootstrappingInfo) Set(fieldName string, value interface{})

Setter for additional properties for BootstrappingInfo

func (*BootstrappingInfo) UnmarshalJSON

func (a *BootstrappingInfo) UnmarshalJSON(b []byte) error

Override default JSON handling for BootstrappingInfo to handle AdditionalProperties

type BootstrappingInfoRequest200Application3gppHalPlusJSONResponse

type BootstrappingInfoRequest200Application3gppHalPlusJSONResponse BootstrappingInfo

func (BootstrappingInfoRequest200Application3gppHalPlusJSONResponse) VisitBootstrappingInfoRequestResponse

func (response BootstrappingInfoRequest200Application3gppHalPlusJSONResponse) VisitBootstrappingInfoRequestResponse(w http.ResponseWriter) error

type BootstrappingInfoRequest307JSONResponse

type BootstrappingInfoRequest307JSONResponse struct {
	Body    externalRef0.RedirectResponse
	Headers BootstrappingInfoRequest307ResponseHeaders
}

func (BootstrappingInfoRequest307JSONResponse) VisitBootstrappingInfoRequestResponse

func (response BootstrappingInfoRequest307JSONResponse) VisitBootstrappingInfoRequestResponse(w http.ResponseWriter) error

type BootstrappingInfoRequest307ResponseHeaders

type BootstrappingInfoRequest307ResponseHeaders struct {
	Location string
}

type BootstrappingInfoRequest308JSONResponse

type BootstrappingInfoRequest308JSONResponse struct {
	Body    externalRef0.RedirectResponse
	Headers BootstrappingInfoRequest308ResponseHeaders
}

func (BootstrappingInfoRequest308JSONResponse) VisitBootstrappingInfoRequestResponse

func (response BootstrappingInfoRequest308JSONResponse) VisitBootstrappingInfoRequestResponse(w http.ResponseWriter) error

type BootstrappingInfoRequest308ResponseHeaders

type BootstrappingInfoRequest308ResponseHeaders struct {
	Location string
}

type BootstrappingInfoRequest400ApplicationProblemPlusJSONResponse

type BootstrappingInfoRequest400ApplicationProblemPlusJSONResponse struct {
	externalRef0.N400ApplicationProblemPlusJSONResponse
}

func (BootstrappingInfoRequest400ApplicationProblemPlusJSONResponse) VisitBootstrappingInfoRequestResponse

func (response BootstrappingInfoRequest400ApplicationProblemPlusJSONResponse) VisitBootstrappingInfoRequestResponse(w http.ResponseWriter) error

type BootstrappingInfoRequest500ApplicationProblemPlusJSONResponse

type BootstrappingInfoRequest500ApplicationProblemPlusJSONResponse struct {
	externalRef0.N500ApplicationProblemPlusJSONResponse
}

func (BootstrappingInfoRequest500ApplicationProblemPlusJSONResponse) VisitBootstrappingInfoRequestResponse

func (response BootstrappingInfoRequest500ApplicationProblemPlusJSONResponse) VisitBootstrappingInfoRequestResponse(w http.ResponseWriter) error

type BootstrappingInfoRequestRequestObject

type BootstrappingInfoRequestRequestObject struct {
}

type BootstrappingInfoRequestResponse

type BootstrappingInfoRequestResponse struct {
	Body                          []byte
	HTTPResponse                  *http.Response
	Application3gppHalJSON200     *BootstrappingInfo
	JSON307                       *externalRef0.RedirectResponse
	JSON308                       *externalRef0.RedirectResponse
	ApplicationproblemJSON400     *externalRef0.N400
	ApplicationproblemJSON500     *externalRef0.N500
	ApplicationproblemJSONDefault *externalRef0.Default
}

func ParseBootstrappingInfoRequestResponse

func ParseBootstrappingInfoRequestResponse(rsp *http.Response) (*BootstrappingInfoRequestResponse, error)

ParseBootstrappingInfoRequestResponse parses an HTTP response from a BootstrappingInfoRequestWithResponse call

func (BootstrappingInfoRequestResponse) Status

Status returns HTTPResponse.Status

func (BootstrappingInfoRequestResponse) StatusCode

func (r BootstrappingInfoRequestResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type BootstrappingInfoRequestResponseObject

type BootstrappingInfoRequestResponseObject interface {
	VisitBootstrappingInfoRequestResponse(w http.ResponseWriter) error
}

type BootstrappingInfoRequestdefaultApplicationProblemPlusJSONResponse

type BootstrappingInfoRequestdefaultApplicationProblemPlusJSONResponse struct {
	Body       externalRef0.ProblemDetails
	StatusCode int
}

func (BootstrappingInfoRequestdefaultApplicationProblemPlusJSONResponse) VisitBootstrappingInfoRequestResponse

func (response BootstrappingInfoRequestdefaultApplicationProblemPlusJSONResponse) VisitBootstrappingInfoRequestResponse(w http.ResponseWriter) error

type Client

type Client struct {
	// The endpoint of the server conforming to this interface, with scheme,
	// https://api.deepmap.com for example. This can contain a path relative
	// to the server, such as https://api.deepmap.com/dev-test, and all the
	// paths in the swagger spec will be appended to the server.
	Server string

	// Doer for performing requests, typically a *http.Client with any
	// customized settings, such as certificate chains.
	Client HttpRequestDoer

	// A list of callbacks for modifying requests which are generated before sending over
	// the network.
	RequestEditors []RequestEditorFn
}

Client which conforms to the OpenAPI3 specification for this service.

func NewClient

func NewClient(server string, opts ...ClientOption) (*Client, error)

Creates a new Client, with reasonable defaults

func (*Client) BootstrappingInfoRequest

func (c *Client) BootstrappingInfoRequest(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

type ClientInterface

type ClientInterface interface {
	// BootstrappingInfoRequest request
	BootstrappingInfoRequest(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
}

The interface specification for the client above.

type ClientOption

type ClientOption func(*Client) error

ClientOption allows setting custom parameters during construction

func WithBaseURL

func WithBaseURL(baseURL string) ClientOption

WithBaseURL overrides the baseURL.

func WithHTTPClient

func WithHTTPClient(doer HttpRequestDoer) ClientOption

WithHTTPClient allows overriding the default Doer, which is automatically created using http.Client. This is useful for tests.

func WithRequestEditorFn

func WithRequestEditorFn(fn RequestEditorFn) ClientOption

WithRequestEditorFn allows setting up a callback function, which will be called right before sending the request. This can be used to mutate the request.

type ClientWithResponses

type ClientWithResponses struct {
	ClientInterface
}

ClientWithResponses builds on ClientInterface to offer response payloads

func NewClientWithResponses

func NewClientWithResponses(server string, opts ...ClientOption) (*ClientWithResponses, error)

NewClientWithResponses creates a new ClientWithResponses, which wraps Client with return type handling

func (*ClientWithResponses) BootstrappingInfoRequestWithResponse

func (c *ClientWithResponses) BootstrappingInfoRequestWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*BootstrappingInfoRequestResponse, error)

BootstrappingInfoRequestWithResponse request returning *BootstrappingInfoRequestResponse

type ClientWithResponsesInterface

type ClientWithResponsesInterface interface {
	// BootstrappingInfoRequestWithResponse request
	BootstrappingInfoRequestWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*BootstrappingInfoRequestResponse, error)
}

ClientWithResponsesInterface is the interface specification for the client with responses above.

type GinServerOptions

type GinServerOptions struct {
	BaseURL      string
	Middlewares  []MiddlewareFunc
	ErrorHandler func(*gin.Context, error, int)
}

GinServerOptions provides options for the Gin server.

type HttpRequestDoer

type HttpRequestDoer interface {
	Do(req *http.Request) (*http.Response, error)
}

Doer performs HTTP requests.

The standard http.Client implements this interface.

type MiddlewareFunc

type MiddlewareFunc func(c *gin.Context)

type RequestEditorFn

type RequestEditorFn func(ctx context.Context, req *http.Request) error

RequestEditorFn is the function signature for the RequestEditor callback function

type ServerInterface

type ServerInterface interface {
	// Bootstrapping Info Request
	// (GET /bootstrapping)
	BootstrappingInfoRequest(c *gin.Context)
}

ServerInterface represents all server handlers.

func NewStrictHandler

func NewStrictHandler(ssi StrictServerInterface, middlewares []StrictMiddlewareFunc) ServerInterface

type ServerInterfaceWrapper

type ServerInterfaceWrapper struct {
	Handler            ServerInterface
	HandlerMiddlewares []MiddlewareFunc
	ErrorHandler       func(*gin.Context, error, int)
}

ServerInterfaceWrapper converts contexts to parameters.

func (*ServerInterfaceWrapper) BootstrappingInfoRequest

func (siw *ServerInterfaceWrapper) BootstrappingInfoRequest(c *gin.Context)

BootstrappingInfoRequest operation middleware

type Status

type Status string

Status Overal status of the NRF

const (
	NONOPERATIVE Status = "NON_OPERATIVE"
	OPERATIVE    Status = "OPERATIVE"
)

Defines values for Status.

type StrictHandlerFunc

type StrictHandlerFunc = strictgin.StrictGinHandlerFunc

type StrictMiddlewareFunc

type StrictMiddlewareFunc = strictgin.StrictGinMiddlewareFunc

type StrictServerInterface

type StrictServerInterface interface {
	// Bootstrapping Info Request
	// (GET /bootstrapping)
	BootstrappingInfoRequest(ctx context.Context, request BootstrappingInfoRequestRequestObject) (BootstrappingInfoRequestResponseObject, error)
}

StrictServerInterface represents all server handlers.

Jump to

Keyboard shortcuts

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