Documentation
¶
Index ¶
- type Client
- type ClientOption
- type ClientService
- type GetUsageForbidden
- func (o *GetUsageForbidden) Code() int
- func (o *GetUsageForbidden) Error() string
- func (o *GetUsageForbidden) GetPayload() *models.Error
- func (o *GetUsageForbidden) IsClientError() bool
- func (o *GetUsageForbidden) IsCode(code int) bool
- func (o *GetUsageForbidden) IsRedirect() bool
- func (o *GetUsageForbidden) IsServerError() bool
- func (o *GetUsageForbidden) IsSuccess() bool
- func (o *GetUsageForbidden) String() string
- type GetUsageNotFound
- func (o *GetUsageNotFound) Code() int
- func (o *GetUsageNotFound) Error() string
- func (o *GetUsageNotFound) GetPayload() *models.Error
- func (o *GetUsageNotFound) IsClientError() bool
- func (o *GetUsageNotFound) IsCode(code int) bool
- func (o *GetUsageNotFound) IsRedirect() bool
- func (o *GetUsageNotFound) IsServerError() bool
- func (o *GetUsageNotFound) IsSuccess() bool
- func (o *GetUsageNotFound) String() string
- type GetUsageOK
- func (o *GetUsageOK) Code() int
- func (o *GetUsageOK) Error() string
- func (o *GetUsageOK) GetPayload() *models.Usage
- func (o *GetUsageOK) IsClientError() bool
- func (o *GetUsageOK) IsCode(code int) bool
- func (o *GetUsageOK) IsRedirect() bool
- func (o *GetUsageOK) IsServerError() bool
- func (o *GetUsageOK) IsSuccess() bool
- func (o *GetUsageOK) String() string
- type GetUsageParams
- func (o *GetUsageParams) SetContext(ctx context.Context)
- func (o *GetUsageParams) SetDefaults()
- func (o *GetUsageParams) SetHTTPClient(client *http.Client)
- func (o *GetUsageParams) SetTimeout(timeout time.Duration)
- func (o *GetUsageParams) WithContext(ctx context.Context) *GetUsageParams
- func (o *GetUsageParams) WithDefaults() *GetUsageParams
- func (o *GetUsageParams) WithHTTPClient(client *http.Client) *GetUsageParams
- func (o *GetUsageParams) WithTimeout(timeout time.Duration) *GetUsageParams
- func (o *GetUsageParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
- type GetUsageReader
- type GetUsageTooManyRequests
- func (o *GetUsageTooManyRequests) Code() int
- func (o *GetUsageTooManyRequests) Error() string
- func (o *GetUsageTooManyRequests) GetPayload() *models.Error
- func (o *GetUsageTooManyRequests) IsClientError() bool
- func (o *GetUsageTooManyRequests) IsCode(code int) bool
- func (o *GetUsageTooManyRequests) IsRedirect() bool
- func (o *GetUsageTooManyRequests) IsServerError() bool
- func (o *GetUsageTooManyRequests) IsSuccess() bool
- func (o *GetUsageTooManyRequests) String() string
- type GetUsageUnauthorized
- func (o *GetUsageUnauthorized) Code() int
- func (o *GetUsageUnauthorized) Error() string
- func (o *GetUsageUnauthorized) GetPayload() *models.Error
- func (o *GetUsageUnauthorized) IsClientError() bool
- func (o *GetUsageUnauthorized) IsCode(code int) bool
- func (o *GetUsageUnauthorized) IsRedirect() bool
- func (o *GetUsageUnauthorized) IsServerError() bool
- func (o *GetUsageUnauthorized) IsSuccess() bool
- func (o *GetUsageUnauthorized) String() string
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 usage API
func (*Client) GetUsage ¶
func (a *Client) GetUsage(params *GetUsageParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetUsageOK, error)
GetUsage gets usage
Get usage.
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 may be used to customize the behavior of Client methods.
type ClientService ¶
type ClientService interface {
GetUsage(params *GetUsageParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*GetUsageOK, 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 usage API client.
func NewClientWithBasicAuth ¶
func NewClientWithBasicAuth(host, basePath, scheme, user, password string) ClientService
New creates a new usage API client with basic auth credentials. It takes the following parameters: - host: http host (github.com). - basePath: any base path for the API client ("/v1", "/v3"). - scheme: http scheme ("http", "https"). - user: user for basic authentication header. - password: password for basic authentication header.
func NewClientWithBearerToken ¶
func NewClientWithBearerToken(host, basePath, scheme, bearerToken string) ClientService
New creates a new usage API client with a bearer token for authentication. It takes the following parameters: - host: http host (github.com). - basePath: any base path for the API client ("/v1", "/v3"). - scheme: http scheme ("http", "https"). - bearerToken: bearer token for Bearer authentication header.
type GetUsageForbidden ¶
GetUsageForbidden describes a response with status code 403, with default header values.
Forbidden
func NewGetUsageForbidden ¶
func NewGetUsageForbidden() *GetUsageForbidden
NewGetUsageForbidden creates a GetUsageForbidden with default headers values
func (*GetUsageForbidden) Code ¶
func (o *GetUsageForbidden) Code() int
Code gets the status code for the get usage forbidden response
func (*GetUsageForbidden) Error ¶
func (o *GetUsageForbidden) Error() string
func (*GetUsageForbidden) GetPayload ¶
func (o *GetUsageForbidden) GetPayload() *models.Error
func (*GetUsageForbidden) IsClientError ¶
func (o *GetUsageForbidden) IsClientError() bool
IsClientError returns true when this get usage forbidden response has a 4xx status code
func (*GetUsageForbidden) IsCode ¶
func (o *GetUsageForbidden) IsCode(code int) bool
IsCode returns true when this get usage forbidden response a status code equal to that given
func (*GetUsageForbidden) IsRedirect ¶
func (o *GetUsageForbidden) IsRedirect() bool
IsRedirect returns true when this get usage forbidden response has a 3xx status code
func (*GetUsageForbidden) IsServerError ¶
func (o *GetUsageForbidden) IsServerError() bool
IsServerError returns true when this get usage forbidden response has a 5xx status code
func (*GetUsageForbidden) IsSuccess ¶
func (o *GetUsageForbidden) IsSuccess() bool
IsSuccess returns true when this get usage forbidden response has a 2xx status code
func (*GetUsageForbidden) String ¶
func (o *GetUsageForbidden) String() string
type GetUsageNotFound ¶
GetUsageNotFound describes a response with status code 404, with default header values.
Not found
func NewGetUsageNotFound ¶
func NewGetUsageNotFound() *GetUsageNotFound
NewGetUsageNotFound creates a GetUsageNotFound with default headers values
func (*GetUsageNotFound) Code ¶
func (o *GetUsageNotFound) Code() int
Code gets the status code for the get usage not found response
func (*GetUsageNotFound) Error ¶
func (o *GetUsageNotFound) Error() string
func (*GetUsageNotFound) GetPayload ¶
func (o *GetUsageNotFound) GetPayload() *models.Error
func (*GetUsageNotFound) IsClientError ¶
func (o *GetUsageNotFound) IsClientError() bool
IsClientError returns true when this get usage not found response has a 4xx status code
func (*GetUsageNotFound) IsCode ¶
func (o *GetUsageNotFound) IsCode(code int) bool
IsCode returns true when this get usage not found response a status code equal to that given
func (*GetUsageNotFound) IsRedirect ¶
func (o *GetUsageNotFound) IsRedirect() bool
IsRedirect returns true when this get usage not found response has a 3xx status code
func (*GetUsageNotFound) IsServerError ¶
func (o *GetUsageNotFound) IsServerError() bool
IsServerError returns true when this get usage not found response has a 5xx status code
func (*GetUsageNotFound) IsSuccess ¶
func (o *GetUsageNotFound) IsSuccess() bool
IsSuccess returns true when this get usage not found response has a 2xx status code
func (*GetUsageNotFound) String ¶
func (o *GetUsageNotFound) String() string
type GetUsageOK ¶
GetUsageOK describes a response with status code 200, with default header values.
Usage
func NewGetUsageOK ¶
func NewGetUsageOK() *GetUsageOK
NewGetUsageOK creates a GetUsageOK with default headers values
func (*GetUsageOK) Code ¶
func (o *GetUsageOK) Code() int
Code gets the status code for the get usage o k response
func (*GetUsageOK) Error ¶
func (o *GetUsageOK) Error() string
func (*GetUsageOK) GetPayload ¶
func (o *GetUsageOK) GetPayload() *models.Usage
func (*GetUsageOK) IsClientError ¶
func (o *GetUsageOK) IsClientError() bool
IsClientError returns true when this get usage o k response has a 4xx status code
func (*GetUsageOK) IsCode ¶
func (o *GetUsageOK) IsCode(code int) bool
IsCode returns true when this get usage o k response a status code equal to that given
func (*GetUsageOK) IsRedirect ¶
func (o *GetUsageOK) IsRedirect() bool
IsRedirect returns true when this get usage o k response has a 3xx status code
func (*GetUsageOK) IsServerError ¶
func (o *GetUsageOK) IsServerError() bool
IsServerError returns true when this get usage o k response has a 5xx status code
func (*GetUsageOK) IsSuccess ¶
func (o *GetUsageOK) IsSuccess() bool
IsSuccess returns true when this get usage o k response has a 2xx status code
func (*GetUsageOK) String ¶
func (o *GetUsageOK) String() string
type GetUsageParams ¶
type GetUsageParams struct {
Context context.Context
HTTPClient *http.Client
// contains filtered or unexported fields
}
GetUsageParams contains all the parameters to send to the API endpoint
for the get usage operation. Typically these are written to a http.Request.
func NewGetUsageParams ¶
func NewGetUsageParams() *GetUsageParams
NewGetUsageParams creates a new GetUsageParams 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 NewGetUsageParamsWithContext ¶
func NewGetUsageParamsWithContext(ctx context.Context) *GetUsageParams
NewGetUsageParamsWithContext creates a new GetUsageParams object with the ability to set a context for a request.
func NewGetUsageParamsWithHTTPClient ¶
func NewGetUsageParamsWithHTTPClient(client *http.Client) *GetUsageParams
NewGetUsageParamsWithHTTPClient creates a new GetUsageParams object with the ability to set a custom HTTPClient for a request.
func NewGetUsageParamsWithTimeout ¶
func NewGetUsageParamsWithTimeout(timeout time.Duration) *GetUsageParams
NewGetUsageParamsWithTimeout creates a new GetUsageParams object with the ability to set a timeout on a request.
func (*GetUsageParams) SetContext ¶
func (o *GetUsageParams) SetContext(ctx context.Context)
SetContext adds the context to the get usage params
func (*GetUsageParams) SetDefaults ¶
func (o *GetUsageParams) SetDefaults()
SetDefaults hydrates default values in the get usage params (not the query body).
All values with no default are reset to their zero value.
func (*GetUsageParams) SetHTTPClient ¶
func (o *GetUsageParams) SetHTTPClient(client *http.Client)
SetHTTPClient adds the HTTPClient to the get usage params
func (*GetUsageParams) SetTimeout ¶
func (o *GetUsageParams) SetTimeout(timeout time.Duration)
SetTimeout adds the timeout to the get usage params
func (*GetUsageParams) WithContext ¶
func (o *GetUsageParams) WithContext(ctx context.Context) *GetUsageParams
WithContext adds the context to the get usage params
func (*GetUsageParams) WithDefaults ¶
func (o *GetUsageParams) WithDefaults() *GetUsageParams
WithDefaults hydrates default values in the get usage params (not the query body).
All values with no default are reset to their zero value.
func (*GetUsageParams) WithHTTPClient ¶
func (o *GetUsageParams) WithHTTPClient(client *http.Client) *GetUsageParams
WithHTTPClient adds the HTTPClient to the get usage params
func (*GetUsageParams) WithTimeout ¶
func (o *GetUsageParams) WithTimeout(timeout time.Duration) *GetUsageParams
WithTimeout adds the timeout to the get usage params
func (*GetUsageParams) WriteToRequest ¶
func (o *GetUsageParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
WriteToRequest writes these params to a swagger request
type GetUsageReader ¶
type GetUsageReader struct {
// contains filtered or unexported fields
}
GetUsageReader is a Reader for the GetUsage structure.
func (*GetUsageReader) ReadResponse ¶
func (o *GetUsageReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
ReadResponse reads a server response into the received o.
type GetUsageTooManyRequests ¶
GetUsageTooManyRequests describes a response with status code 429, with default header values.
Too many requests
func NewGetUsageTooManyRequests ¶
func NewGetUsageTooManyRequests() *GetUsageTooManyRequests
NewGetUsageTooManyRequests creates a GetUsageTooManyRequests with default headers values
func (*GetUsageTooManyRequests) Code ¶
func (o *GetUsageTooManyRequests) Code() int
Code gets the status code for the get usage too many requests response
func (*GetUsageTooManyRequests) Error ¶
func (o *GetUsageTooManyRequests) Error() string
func (*GetUsageTooManyRequests) GetPayload ¶
func (o *GetUsageTooManyRequests) GetPayload() *models.Error
func (*GetUsageTooManyRequests) IsClientError ¶
func (o *GetUsageTooManyRequests) IsClientError() bool
IsClientError returns true when this get usage too many requests response has a 4xx status code
func (*GetUsageTooManyRequests) IsCode ¶
func (o *GetUsageTooManyRequests) IsCode(code int) bool
IsCode returns true when this get usage too many requests response a status code equal to that given
func (*GetUsageTooManyRequests) IsRedirect ¶
func (o *GetUsageTooManyRequests) IsRedirect() bool
IsRedirect returns true when this get usage too many requests response has a 3xx status code
func (*GetUsageTooManyRequests) IsServerError ¶
func (o *GetUsageTooManyRequests) IsServerError() bool
IsServerError returns true when this get usage too many requests response has a 5xx status code
func (*GetUsageTooManyRequests) IsSuccess ¶
func (o *GetUsageTooManyRequests) IsSuccess() bool
IsSuccess returns true when this get usage too many requests response has a 2xx status code
func (*GetUsageTooManyRequests) String ¶
func (o *GetUsageTooManyRequests) String() string
type GetUsageUnauthorized ¶
type GetUsageUnauthorized struct {
}
GetUsageUnauthorized describes a response with status code 401, with default header values.
Unauthorized
func NewGetUsageUnauthorized ¶
func NewGetUsageUnauthorized() *GetUsageUnauthorized
NewGetUsageUnauthorized creates a GetUsageUnauthorized with default headers values
func (*GetUsageUnauthorized) Code ¶
func (o *GetUsageUnauthorized) Code() int
Code gets the status code for the get usage unauthorized response
func (*GetUsageUnauthorized) Error ¶
func (o *GetUsageUnauthorized) Error() string
func (*GetUsageUnauthorized) GetPayload ¶
func (o *GetUsageUnauthorized) GetPayload() *models.Error
func (*GetUsageUnauthorized) IsClientError ¶
func (o *GetUsageUnauthorized) IsClientError() bool
IsClientError returns true when this get usage unauthorized response has a 4xx status code
func (*GetUsageUnauthorized) IsCode ¶
func (o *GetUsageUnauthorized) IsCode(code int) bool
IsCode returns true when this get usage unauthorized response a status code equal to that given
func (*GetUsageUnauthorized) IsRedirect ¶
func (o *GetUsageUnauthorized) IsRedirect() bool
IsRedirect returns true when this get usage unauthorized response has a 3xx status code
func (*GetUsageUnauthorized) IsServerError ¶
func (o *GetUsageUnauthorized) IsServerError() bool
IsServerError returns true when this get usage unauthorized response has a 5xx status code
func (*GetUsageUnauthorized) IsSuccess ¶
func (o *GetUsageUnauthorized) IsSuccess() bool
IsSuccess returns true when this get usage unauthorized response has a 2xx status code
func (*GetUsageUnauthorized) String ¶
func (o *GetUsageUnauthorized) String() string