Documentation
¶
Index ¶
- func GetRates(prepareData models.PrepareShiftRequest, selectedCoin hestia.Coin, ...) (amountTo decimal.Decimal, payment models.PaymentInfo, ...)
- func GetServiceConfig(data models.PrepareShiftRequest, hestiaService services.HestiaService, ...) (selectedCoin hestia.Coin, err error)
- type TycheController
- func (s *TycheController) AddShiftToMap(uid string, shiftPrepare models.PrepareShiftInfo)
- func (s *TycheController) Balance(_ string, _ []byte, params models.Params) (interface{}, error)
- func (s *TycheController) GetShiftFromMap(key string) (models.PrepareShiftInfo, error)
- func (s *TycheController) OpenBalance(_ string, _ []byte, params models.Params) (interface{}, error)
- func (s *TycheController) OpenPrepare(uid string, payload []byte, _ models.Params) (interface{}, error)
- func (s *TycheController) OpenStatus(_ string, _ []byte, _ models.Params) (interface{}, error)
- func (s *TycheController) OpenStore(uid string, payload []byte, _ models.Params) (interface{}, error)
- func (s *TycheController) Prepare(uid string, payload []byte, _ models.Params) (interface{}, error)
- func (s *TycheController) PrepareV11(_ string, payload []byte, _ models.Params) (interface{}, error)
- func (s *TycheController) RemoveShiftFromMap(uid string)
- func (s *TycheController) Status(string, []byte, models.Params) (interface{}, error)
- func (s *TycheController) Store(uid string, payload []byte, _ models.Params) (interface{}, error)
- func (s *TycheController) StoreV11(uid string, payload []byte, _ models.Params) (interface{}, error)
- type TycheControllerV2
- func (s *TycheControllerV2) AddShiftToMap(uid string, shiftPrepare models.PrepareShiftInfoV2)
- func (s *TycheControllerV2) BalanceV2(_ string, _ []byte, params models.Params) (interface{}, error)
- func (s *TycheControllerV2) GetRatesV2(prepareData models.PrepareShiftRequest, selectedCoin hestia.Coin) (amountTo decimal.Decimal, paymentData models.PaymentInfoV2, err error)
- func (s *TycheControllerV2) GetShiftFromMap(key string) (models.PrepareShiftInfoV2, error)
- func (s *TycheControllerV2) PrepareV2(uid string, payload []byte, _ models.Params) (interface{}, error)
- func (s *TycheControllerV2) RemoveShiftFromMap(uid string)
- func (s *TycheControllerV2) StatusV2(uid string, _ []byte, _ models.Params) (interface{}, error)
- func (s *TycheControllerV2) StoreV2(uid string, payload []byte, _ models.Params) (interface{}, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetRates ¶
func GetRates(prepareData models.PrepareShiftRequest, selectedCoin hestia.Coin, obolService obol.ObolService, plutusService services.PlutusService) (amountTo decimal.Decimal, payment models.PaymentInfo, feePayment models.PaymentInfo, err error)
func GetServiceConfig ¶
func GetServiceConfig(data models.PrepareShiftRequest, hestiaService services.HestiaService, dev bool) (selectedCoin hestia.Coin, err error)
Utility Functions
Types ¶
type TycheController ¶
type TycheController struct { PrepareShifts map[string]models.PrepareShiftInfo TxsAvailable bool Hestia services.HestiaService Plutus services.PlutusService Obol obol.ObolService DevMode bool // contains filtered or unexported fields }
func (*TycheController) AddShiftToMap ¶
func (s *TycheController) AddShiftToMap(uid string, shiftPrepare models.PrepareShiftInfo)
func (*TycheController) GetShiftFromMap ¶
func (s *TycheController) GetShiftFromMap(key string) (models.PrepareShiftInfo, error)
func (*TycheController) OpenBalance ¶
func (*TycheController) OpenPrepare ¶
func (*TycheController) OpenStatus ¶
func (*TycheController) PrepareV11 ¶
func (s *TycheController) PrepareV11(_ string, payload []byte, _ models.Params) (interface{}, error)
Tyche v2 API. Most important change is the use of ShiftId instead of UID as Mempool Map Key.
func (*TycheController) RemoveShiftFromMap ¶
func (s *TycheController) RemoveShiftFromMap(uid string)
type TycheControllerV2 ¶
type TycheControllerV2 struct { PrepareShifts map[string]models.PrepareShiftInfoV2 TxsAvailable bool Hestia services.HestiaService Plutus services.PlutusService Obol obol.ObolService Adrestia services.AdrestiaService DevMode bool ExFactory *exchanges.ExchangeFactory // contains filtered or unexported fields }
func (*TycheControllerV2) AddShiftToMap ¶
func (s *TycheControllerV2) AddShiftToMap(uid string, shiftPrepare models.PrepareShiftInfoV2)
func (*TycheControllerV2) GetRatesV2 ¶
func (s *TycheControllerV2) GetRatesV2(prepareData models.PrepareShiftRequest, selectedCoin hestia.Coin) (amountTo decimal.Decimal, paymentData models.PaymentInfoV2, err error)
func (*TycheControllerV2) GetShiftFromMap ¶
func (s *TycheControllerV2) GetShiftFromMap(key string) (models.PrepareShiftInfoV2, error)
func (*TycheControllerV2) PrepareV2 ¶
func (s *TycheControllerV2) PrepareV2(uid string, payload []byte, _ models.Params) (interface{}, error)
Tyche v2 API. Most important change is the use of ShiftId instead of UID as Mempool Map Key.
func (*TycheControllerV2) RemoveShiftFromMap ¶
func (s *TycheControllerV2) RemoveShiftFromMap(uid string)
utils
Click to show internal directories.
Click to hide internal directories.