Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // Debug mode. Default: false. Debug bool )
Functions ¶
Types ¶
type Branch ¶
type Branch struct { Bank string `json:"bank"` Subway string `json:"subway"` Currency string `json:"currency"` Buy float64 `json:"buy"` Sell float64 `json:"sell"` Updated time.Time `json:"updated"` }
Bank or branch.
type Branches ¶
type Branches struct { Currency Currency `json:"currency"` City City `json:"city"` Items []Branch `json:"items"` }
Banks or branches.
type ByBuySorter ¶
type ByBuySorter []Branch
ByBuySorter implements sort.Interface based on the Buy field.
func (ByBuySorter) Len ¶
func (b ByBuySorter) Len() int
Len, Swap and Less implement sort.Interface for ByBuySorter.
func (ByBuySorter) Less ¶
func (b ByBuySorter) Less(i, j int) bool
func (ByBuySorter) Swap ¶
func (b ByBuySorter) Swap(i, j int)
type BySellSorter ¶
type BySellSorter []Branch
BySellSorter implements sort.Interface based on the Sell field.
func (BySellSorter) Len ¶
func (s BySellSorter) Len() int
Len, Swap and Less implement sort.Interface for BySellSorter.
func (BySellSorter) Less ¶
func (s BySellSorter) Less(i, j int) bool
func (BySellSorter) Swap ¶
func (s BySellSorter) Swap(i, j int)
type City ¶
type City string
City type.
const ( // City. Barnaul City = "barnaul" Voronezh City = "voronezh" Volgograd City = "volgograd" Vladivostok City = "vladivostok" Ekaterinburg City = "ekaterinburg" Irkutsk City = "irkutsk" Izhevsk City = "izhevsk" Kazan City = "kazan~" Krasnodar City = "krasnodar" Krasnoyarsk City = "krasnoyarsk" Kaliningrad City = "kaliningrad" Kirov City = "kirov" Kemerovo City = "kemerovo" Moscow City = "moskva" Novosibirsk City = "novosibirsk" NizhnyNovgorod City = "nizhniy_novgorod" Omsk City = "omsk" Orenburg City = "orenburg" Perm City = "perm~" RostovOnDon City = "rostov-na-donu" SaintPetersburg City = "sankt-peterburg" Samara City = "samara" Saratov City = "saratov" Sochi City = "krasnodarskiy_kray/sochi" Tyumen City = "tyumen~" Tolyatti City = "samarskaya_oblast~/tol~yatti" Tomsk City = "tomsk" Ufa City = "ufa" Khabarovsk City = "habarovsk" Chelyabinsk City = "chelyabinsk" )
Click to show internal directories.
Click to hide internal directories.