Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ClientImpl ¶
type ClientImpl struct {
// contains filtered or unexported fields
}
func NewClientImpl ¶
func NewClientImpl(client *http.Client) *ClientImpl
func (*ClientImpl) GetCrate ¶
func (c *ClientImpl) GetCrate(ctx context.Context, crate string) (*CratePayload, error)
func (*ClientImpl) GetLatestVersion ¶
func (*ClientImpl) ListVersions ¶
type CratePayload ¶
type CratePayload struct {
Crate *Crate `json:"crate"`
}
type MockClient ¶
type MockClient struct { Versions []string Err error CratePayload *CratePayload }
func (*MockClient) GetCrate ¶
func (m *MockClient) GetCrate(ctx context.Context, crate string) (*CratePayload, error)
func (*MockClient) GetLatestVersion ¶
func (*MockClient) ListVersions ¶
type Payload ¶
type Payload struct {
Versions []*PayloadVersion `json:"versions"`
}
type PayloadVersion ¶
type PayloadVersion struct {
Num string `json:"num"`
}
Click to show internal directories.
Click to hide internal directories.