provider

package
v0.9.1 Latest Latest
Warning

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

Go to latest
Published: Dec 16, 2023 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewTrackerFittingsProvider

func NewTrackerFittingsProvider(client *http.Client) *trackerFittingsProvider

Types

type AvailabilityResult

type AvailabilityResult struct {
	Available bool
	Err       error
}

type Fit

type Fit struct {
	Success bool `json:"success"`
	Item    Item `json:"item"`
}

type Fits

type Fits struct {
	Success bool   `json:"success"`
	Items   []Item `json:"items"`
	Count   int64  `json:"count"`
}

type FittingsProvider

type FittingsProvider interface {
	Available(ctx context.Context) AvailabilityResult
	SourceName() string
	AvailableFittingIDs(ctx context.Context) []string
	GetFittingDetails(ctx context.Context, ID string) (*Fit, error)
}

type Item

type Item struct {
	ID   int64  `json:"id"`
	Name string `json:"name"`
	Ship Ship   `json:"ship"`
	EFT  string `json:"eft"`
	FFH  string `json:"flexibleFitHash"`
}

type Ship

type Ship struct {
	ID   int64  `json:"id"`
	Name string `json:"name"`
	Size string `json:"size"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL