statistics

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Sep 11, 2023 License: MPL-2.0 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 statistics API

func (*Client) SetTransport

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

SetTransport changes the transport on the client

func (*Client) StorageUsageSeriesHTTPPost

func (a *Client) StorageUsageSeriesHTTPPost(params *StorageUsageSeriesHTTPPostParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*StorageUsageSeriesHTTPPostOK, error)

StorageUsageSeriesHTTPPost gets storage usage statistics

Returns up to 1 year of storage statistics in a series format filtered by location, storage, and bucket.

type ClientOption

type ClientOption func(*runtime.ClientOperation)

ClientOption is the option for Client methods

type ClientService

type ClientService interface {
	StorageUsageSeriesHTTPPost(params *StorageUsageSeriesHTTPPostParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*StorageUsageSeriesHTTPPostOK, 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 statistics API client.

type StorageUsageSeriesHTTPPostBadRequest

type StorageUsageSeriesHTTPPostBadRequest struct {
	Payload *models.ErrResponse
}

StorageUsageSeriesHTTPPostBadRequest describes a response with status code 400, with default header values.

ErrResponse

func NewStorageUsageSeriesHTTPPostBadRequest

func NewStorageUsageSeriesHTTPPostBadRequest() *StorageUsageSeriesHTTPPostBadRequest

NewStorageUsageSeriesHTTPPostBadRequest creates a StorageUsageSeriesHTTPPostBadRequest with default headers values

func (*StorageUsageSeriesHTTPPostBadRequest) Code added in v0.2.0

Code gets the status code for the storage usage series Http post bad request response

func (*StorageUsageSeriesHTTPPostBadRequest) Error

func (*StorageUsageSeriesHTTPPostBadRequest) GetPayload

func (*StorageUsageSeriesHTTPPostBadRequest) IsClientError

func (o *StorageUsageSeriesHTTPPostBadRequest) IsClientError() bool

IsClientError returns true when this storage usage series Http post bad request response has a 4xx status code

func (*StorageUsageSeriesHTTPPostBadRequest) IsCode

IsCode returns true when this storage usage series Http post bad request response a status code equal to that given

func (*StorageUsageSeriesHTTPPostBadRequest) IsRedirect

IsRedirect returns true when this storage usage series Http post bad request response has a 3xx status code

func (*StorageUsageSeriesHTTPPostBadRequest) IsServerError

func (o *StorageUsageSeriesHTTPPostBadRequest) IsServerError() bool

IsServerError returns true when this storage usage series Http post bad request response has a 5xx status code

func (*StorageUsageSeriesHTTPPostBadRequest) IsSuccess

IsSuccess returns true when this storage usage series Http post bad request response has a 2xx status code

func (*StorageUsageSeriesHTTPPostBadRequest) String

type StorageUsageSeriesHTTPPostBody

type StorageUsageSeriesHTTPPostBody struct {

	// Specify the starting point of the required period (YYYY-MM-DD format)
	// Example: 2023-01-15
	From string `json:"from,omitempty"`

	// Set the time intervals for grouping the data.
	// Valid time units are "s", "m", "h"
	// Example: 6h
	Granularity string `json:"granularity,omitempty"`

	// Specify the storage locations for grouping the data
	// Example: ["s-dt2"]
	Locations []string `json:"locations"`

	// Specify the storage names for grouping the data
	// Example: ["4554-test-storage"]
	Storages []string `json:"storages"`

	// Specify the end of the required period (YYYY-MM-DD format)
	// Example: 2023-04-03
	To string `json:"to,omitempty"`

	// Decide whether to convert the response time format from the UNIX timestamp (1673809200) to RFC3339 (2023-01-15T19:00:00Z).<br>
	// Choose one of the values:<ul>
	// <li><b>true</b> — to convert the time to RFC3339 format;</li>
	// <li><b>false</b> — to leave the time in the UNIX timestamp format</li>
	// </ul>
	TsString bool `json:"ts_string,omitempty"`
}

StorageUsageSeriesHTTPPostBody storage usage series HTTP post body swagger:model StorageUsageSeriesHTTPPostBody

func (*StorageUsageSeriesHTTPPostBody) ContextValidate

func (o *StorageUsageSeriesHTTPPostBody) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this storage usage series HTTP post body based on context it is used

func (*StorageUsageSeriesHTTPPostBody) MarshalBinary

func (o *StorageUsageSeriesHTTPPostBody) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*StorageUsageSeriesHTTPPostBody) UnmarshalBinary

func (o *StorageUsageSeriesHTTPPostBody) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*StorageUsageSeriesHTTPPostBody) Validate

func (o *StorageUsageSeriesHTTPPostBody) Validate(formats strfmt.Registry) error

Validate validates this storage usage series HTTP post body

type StorageUsageSeriesHTTPPostOK

type StorageUsageSeriesHTTPPostOK struct {
	Payload *models.StorageUsageSeriesEndpointRes
}

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

StorageUsageSeriesEndpointRes

func NewStorageUsageSeriesHTTPPostOK

func NewStorageUsageSeriesHTTPPostOK() *StorageUsageSeriesHTTPPostOK

NewStorageUsageSeriesHTTPPostOK creates a StorageUsageSeriesHTTPPostOK with default headers values

func (*StorageUsageSeriesHTTPPostOK) Code added in v0.2.0

Code gets the status code for the storage usage series Http post o k response

func (*StorageUsageSeriesHTTPPostOK) Error

func (*StorageUsageSeriesHTTPPostOK) GetPayload

func (*StorageUsageSeriesHTTPPostOK) IsClientError

func (o *StorageUsageSeriesHTTPPostOK) IsClientError() bool

IsClientError returns true when this storage usage series Http post o k response has a 4xx status code

func (*StorageUsageSeriesHTTPPostOK) IsCode

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

IsCode returns true when this storage usage series Http post o k response a status code equal to that given

func (*StorageUsageSeriesHTTPPostOK) IsRedirect

func (o *StorageUsageSeriesHTTPPostOK) IsRedirect() bool

IsRedirect returns true when this storage usage series Http post o k response has a 3xx status code

func (*StorageUsageSeriesHTTPPostOK) IsServerError

func (o *StorageUsageSeriesHTTPPostOK) IsServerError() bool

IsServerError returns true when this storage usage series Http post o k response has a 5xx status code

func (*StorageUsageSeriesHTTPPostOK) IsSuccess

func (o *StorageUsageSeriesHTTPPostOK) IsSuccess() bool

IsSuccess returns true when this storage usage series Http post o k response has a 2xx status code

func (*StorageUsageSeriesHTTPPostOK) String

type StorageUsageSeriesHTTPPostParams

type StorageUsageSeriesHTTPPostParams struct {

	// Body.
	Body StorageUsageSeriesHTTPPostBody

	Context    context.Context
	HTTPClient *http.Client
	// contains filtered or unexported fields
}

StorageUsageSeriesHTTPPostParams contains all the parameters to send to the API endpoint

for the storage usage series Http post operation.

Typically these are written to a http.Request.

func NewStorageUsageSeriesHTTPPostParams

func NewStorageUsageSeriesHTTPPostParams() *StorageUsageSeriesHTTPPostParams

NewStorageUsageSeriesHTTPPostParams creates a new StorageUsageSeriesHTTPPostParams 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 NewStorageUsageSeriesHTTPPostParamsWithContext

func NewStorageUsageSeriesHTTPPostParamsWithContext(ctx context.Context) *StorageUsageSeriesHTTPPostParams

NewStorageUsageSeriesHTTPPostParamsWithContext creates a new StorageUsageSeriesHTTPPostParams object with the ability to set a context for a request.

func NewStorageUsageSeriesHTTPPostParamsWithHTTPClient

func NewStorageUsageSeriesHTTPPostParamsWithHTTPClient(client *http.Client) *StorageUsageSeriesHTTPPostParams

NewStorageUsageSeriesHTTPPostParamsWithHTTPClient creates a new StorageUsageSeriesHTTPPostParams object with the ability to set a custom HTTPClient for a request.

func NewStorageUsageSeriesHTTPPostParamsWithTimeout

func NewStorageUsageSeriesHTTPPostParamsWithTimeout(timeout time.Duration) *StorageUsageSeriesHTTPPostParams

NewStorageUsageSeriesHTTPPostParamsWithTimeout creates a new StorageUsageSeriesHTTPPostParams object with the ability to set a timeout on a request.

func (*StorageUsageSeriesHTTPPostParams) SetBody

SetBody adds the body to the storage usage series Http post params

func (*StorageUsageSeriesHTTPPostParams) SetContext

SetContext adds the context to the storage usage series Http post params

func (*StorageUsageSeriesHTTPPostParams) SetDefaults

func (o *StorageUsageSeriesHTTPPostParams) SetDefaults()

SetDefaults hydrates default values in the storage usage series Http post params (not the query body).

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

func (*StorageUsageSeriesHTTPPostParams) SetHTTPClient

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

SetHTTPClient adds the HTTPClient to the storage usage series Http post params

func (*StorageUsageSeriesHTTPPostParams) SetTimeout

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

SetTimeout adds the timeout to the storage usage series Http post params

func (*StorageUsageSeriesHTTPPostParams) WithBody

WithBody adds the body to the storage usage series Http post params

func (*StorageUsageSeriesHTTPPostParams) WithContext

WithContext adds the context to the storage usage series Http post params

func (*StorageUsageSeriesHTTPPostParams) WithDefaults

WithDefaults hydrates default values in the storage usage series Http post params (not the query body).

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

func (*StorageUsageSeriesHTTPPostParams) WithHTTPClient

WithHTTPClient adds the HTTPClient to the storage usage series Http post params

func (*StorageUsageSeriesHTTPPostParams) WithTimeout

WithTimeout adds the timeout to the storage usage series Http post params

func (*StorageUsageSeriesHTTPPostParams) WriteToRequest

WriteToRequest writes these params to a swagger request

type StorageUsageSeriesHTTPPostReader

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

StorageUsageSeriesHTTPPostReader is a Reader for the StorageUsageSeriesHTTPPost structure.

func (*StorageUsageSeriesHTTPPostReader) ReadResponse

func (o *StorageUsageSeriesHTTPPostReader) 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