service

package
v0.4.2 Latest Latest
Warning

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

Go to latest
Published: Nov 4, 2022 License: MulanPSL-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client for service API

func (*Client) Readyz

func (a *Client) Readyz(params *ReadyzParams, opts ...ClientOption) (*ReadyzOK, error)

Readyz Ready status

func (*Client) SetTransport

func (a *Client) SetTransport(transport runtime.ClientTransport)

SetTransport changes the transport on the client

type ClientOption

type ClientOption func(*runtime.ClientOperation)

ClientOption is the option for Client methods

type ClientService

type ClientService interface {
	Readyz(params *ReadyzParams, opts ...ClientOption) (*ReadyzOK, error)

	SetTransport(transport runtime.ClientTransport)
}

ClientService is the interface for Client methods

func New

func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService

New creates a new service API client.

type ReadyzOK

type ReadyzOK struct {
	Payload models.ReadyStatus
}
ReadyzOK describes a response with status code 200, with default header values.

Ready status

func NewReadyzOK

func NewReadyzOK() *ReadyzOK

NewReadyzOK creates a ReadyzOK with default headers values

func (*ReadyzOK) Error

func (o *ReadyzOK) Error() string

func (*ReadyzOK) GetPayload

func (o *ReadyzOK) GetPayload() models.ReadyStatus

type ReadyzParams

type ReadyzParams struct {
	Context    context.Context
	HTTPClient *http.Client
	// contains filtered or unexported fields
}

ReadyzParams contains all the parameters to send to the API endpoint

for the readyz operation.

Typically these are written to a http.Request.

func NewReadyzParams

func NewReadyzParams() *ReadyzParams

NewReadyzParams creates a new ReadyzParams object, with the default timeout for this client.

Default values are not hydrated, since defaults are normally applied by the API server side.

To enforce default values in parameter, use SetDefaults or WithDefaults.

func NewReadyzParamsWithContext

func NewReadyzParamsWithContext(ctx context.Context) *ReadyzParams

NewReadyzParamsWithContext creates a new ReadyzParams object with the ability to set a context for a request.

func NewReadyzParamsWithHTTPClient

func NewReadyzParamsWithHTTPClient(client *http.Client) *ReadyzParams

NewReadyzParamsWithHTTPClient creates a new ReadyzParams object with the ability to set a custom HTTPClient for a request.

func NewReadyzParamsWithTimeout

func NewReadyzParamsWithTimeout(timeout time.Duration) *ReadyzParams

NewReadyzParamsWithTimeout creates a new ReadyzParams object with the ability to set a timeout on a request.

func (*ReadyzParams) SetContext

func (o *ReadyzParams) SetContext(ctx context.Context)

SetContext adds the context to the readyz params

func (*ReadyzParams) SetDefaults

func (o *ReadyzParams) SetDefaults()

SetDefaults hydrates default values in the readyz params (not the query body).

All values with no default are reset to their zero value.

func (*ReadyzParams) SetHTTPClient

func (o *ReadyzParams) SetHTTPClient(client *http.Client)

SetHTTPClient adds the HTTPClient to the readyz params

func (*ReadyzParams) SetTimeout

func (o *ReadyzParams) SetTimeout(timeout time.Duration)

SetTimeout adds the timeout to the readyz params

func (*ReadyzParams) WithContext

func (o *ReadyzParams) WithContext(ctx context.Context) *ReadyzParams

WithContext adds the context to the readyz params

func (*ReadyzParams) WithDefaults

func (o *ReadyzParams) WithDefaults() *ReadyzParams

WithDefaults hydrates default values in the readyz params (not the query body).

All values with no default are reset to their zero value.

func (*ReadyzParams) WithHTTPClient

func (o *ReadyzParams) WithHTTPClient(client *http.Client) *ReadyzParams

WithHTTPClient adds the HTTPClient to the readyz params

func (*ReadyzParams) WithTimeout

func (o *ReadyzParams) WithTimeout(timeout time.Duration) *ReadyzParams

WithTimeout adds the timeout to the readyz params

func (*ReadyzParams) WriteToRequest

func (o *ReadyzParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error

WriteToRequest writes these params to a swagger request

type ReadyzReader

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

ReadyzReader is a Reader for the Readyz structure.

func (*ReadyzReader) ReadResponse

func (o *ReadyzReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)

ReadResponse reads a server response into the received o.

Jump to

Keyboard shortcuts

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