Documentation
¶
Index ¶
- type Client
- func (a *Client) GetConsensus(params *GetConsensusParams, authInfo runtime.ClientAuthInfoWriter) (*GetConsensusOK, error)
- func (a *Client) PostConsensusValidateTransactionset(params *PostConsensusValidateTransactionsetParams, ...) (*PostConsensusValidateTransactionsetNoContent, error)
- func (a *Client) SetTransport(transport runtime.ClientTransport)
- type ClientService
- type GetConsensusDefault
- type GetConsensusOK
- type GetConsensusOKBody
- type GetConsensusParams
- func (o *GetConsensusParams) SetContext(ctx context.Context)
- func (o *GetConsensusParams) SetDefaults()
- func (o *GetConsensusParams) SetHTTPClient(client *http.Client)
- func (o *GetConsensusParams) SetTimeout(timeout time.Duration)
- func (o *GetConsensusParams) WithContext(ctx context.Context) *GetConsensusParams
- func (o *GetConsensusParams) WithDefaults() *GetConsensusParams
- func (o *GetConsensusParams) WithHTTPClient(client *http.Client) *GetConsensusParams
- func (o *GetConsensusParams) WithTimeout(timeout time.Duration) *GetConsensusParams
- func (o *GetConsensusParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
- type GetConsensusReader
- type PostConsensusValidateTransactionsetDefault
- type PostConsensusValidateTransactionsetNoContent
- type PostConsensusValidateTransactionsetParams
- func NewPostConsensusValidateTransactionsetParams() *PostConsensusValidateTransactionsetParams
- func NewPostConsensusValidateTransactionsetParamsWithContext(ctx context.Context) *PostConsensusValidateTransactionsetParams
- func NewPostConsensusValidateTransactionsetParamsWithHTTPClient(client *http.Client) *PostConsensusValidateTransactionsetParams
- func NewPostConsensusValidateTransactionsetParamsWithTimeout(timeout time.Duration) *PostConsensusValidateTransactionsetParams
- func (o *PostConsensusValidateTransactionsetParams) SetBody(body models.TransactionSet)
- func (o *PostConsensusValidateTransactionsetParams) SetContext(ctx context.Context)
- func (o *PostConsensusValidateTransactionsetParams) SetDefaults()
- func (o *PostConsensusValidateTransactionsetParams) SetHTTPClient(client *http.Client)
- func (o *PostConsensusValidateTransactionsetParams) SetTimeout(timeout time.Duration)
- func (o *PostConsensusValidateTransactionsetParams) WithBody(body models.TransactionSet) *PostConsensusValidateTransactionsetParams
- func (o *PostConsensusValidateTransactionsetParams) WithContext(ctx context.Context) *PostConsensusValidateTransactionsetParams
- func (o *PostConsensusValidateTransactionsetParams) WithDefaults() *PostConsensusValidateTransactionsetParams
- func (o *PostConsensusValidateTransactionsetParams) WithHTTPClient(client *http.Client) *PostConsensusValidateTransactionsetParams
- func (o *PostConsensusValidateTransactionsetParams) WithTimeout(timeout time.Duration) *PostConsensusValidateTransactionsetParams
- func (o *PostConsensusValidateTransactionsetParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
- type PostConsensusValidateTransactionsetReader
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 consensus API
func (*Client) GetConsensus ¶
func (a *Client) GetConsensus(params *GetConsensusParams, authInfo runtime.ClientAuthInfoWriter) (*GetConsensusOK, error)
GetConsensus returns information about the consensus set, such as the current block height.
func (*Client) PostConsensusValidateTransactionset ¶
func (a *Client) PostConsensusValidateTransactionset(params *PostConsensusValidateTransactionsetParams, authInfo runtime.ClientAuthInfoWriter) (*PostConsensusValidateTransactionsetNoContent, error)
PostConsensusValidateTransactionset validates a set of transactions using the current utxo set.
func (*Client) SetTransport ¶
func (a *Client) SetTransport(transport runtime.ClientTransport)
SetTransport changes the transport on the client
type ClientService ¶ added in v0.5.9
type ClientService interface { GetConsensus(params *GetConsensusParams, authInfo runtime.ClientAuthInfoWriter) (*GetConsensusOK, error) PostConsensusValidateTransactionset(params *PostConsensusValidateTransactionsetParams, authInfo runtime.ClientAuthInfoWriter) (*PostConsensusValidateTransactionsetNoContent, 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 consensus API client.
type GetConsensusDefault ¶
type GetConsensusDefault struct { Payload *models.StandardError // contains filtered or unexported fields }
GetConsensusDefault describes a response with status code -1, with default header values.
Error Response
func NewGetConsensusDefault ¶
func NewGetConsensusDefault(code int) *GetConsensusDefault
NewGetConsensusDefault creates a GetConsensusDefault with default headers values
func (*GetConsensusDefault) Code ¶
func (o *GetConsensusDefault) Code() int
Code gets the status code for the get consensus default response
func (*GetConsensusDefault) Error ¶
func (o *GetConsensusDefault) Error() string
func (*GetConsensusDefault) GetPayload ¶ added in v0.5.4
func (o *GetConsensusDefault) GetPayload() *models.StandardError
type GetConsensusOK ¶
type GetConsensusOK struct {
Payload *GetConsensusOKBody
}
GetConsensusOK describes a response with status code 200, with default header values.
Successful Response
func NewGetConsensusOK ¶
func NewGetConsensusOK() *GetConsensusOK
NewGetConsensusOK creates a GetConsensusOK with default headers values
func (*GetConsensusOK) Error ¶
func (o *GetConsensusOK) Error() string
func (*GetConsensusOK) GetPayload ¶ added in v0.5.4
func (o *GetConsensusOK) GetPayload() *GetConsensusOKBody
type GetConsensusOKBody ¶
type GetConsensusOKBody struct { // currentblock Currentblock string `json:"currentblock,omitempty"` // Number of blocks preceding the current block. // Example: 62248 Height int64 `json:"height,omitempty"` // True if the consensus set is synced with the network, i.e. it has downloaded the entire blockchain. Synced bool `json:"synced,omitempty"` }
GetConsensusOKBody get consensus o k body swagger:model GetConsensusOKBody
func (*GetConsensusOKBody) ContextValidate ¶ added in v0.5.9
ContextValidate validates this get consensus o k body based on context it is used
func (*GetConsensusOKBody) MarshalBinary ¶
func (o *GetConsensusOKBody) MarshalBinary() ([]byte, error)
MarshalBinary interface implementation
func (*GetConsensusOKBody) UnmarshalBinary ¶
func (o *GetConsensusOKBody) UnmarshalBinary(b []byte) error
UnmarshalBinary interface implementation
type GetConsensusParams ¶
type GetConsensusParams struct { Context context.Context HTTPClient *http.Client // contains filtered or unexported fields }
GetConsensusParams contains all the parameters to send to the API endpoint
for the get consensus operation. Typically these are written to a http.Request.
func NewGetConsensusParams ¶
func NewGetConsensusParams() *GetConsensusParams
NewGetConsensusParams creates a new GetConsensusParams 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 NewGetConsensusParamsWithContext ¶
func NewGetConsensusParamsWithContext(ctx context.Context) *GetConsensusParams
NewGetConsensusParamsWithContext creates a new GetConsensusParams object with the ability to set a context for a request.
func NewGetConsensusParamsWithHTTPClient ¶
func NewGetConsensusParamsWithHTTPClient(client *http.Client) *GetConsensusParams
NewGetConsensusParamsWithHTTPClient creates a new GetConsensusParams object with the ability to set a custom HTTPClient for a request.
func NewGetConsensusParamsWithTimeout ¶
func NewGetConsensusParamsWithTimeout(timeout time.Duration) *GetConsensusParams
NewGetConsensusParamsWithTimeout creates a new GetConsensusParams object with the ability to set a timeout on a request.
func (*GetConsensusParams) SetContext ¶
func (o *GetConsensusParams) SetContext(ctx context.Context)
SetContext adds the context to the get consensus params
func (*GetConsensusParams) SetDefaults ¶ added in v0.5.9
func (o *GetConsensusParams) SetDefaults()
SetDefaults hydrates default values in the get consensus params (not the query body).
All values with no default are reset to their zero value.
func (*GetConsensusParams) SetHTTPClient ¶
func (o *GetConsensusParams) SetHTTPClient(client *http.Client)
SetHTTPClient adds the HTTPClient to the get consensus params
func (*GetConsensusParams) SetTimeout ¶
func (o *GetConsensusParams) SetTimeout(timeout time.Duration)
SetTimeout adds the timeout to the get consensus params
func (*GetConsensusParams) WithContext ¶
func (o *GetConsensusParams) WithContext(ctx context.Context) *GetConsensusParams
WithContext adds the context to the get consensus params
func (*GetConsensusParams) WithDefaults ¶ added in v0.5.9
func (o *GetConsensusParams) WithDefaults() *GetConsensusParams
WithDefaults hydrates default values in the get consensus params (not the query body).
All values with no default are reset to their zero value.
func (*GetConsensusParams) WithHTTPClient ¶
func (o *GetConsensusParams) WithHTTPClient(client *http.Client) *GetConsensusParams
WithHTTPClient adds the HTTPClient to the get consensus params
func (*GetConsensusParams) WithTimeout ¶
func (o *GetConsensusParams) WithTimeout(timeout time.Duration) *GetConsensusParams
WithTimeout adds the timeout to the get consensus params
func (*GetConsensusParams) WriteToRequest ¶
func (o *GetConsensusParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
WriteToRequest writes these params to a swagger request
type GetConsensusReader ¶
type GetConsensusReader struct {
// contains filtered or unexported fields
}
GetConsensusReader is a Reader for the GetConsensus structure.
func (*GetConsensusReader) ReadResponse ¶
func (o *GetConsensusReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
ReadResponse reads a server response into the received o.
type PostConsensusValidateTransactionsetDefault ¶
type PostConsensusValidateTransactionsetDefault struct { Payload *models.StandardError // contains filtered or unexported fields }
PostConsensusValidateTransactionsetDefault describes a response with status code -1, with default header values.
Error Response
func NewPostConsensusValidateTransactionsetDefault ¶
func NewPostConsensusValidateTransactionsetDefault(code int) *PostConsensusValidateTransactionsetDefault
NewPostConsensusValidateTransactionsetDefault creates a PostConsensusValidateTransactionsetDefault with default headers values
func (*PostConsensusValidateTransactionsetDefault) Code ¶
func (o *PostConsensusValidateTransactionsetDefault) Code() int
Code gets the status code for the post consensus validate transactionset default response
func (*PostConsensusValidateTransactionsetDefault) Error ¶
func (o *PostConsensusValidateTransactionsetDefault) Error() string
func (*PostConsensusValidateTransactionsetDefault) GetPayload ¶ added in v0.5.4
func (o *PostConsensusValidateTransactionsetDefault) GetPayload() *models.StandardError
type PostConsensusValidateTransactionsetNoContent ¶
type PostConsensusValidateTransactionsetNoContent struct { }
PostConsensusValidateTransactionsetNoContent describes a response with status code 204, with default header values.
Successful Response
func NewPostConsensusValidateTransactionsetNoContent ¶
func NewPostConsensusValidateTransactionsetNoContent() *PostConsensusValidateTransactionsetNoContent
NewPostConsensusValidateTransactionsetNoContent creates a PostConsensusValidateTransactionsetNoContent with default headers values
func (*PostConsensusValidateTransactionsetNoContent) Error ¶
func (o *PostConsensusValidateTransactionsetNoContent) Error() string
type PostConsensusValidateTransactionsetParams ¶
type PostConsensusValidateTransactionsetParams struct { // Body. Body models.TransactionSet Context context.Context HTTPClient *http.Client // contains filtered or unexported fields }
PostConsensusValidateTransactionsetParams contains all the parameters to send to the API endpoint
for the post consensus validate transactionset operation. Typically these are written to a http.Request.
func NewPostConsensusValidateTransactionsetParams ¶
func NewPostConsensusValidateTransactionsetParams() *PostConsensusValidateTransactionsetParams
NewPostConsensusValidateTransactionsetParams creates a new PostConsensusValidateTransactionsetParams 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 NewPostConsensusValidateTransactionsetParamsWithContext ¶
func NewPostConsensusValidateTransactionsetParamsWithContext(ctx context.Context) *PostConsensusValidateTransactionsetParams
NewPostConsensusValidateTransactionsetParamsWithContext creates a new PostConsensusValidateTransactionsetParams object with the ability to set a context for a request.
func NewPostConsensusValidateTransactionsetParamsWithHTTPClient ¶
func NewPostConsensusValidateTransactionsetParamsWithHTTPClient(client *http.Client) *PostConsensusValidateTransactionsetParams
NewPostConsensusValidateTransactionsetParamsWithHTTPClient creates a new PostConsensusValidateTransactionsetParams object with the ability to set a custom HTTPClient for a request.
func NewPostConsensusValidateTransactionsetParamsWithTimeout ¶
func NewPostConsensusValidateTransactionsetParamsWithTimeout(timeout time.Duration) *PostConsensusValidateTransactionsetParams
NewPostConsensusValidateTransactionsetParamsWithTimeout creates a new PostConsensusValidateTransactionsetParams object with the ability to set a timeout on a request.
func (*PostConsensusValidateTransactionsetParams) SetBody ¶
func (o *PostConsensusValidateTransactionsetParams) SetBody(body models.TransactionSet)
SetBody adds the body to the post consensus validate transactionset params
func (*PostConsensusValidateTransactionsetParams) SetContext ¶
func (o *PostConsensusValidateTransactionsetParams) SetContext(ctx context.Context)
SetContext adds the context to the post consensus validate transactionset params
func (*PostConsensusValidateTransactionsetParams) SetDefaults ¶ added in v0.5.9
func (o *PostConsensusValidateTransactionsetParams) SetDefaults()
SetDefaults hydrates default values in the post consensus validate transactionset params (not the query body).
All values with no default are reset to their zero value.
func (*PostConsensusValidateTransactionsetParams) SetHTTPClient ¶
func (o *PostConsensusValidateTransactionsetParams) SetHTTPClient(client *http.Client)
SetHTTPClient adds the HTTPClient to the post consensus validate transactionset params
func (*PostConsensusValidateTransactionsetParams) SetTimeout ¶
func (o *PostConsensusValidateTransactionsetParams) SetTimeout(timeout time.Duration)
SetTimeout adds the timeout to the post consensus validate transactionset params
func (*PostConsensusValidateTransactionsetParams) WithBody ¶
func (o *PostConsensusValidateTransactionsetParams) WithBody(body models.TransactionSet) *PostConsensusValidateTransactionsetParams
WithBody adds the body to the post consensus validate transactionset params
func (*PostConsensusValidateTransactionsetParams) WithContext ¶
func (o *PostConsensusValidateTransactionsetParams) WithContext(ctx context.Context) *PostConsensusValidateTransactionsetParams
WithContext adds the context to the post consensus validate transactionset params
func (*PostConsensusValidateTransactionsetParams) WithDefaults ¶ added in v0.5.9
func (o *PostConsensusValidateTransactionsetParams) WithDefaults() *PostConsensusValidateTransactionsetParams
WithDefaults hydrates default values in the post consensus validate transactionset params (not the query body).
All values with no default are reset to their zero value.
func (*PostConsensusValidateTransactionsetParams) WithHTTPClient ¶
func (o *PostConsensusValidateTransactionsetParams) WithHTTPClient(client *http.Client) *PostConsensusValidateTransactionsetParams
WithHTTPClient adds the HTTPClient to the post consensus validate transactionset params
func (*PostConsensusValidateTransactionsetParams) WithTimeout ¶
func (o *PostConsensusValidateTransactionsetParams) WithTimeout(timeout time.Duration) *PostConsensusValidateTransactionsetParams
WithTimeout adds the timeout to the post consensus validate transactionset params
func (*PostConsensusValidateTransactionsetParams) WriteToRequest ¶
func (o *PostConsensusValidateTransactionsetParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
WriteToRequest writes these params to a swagger request
type PostConsensusValidateTransactionsetReader ¶
type PostConsensusValidateTransactionsetReader struct {
// contains filtered or unexported fields
}
PostConsensusValidateTransactionsetReader is a Reader for the PostConsensusValidateTransactionset structure.
func (*PostConsensusValidateTransactionsetReader) ReadResponse ¶
func (o *PostConsensusValidateTransactionsetReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
ReadResponse reads a server response into the received o.