110 lines
2.7 KiB
Go
110 lines
2.7 KiB
Go
// Code generated by go-swagger; DO NOT EDIT.
|
|
|
|
package faction_warfare
|
|
|
|
// This file was generated by the swagger tool.
|
|
// Editing this file might prove futile when you re-run the swagger generate command
|
|
|
|
import (
|
|
"github.com/go-openapi/runtime"
|
|
|
|
strfmt "github.com/go-openapi/strfmt"
|
|
)
|
|
|
|
// New creates a new faction warfare API client.
|
|
func New(transport runtime.ClientTransport, formats strfmt.Registry) *Client {
|
|
return &Client{transport: transport, formats: formats}
|
|
}
|
|
|
|
/*
|
|
Client for faction warfare API
|
|
*/
|
|
type Client struct {
|
|
transport runtime.ClientTransport
|
|
formats strfmt.Registry
|
|
}
|
|
|
|
/*
|
|
GetFwStats ans overview of statistics about factions involved in faction warfare
|
|
|
|
Statistical overviews of factions involved in faction warfare
|
|
|
|
---
|
|
Alternate route: `/v1/fw/stats/`
|
|
|
|
Alternate route: `/legacy/fw/stats/`
|
|
|
|
Alternate route: `/dev/fw/stats/`
|
|
|
|
---
|
|
This route expires daily at 11:05
|
|
*/
|
|
func (a *Client) GetFwStats(params *GetFwStatsParams) (*GetFwStatsOK, error) {
|
|
// TODO: Validate the params before sending
|
|
if params == nil {
|
|
params = NewGetFwStatsParams()
|
|
}
|
|
|
|
result, err := a.transport.Submit(&runtime.ClientOperation{
|
|
ID: "get_fw_stats",
|
|
Method: "GET",
|
|
PathPattern: "/fw/stats/",
|
|
ProducesMediaTypes: []string{"application/json"},
|
|
ConsumesMediaTypes: []string{""},
|
|
Schemes: []string{"https"},
|
|
Params: params,
|
|
Reader: &GetFwStatsReader{formats: a.formats},
|
|
Context: params.Context,
|
|
Client: params.HTTPClient,
|
|
})
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return result.(*GetFwStatsOK), nil
|
|
|
|
}
|
|
|
|
/*
|
|
GetFwWars data about which n p c factions are at war
|
|
|
|
Data about which NPC factions are at war
|
|
|
|
---
|
|
Alternate route: `/v1/fw/wars/`
|
|
|
|
Alternate route: `/legacy/fw/wars/`
|
|
|
|
Alternate route: `/dev/fw/wars/`
|
|
|
|
---
|
|
This route expires daily at 11:05
|
|
*/
|
|
func (a *Client) GetFwWars(params *GetFwWarsParams) (*GetFwWarsOK, error) {
|
|
// TODO: Validate the params before sending
|
|
if params == nil {
|
|
params = NewGetFwWarsParams()
|
|
}
|
|
|
|
result, err := a.transport.Submit(&runtime.ClientOperation{
|
|
ID: "get_fw_wars",
|
|
Method: "GET",
|
|
PathPattern: "/fw/wars/",
|
|
ProducesMediaTypes: []string{"application/json"},
|
|
ConsumesMediaTypes: []string{""},
|
|
Schemes: []string{"https"},
|
|
Params: params,
|
|
Reader: &GetFwWarsReader{formats: a.formats},
|
|
Context: params.Context,
|
|
Client: params.HTTPClient,
|
|
})
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return result.(*GetFwWarsOK), nil
|
|
|
|
}
|
|
|
|
// SetTransport changes the transport on the client
|
|
func (a *Client) SetTransport(transport runtime.ClientTransport) {
|
|
a.transport = transport
|
|
}
|