28 lines
553 B
Go
28 lines
553 B
Go
|
|
package server
|
||
|
|
|
||
|
|
import "time"
|
||
|
|
|
||
|
|
type Amount struct {
|
||
|
|
Asset string `json:"asset"`
|
||
|
|
Amount int64 `json:"amount"`
|
||
|
|
}
|
||
|
|
|
||
|
|
type Window struct {
|
||
|
|
Start *time.Time `json:"start,omitempty"`
|
||
|
|
End *time.Time `json:"end,omitempty"`
|
||
|
|
}
|
||
|
|
|
||
|
|
type RegenRule struct {
|
||
|
|
Every int64 `json:"every"`
|
||
|
|
Max int64 `json:"max"`
|
||
|
|
}
|
||
|
|
|
||
|
|
type RegenState struct {
|
||
|
|
Value int64 `json:"value"`
|
||
|
|
Max int64 `json:"max"`
|
||
|
|
Every int64 `json:"every"`
|
||
|
|
NextAt *time.Time `json:"nextAt,omitempty"`
|
||
|
|
FullAt *time.Time `json:"fullAt,omitempty"`
|
||
|
|
At time.Time `json:"at"`
|
||
|
|
}
|