handle

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Nov 13, 2024 License: MIT Imports: 11 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 handle API

func (*Client) Handle

func (a *Client) Handle(params *HandleParams, opts ...ClientOption) (*HandleOK, error)

Handle - Handle is responsible for producing the input message into the corresponded Kafka Topic

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 {
	Handle(params *HandleParams, opts ...ClientOption) (*HandleOK, 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 handle API client.

type HandleForbidden

type HandleForbidden struct {

	/* Trace-ID: submit to support if resolving an issue
	 */
	XCSTRACEID string

	/* Request limit per minute.
	 */
	XRateLimitLimit int64

	/* The number of requests remaining for the sliding one minute window.
	 */
	XRateLimitRemaining int64

	Payload *models.MsaReplyMetaOnly
}

HandleForbidden describes a response with status code 403, with default header values.

Forbidden

func NewHandleForbidden

func NewHandleForbidden() *HandleForbidden

NewHandleForbidden creates a HandleForbidden with default headers values

func (*HandleForbidden) Code

func (o *HandleForbidden) Code() int

Code gets the status code for the handle forbidden response

func (*HandleForbidden) Error

func (o *HandleForbidden) Error() string

func (*HandleForbidden) GetPayload

func (o *HandleForbidden) GetPayload() *models.MsaReplyMetaOnly

func (*HandleForbidden) IsClientError

func (o *HandleForbidden) IsClientError() bool

IsClientError returns true when this handle forbidden response has a 4xx status code

func (*HandleForbidden) IsCode

func (o *HandleForbidden) IsCode(code int) bool

IsCode returns true when this handle forbidden response a status code equal to that given

func (*HandleForbidden) IsRedirect

func (o *HandleForbidden) IsRedirect() bool

IsRedirect returns true when this handle forbidden response has a 3xx status code

func (*HandleForbidden) IsServerError

func (o *HandleForbidden) IsServerError() bool

IsServerError returns true when this handle forbidden response has a 5xx status code

func (*HandleForbidden) IsSuccess

func (o *HandleForbidden) IsSuccess() bool

IsSuccess returns true when this handle forbidden response has a 2xx status code

func (*HandleForbidden) String

func (o *HandleForbidden) String() string

type HandleOK

type HandleOK struct {

	/* Trace-ID: submit to support if resolving an issue
	 */
	XCSTRACEID string

	/* Request limit per minute.
	 */
	XRateLimitLimit int64

	/* The number of requests remaining for the sliding one minute window.
	 */
	XRateLimitRemaining int64

	Payload map[string]string
}

HandleOK describes a response with status code 200, with default header values.

OK

func NewHandleOK

func NewHandleOK() *HandleOK

NewHandleOK creates a HandleOK with default headers values

func (*HandleOK) Code

func (o *HandleOK) Code() int

Code gets the status code for the handle o k response

func (*HandleOK) Error

func (o *HandleOK) Error() string

func (*HandleOK) GetPayload

func (o *HandleOK) GetPayload() map[string]string

func (*HandleOK) IsClientError

func (o *HandleOK) IsClientError() bool

IsClientError returns true when this handle o k response has a 4xx status code

func (*HandleOK) IsCode

func (o *HandleOK) IsCode(code int) bool

IsCode returns true when this handle o k response a status code equal to that given

func (*HandleOK) IsRedirect

func (o *HandleOK) IsRedirect() bool

IsRedirect returns true when this handle o k response has a 3xx status code

func (*HandleOK) IsServerError

func (o *HandleOK) IsServerError() bool

IsServerError returns true when this handle o k response has a 5xx status code

func (*HandleOK) IsSuccess

func (o *HandleOK) IsSuccess() bool

IsSuccess returns true when this handle o k response has a 2xx status code

func (*HandleOK) String

func (o *HandleOK) String() string

type HandleParams

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

HandleParams contains all the parameters to send to the API endpoint

for the handle operation.

Typically these are written to a http.Request.

func NewHandleParams

func NewHandleParams() *HandleParams

NewHandleParams creates a new HandleParams 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 NewHandleParamsWithContext

func NewHandleParamsWithContext(ctx context.Context) *HandleParams

NewHandleParamsWithContext creates a new HandleParams object with the ability to set a context for a request.

func NewHandleParamsWithHTTPClient

func NewHandleParamsWithHTTPClient(client *http.Client) *HandleParams

NewHandleParamsWithHTTPClient creates a new HandleParams object with the ability to set a custom HTTPClient for a request.

func NewHandleParamsWithTimeout

func NewHandleParamsWithTimeout(timeout time.Duration) *HandleParams

NewHandleParamsWithTimeout creates a new HandleParams object with the ability to set a timeout on a request.

func (*HandleParams) SetContext

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

SetContext adds the context to the handle params

func (*HandleParams) SetDefaults

func (o *HandleParams) SetDefaults()

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

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

func (*HandleParams) SetHTTPClient

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

SetHTTPClient adds the HTTPClient to the handle params

func (*HandleParams) SetTimeout

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

SetTimeout adds the timeout to the handle params

func (*HandleParams) WithContext

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

WithContext adds the context to the handle params

func (*HandleParams) WithDefaults

func (o *HandleParams) WithDefaults() *HandleParams

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

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

func (*HandleParams) WithHTTPClient

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

WithHTTPClient adds the HTTPClient to the handle params

func (*HandleParams) WithTimeout

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

WithTimeout adds the timeout to the handle params

func (*HandleParams) WriteToRequest

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

WriteToRequest writes these params to a swagger request

type HandleReader

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

HandleReader is a Reader for the Handle structure.

func (*HandleReader) ReadResponse

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

ReadResponse reads a server response into the received o.

type HandleTooManyRequests

type HandleTooManyRequests struct {

	/* Trace-ID: submit to support if resolving an issue
	 */
	XCSTRACEID string

	/* Request limit per minute.
	 */
	XRateLimitLimit int64

	/* The number of requests remaining for the sliding one minute window.
	 */
	XRateLimitRemaining int64

	/* Too many requests, retry after this time (as milliseconds since epoch)
	 */
	XRateLimitRetryAfter int64

	Payload *models.MsaReplyMetaOnly
}

HandleTooManyRequests describes a response with status code 429, with default header values.

Too Many Requests

func NewHandleTooManyRequests

func NewHandleTooManyRequests() *HandleTooManyRequests

NewHandleTooManyRequests creates a HandleTooManyRequests with default headers values

func (*HandleTooManyRequests) Code

func (o *HandleTooManyRequests) Code() int

Code gets the status code for the handle too many requests response

func (*HandleTooManyRequests) Error

func (o *HandleTooManyRequests) Error() string

func (*HandleTooManyRequests) GetPayload

func (*HandleTooManyRequests) IsClientError

func (o *HandleTooManyRequests) IsClientError() bool

IsClientError returns true when this handle too many requests response has a 4xx status code

func (*HandleTooManyRequests) IsCode

func (o *HandleTooManyRequests) IsCode(code int) bool

IsCode returns true when this handle too many requests response a status code equal to that given

func (*HandleTooManyRequests) IsRedirect

func (o *HandleTooManyRequests) IsRedirect() bool

IsRedirect returns true when this handle too many requests response has a 3xx status code

func (*HandleTooManyRequests) IsServerError

func (o *HandleTooManyRequests) IsServerError() bool

IsServerError returns true when this handle too many requests response has a 5xx status code

func (*HandleTooManyRequests) IsSuccess

func (o *HandleTooManyRequests) IsSuccess() bool

IsSuccess returns true when this handle too many requests response has a 2xx status code

func (*HandleTooManyRequests) String

func (o *HandleTooManyRequests) String() string

Jump to

Keyboard shortcuts

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