Documentation
¶
Overview ¶
deprecate
Index ¶
- Constants
- func GetPow(v uint8, r types.Bytes32, s types.Bytes32, powNonce uint64) *big.Int
- func HandleInputOrder(input eventemitter.EventData) (orderHash string, err error)
- func HandleOrder(input eventemitter.EventData) error
- func Initialize(filterOptions *GatewayFiltersOptions, options *GateWayOptions, ...)
- func StartMotanService(options motan.MotanServerOptions, accountManager accountmanager.AccountManager, ...)
- func Uint64ToByteArray(src uint64) []byte
- type AccountJson
- type AskBid
- type BaseFilter
- type CancelOrderQuery
- type CommonTokenRequest
- type CutoffFilter
- type CutoffRequest
- type Depth
- type DepthElement
- type DepthQuery
- type EstimatedAllocatedAllowanceQuery
- type EthForwarder
- func (e *EthForwarder) Call(ethCall *types.CallArg, blockNumber string) (result string, err error)
- func (e *EthForwarder) GetBalance(address, blockNumber string) (result string, err error)
- func (e *EthForwarder) GetTransactionCount(address, blockNumber string) (result string, err error)
- func (e *EthForwarder) SendRawTransaction(tx string) (result string, err error)
- type FillQuery
- type Filter
- type GateWayOptions
- type Gateway
- type GatewayFiltersOptions
- type InvokeInfo
- type JsonrpcOptions
- type JsonrpcService
- type JsonrpcServiceImpl
- type LatestFill
- type LatestOrderQuery
- type LoginInfo
- type MotanService
- type NotifyCirculrBody
- type OrderBook
- type OrderBookElement
- type OrderJsonResult
- type OrderQuery
- type OrderTransfer
- type OrderTransferQuery
- type P2PRingRequest
- type PageResult
- type Portfolio
- type PowFilter
- type PriceQuote
- type PriceQuoteQuery
- type RawOrderJsonResult
- type RingMinedDetail
- type RingMinedInfo
- type RingMinedQuery
- type Server
- type SignFilter
- type SignInfo
- type SignedLoginInfo
- type SimpleKey
- type SingleDelegateAddress
- type SingleMarket
- type SingleOwner
- type SingleToken
- type SocketClient
- type SocketIOJsonResp
- type SocketIOService
- type SocketIOServiceImpl
- type SocketMsgHandler
- type SocketNode
- type TempStore
- type Ticket
- type TicketQuery
- type Token
- type TokenFilter
- type TokenPrice
- type TransactionQuery
- type TrendQuery
- type TxNotify
- type WalletServiceImpl
- func (w *WalletServiceImpl) ApplyTicket(ticket Ticket) (result string, err error)
- func (w *WalletServiceImpl) FlexCancelOrder(req CancelOrderQuery) (rst string, err error)
- func (w *WalletServiceImpl) GetBalance(balanceQuery CommonTokenRequest) (res AccountJson, err error)
- func (w *WalletServiceImpl) GetContracts() (contracts map[string][]string, err error)
- func (w *WalletServiceImpl) GetCutoff(query CutoffRequest) (result int64, err error)
- func (w *WalletServiceImpl) GetDepth(query DepthQuery) (res Depth, err error)
- func (w *WalletServiceImpl) GetEstimateGasPrice() (result string, err error)
- func (w *WalletServiceImpl) GetEstimatedAllocatedAllowance(query EstimatedAllocatedAllowanceQuery) (frozenAmount string, err error)
- func (w *WalletServiceImpl) GetFills(query FillQuery) (dao.PageResult, error)
- func (w *WalletServiceImpl) GetFrozenLRCFee(query SingleOwner) (frozenAmount string, err error)
- func (w *WalletServiceImpl) GetGlobalMarketTicker(req SingleToken) (tickers map[string][]market.GlobalMarketTicker, err error)
- func (w *WalletServiceImpl) GetGlobalTicker(req SingleToken) (ticker map[string]market.GlobalTicker, err error)
- func (w *WalletServiceImpl) GetGlobalTrend(req SingleToken) (trend map[string][]market.GlobalTrend, err error)
- func (w *WalletServiceImpl) GetLatestFills(query FillQuery) ([]LatestFill, error)
- func (w *WalletServiceImpl) GetLatestMarketOrders(query LatestOrderQuery) (res []OrderJsonResult, err error)
- func (w *WalletServiceImpl) GetLatestOrders(query LatestOrderQuery) (res []OrderJsonResult, err error)
- func (w *WalletServiceImpl) GetLatestP2POrders(query LatestOrderQuery) (res []OrderJsonResult, err error)
- func (w *WalletServiceImpl) GetLatestTransactions(query TransactionQuery) ([]txtyp.TransactionJsonResult, error)
- func (w *WalletServiceImpl) GetLooprSupportedMarket() (markets []string, err error)
- func (w *WalletServiceImpl) GetLooprSupportedTokens() (markets []types.Token, err error)
- func (w *WalletServiceImpl) GetNonce(owner SingleOwner) (n int64, err error)
- func (w *WalletServiceImpl) GetOldVersionWethBalance(owner SingleOwner) (res string, err error)
- func (w *WalletServiceImpl) GetOrderByHash(query OrderQuery) (order OrderJsonResult, err error)
- func (w *WalletServiceImpl) GetOrderTransfer(req OrderTransferQuery) (ot OrderTransfer, err error)
- func (w *WalletServiceImpl) GetOrders(query *OrderQuery) (res PageResult, err error)
- func (w *WalletServiceImpl) GetPendingRawTxByHash(query TransactionQuery) (result TxNotify, err error)
- func (w *WalletServiceImpl) GetPendingTransactions(query SingleOwner) (result []txtyp.TransactionJsonResult, err error)
- func (w *WalletServiceImpl) GetPortfolio(query SingleOwner) (res []Portfolio, err error)
- func (w *WalletServiceImpl) GetPriceQuote(query PriceQuoteQuery) (result PriceQuote, err error)
- func (w *WalletServiceImpl) GetRingMined(query RingMinedQuery) (res dao.PageResult, err error)
- func (w *WalletServiceImpl) GetRingMinedDetail(query RingMinedQuery) (res RingMinedDetail, err error)
- func (w *WalletServiceImpl) GetSupportedMarket() (markets []string, err error)
- func (w *WalletServiceImpl) GetSupportedTokens() (markets []types.Token, err error)
- func (w *WalletServiceImpl) GetTempStore(req SimpleKey) (ts string, err error)
- func (w *WalletServiceImpl) GetTicker() (res []market.Ticker, err error)
- func (w *WalletServiceImpl) GetTickers(mkt SingleMarket) (result map[string]market.Ticker, err error)
- func (w *WalletServiceImpl) GetTransactions(query TransactionQuery) (PageResult, error)
- func (w *WalletServiceImpl) GetTransactionsByHash(query TransactionQuery) (result []txtyp.TransactionJsonResult, err error)
- func (w *WalletServiceImpl) GetTrend(query TrendQuery) (res []market.Trend, err error)
- func (w *WalletServiceImpl) GetUnmergedOrderBook(query DepthQuery) (res OrderBook, err error)
- func (w *WalletServiceImpl) NotifyCirculr(req NotifyCirculrBody) (owner string, err error)
- func (w *WalletServiceImpl) NotifyScanLogin(req SignedLoginInfo) (rst string, err error)
- func (w *WalletServiceImpl) NotifyTransactionSubmitted(txNotify TxNotify) (result string, err error)
- func (w *WalletServiceImpl) QueryTicket(query TicketQuery) (ticket dao.TicketReceiver, err error)
- func (w *WalletServiceImpl) SetOrderTransfer(req OrderTransfer) (hash string, err error)
- func (w *WalletServiceImpl) SetTempStore(req TempStore) (hash string, err error)
- func (w *WalletServiceImpl) SubmitOrder(order *types.OrderJsonRequest) (res string, err error)
- func (w *WalletServiceImpl) SubmitRingForP2P(p2pRing P2PRingRequest) (res string, err error)
- func (w *WalletServiceImpl) TestPing(input int) (resp []byte, err error)
- func (w *WalletServiceImpl) TicketCount() (int, error)
- func (w *WalletServiceImpl) UnlockWallet(owner SingleOwner) (result string, err error)
- func (w *WalletServiceImpl) UpdateOrderTransfer(req OrderTransfer) (hash string, err error)
- type WebsocketOptions
- type WebsocketRequest
- type WebsocketService
- type WebsocketServiceImpl
Constants ¶
View Source
const ( EventPostfixReq = "_req" EventPostfixRes = "_res" EventPostfixEnd = "_end" DefaultCronSpec3Second = "0/3 * * * * *" DefaultCronSpec5Second = "0/5 * * * * *" DefaultCronSpec10Second = "0/10 * * * * *" DefaultCronSpec5Minute = "0 */5 * * * *" DefaultCronSpec10Hour = "0 0 */10 * * *" DefaultCronSpec30Day = "0 0 0 */30 * *" )
View Source
const DefaultCapCurrency = "CNY"
View Source
const Kafka_Topic_SocketIO_Notify_Circulr = "Kafka_Topic_SocketIO_Notify_Circulr"
View Source
const Kafka_Topic_SocketIO_Order_Transfer = "Kafka_Topic_SocketIO_Order_Transfer"
View Source
const Kafka_Topic_SocketIO_Scan_Login = "Kafka_Topic_SocketIO_Scan_Login"
View Source
const OT_REDIS_PRE_KEY = "otrpk_"
View Source
const OT_STATUS_ACCEPT = "accept"
View Source
const OT_STATUS_INIT = "init"
View Source
const OT_STATUS_REJECT = "reject"
View Source
const P2P_50001 = "50001"
View Source
const P2P_50002 = "50002"
View Source
const P2P_50003 = "50003"
View Source
const P2P_50004 = "50004"
View Source
const P2P_50005 = "50005"
View Source
const P2P_50006 = "50006"
View Source
const P2P_50007 = "50007"
View Source
const P2P_50008 = "50008"
View Source
const PendingTxPreKey = "PENDING_TX_"
View Source
const SL_REDIS_PRE_KEY = "slrpk_"
View Source
const SYS_10001 = "10001"
View Source
const TS_REDIS_PRE_KEY = "tsrpk_"
Variables ¶
This section is empty.
Functions ¶
func HandleInputOrder ¶
func HandleInputOrder(input eventemitter.EventData) (orderHash string, err error)
func HandleOrder ¶
func HandleOrder(input eventemitter.EventData) error
func Initialize ¶
func Initialize(filterOptions *GatewayFiltersOptions, options *GateWayOptions, om viewer.OrderViewer, marketCap marketcap.MarketCapProvider, am accountmanager.AccountManager)
func StartMotanService ¶
func StartMotanService(options motan.MotanServerOptions, accountManager accountmanager.AccountManager, orderViewer viewer.OrderViewer)
func Uint64ToByteArray ¶
Types ¶
type AccountJson ¶
type BaseFilter ¶
type CancelOrderQuery ¶
type CommonTokenRequest ¶
type CutoffFilter ¶
type CutoffFilter struct {
// contains filtered or unexported fields
}
type CutoffRequest ¶
type DepthElement ¶
type DepthQuery ¶
type EthForwarder ¶
type EthForwarder struct {
}
func (*EthForwarder) GetBalance ¶
func (e *EthForwarder) GetBalance(address, blockNumber string) (result string, err error)
func (*EthForwarder) GetTransactionCount ¶
func (e *EthForwarder) GetTransactionCount(address, blockNumber string) (result string, err error)
func (*EthForwarder) SendRawTransaction ¶
func (e *EthForwarder) SendRawTransaction(tx string) (result string, err error)
type FillQuery ¶
type FillQuery struct {
DelegateAddress string `json:"delegateAddress"`
Market string `json:"market"`
Owner string `json:"owner"`
OrderHash string `json:"orderHash"`
RingHash string `json:"ringHash"`
PageIndex int `json:"pageIndex"`
PageSize int `json:"pageSize"`
Side string `json:"side"`
OrderType string `json:"orderType"`
}
type GateWayOptions ¶
type GatewayFiltersOptions ¶
type InvokeInfo ¶
type InvokeInfo struct {
MethodName string
Query interface{}
// contains filtered or unexported fields
}
type JsonrpcOptions ¶
type JsonrpcOptions struct {
Port string
}
type JsonrpcService ¶
type JsonrpcService interface {
Start(port string)
Stop()
}
type JsonrpcServiceImpl ¶
type JsonrpcServiceImpl struct {
// contains filtered or unexported fields
}
func NewJsonrpcService ¶
func NewJsonrpcService(port string, walletService *WalletServiceImpl) *JsonrpcServiceImpl
func (*JsonrpcServiceImpl) Ping ¶
func (*JsonrpcServiceImpl) Ping(val string, val2 int) (res string, err error)
func (*JsonrpcServiceImpl) Start ¶
func (j *JsonrpcServiceImpl) Start()
type LatestFill ¶
type LatestOrderQuery ¶
type MotanService ¶
type MotanService struct {
// contains filtered or unexported fields
}
func (*MotanService) GetBalanceAndAllowance ¶
func (s *MotanService) GetBalanceAndAllowance(req *motan.AccountBalanceAndAllowanceReq) *motan.AccountBalanceAndAllowanceRes
func (*MotanService) GetMinerOrders ¶
func (s *MotanService) GetMinerOrders(req *motan.MinerOrdersReq) *motan.MinerOrdersRes
type NotifyCirculrBody ¶
type OrderBook ¶
type OrderBook struct {
DelegateAddress string `json:"delegateAddress"`
Market string `json:"market"`
Buy []OrderBookElement `json:"buy"`
Sell []OrderBookElement `json:"sell"`
}
type OrderBookElement ¶
type OrderJsonResult ¶
type OrderQuery ¶
type OrderQuery struct {
Status string `json:"status"`
PageIndex int `json:"pageIndex"`
PageSize int `json:"pageSize"`
DelegateAddress string `json:"delegateAddress"`
Owner string `json:"owner"`
Market string `json:"market"`
OrderHash string `json:"orderHash"`
Side string `json:"side"`
OrderType string `json:"orderType"`
}
type OrderTransfer ¶
type OrderTransferQuery ¶
type OrderTransferQuery struct {
Hash string `json:"hash"`
}
type P2PRingRequest ¶
type PageResult ¶
type PriceQuote ¶
type PriceQuote struct {
Currency string `json:"currency"`
Tokens []TokenPrice `json:"tokens"`
}
type PriceQuoteQuery ¶
type PriceQuoteQuery struct {
Currency string `json:"currency"`
}
type RawOrderJsonResult ¶
type RawOrderJsonResult struct {
Protocol string `json:"protocol"` // 智能合约地址
DelegateAddress string `json:"delegateAddress"` // 智能合约地址
Owner string `json:"address"`
Hash string `json:"hash"`
TokenS string `json:"tokenS"` // 卖出erc20代币智能合约地址
TokenB string `json:"tokenB"` // 买入erc20代币智能合约地址
AmountS string `json:"amountS"` // 卖出erc20代币数量上限
AmountB string `json:"amountB"` // 买入erc20代币数量上限
ValidSince string `json:"validSince"`
ValidUntil string `json:"validUntil"` // 订单过期时间
//Salt string `json:"salt"`
LrcFee string `json:"lrcFee"` // 交易总费用,部分成交的费用按该次撮合实际卖出代币额与比例计算
BuyNoMoreThanAmountB bool `json:"buyNoMoreThanAmountB"`
MarginSplitPercentage string `json:"marginSplitPercentage"` // 不为0时支付给交易所的分润比例,否则视为100%
V string `json:"v"`
R string `json:"r"`
S string `json:"s"`
WalletAddress string `json:"walletAddress" gencodec:"required"`
AuthAddr string `json:"authAddr" gencodec:"required"` //
AuthPrivateKey string `json:"authPrivateKey" gencodec:"required"` //
Market string `json:"market"`
Side string `json:"side"`
CreateTime int64 `json:"createTime"`
OrderType string `json:"orderType"`
}
type RingMinedDetail ¶
type RingMinedDetail struct {
RingInfo RingMinedInfo `json:"ringInfo"`
Fills []dao.FillEvent `json:"fills"`
}
type RingMinedInfo ¶
type RingMinedInfo struct {
ID int `json:"id"`
Protocol string `json:"protocol"`
DelegateAddress string `json:"delegateAddress"`
RingIndex string `json:"ringIndex"`
RingHash string `json:"ringHash"`
TxHash string `json:"txHash"`
Miner string `json:"miner"`
FeeRecipient string `json:"feeRecipient"`
IsRinghashReserved bool `json:"isRinghashReserved"`
BlockNumber int64 `json:"blockNumber"`
TotalLrcFee string `json:"totalLrcFee"`
TotalSplitFee map[string]*big.Int `json:"totalSplitFee"`
TradeAmount int `json:"tradeAmount"`
Time int64 `json:"timestamp"`
}
type RingMinedQuery ¶
type SignFilter ¶
type SignFilter struct {
}
type SignedLoginInfo ¶
type SingleDelegateAddress ¶
type SingleDelegateAddress struct {
DelegateAddress string `json:"delegateAddress"`
}
type SingleMarket ¶
type SingleMarket struct {
Market string `json:"market"`
}
type SingleOwner ¶
type SingleOwner struct {
Owner string `json:"owner"`
}
type SingleToken ¶
type SingleToken struct {
Token string `json:"token"`
}
type SocketClient ¶
type SocketClient struct {
// contains filtered or unexported fields
}
type SocketIOJsonResp ¶
type SocketIOService ¶
type SocketIOService interface {
Start(port string)
Stop()
}
type SocketIOServiceImpl ¶
type SocketIOServiceImpl struct {
// contains filtered or unexported fields
}
func NewSocketIOService ¶
func NewSocketIOService(port string, walletService WalletServiceImpl, brokers []string) *SocketIOServiceImpl
func (*SocketIOServiceImpl) EmitNowByEventType ¶
func (so *SocketIOServiceImpl) EmitNowByEventType(bk string, v socketio.Conn, bv string)
func (*SocketIOServiceImpl) Start ¶
func (so *SocketIOServiceImpl) Start()
type SocketMsgHandler ¶
type SocketMsgHandler struct {
Data interface{}
Handler func(data interface{}) error
}
type SocketNode ¶
type SocketNode struct {
// contains filtered or unexported fields
}
type Ticket ¶
type Ticket struct {
Sign SignInfo `json:"sign"`
Ticket dao.TicketReceiver `json:"ticket"`
}
type TicketQuery ¶
type TokenFilter ¶
type TokenPrice ¶
type TransactionQuery ¶
type TrendQuery ¶
type TxNotify ¶
type TxNotify struct {
Hash string `json:"hash"`
Nonce string `json:"nonce"`
From string `json:"from"`
To string `json:"to"`
Value string `json:"value"`
GasPrice string `json:"gasPrice"`
Gas string `json:"gas"`
Input string `json:"input"`
R string `json:"r"`
S string `json:"s"`
V string `json:"v"`
}
type WalletServiceImpl ¶
type WalletServiceImpl struct {
// contains filtered or unexported fields
}
func NewWalletService ¶
func NewWalletService(trendManager market.TrendManager, orderViewer viewer.OrderViewer, accountManager accountmanager.AccountManager, capProvider marketcap.MarketCapProvider, collector market.CollectorImpl, rds *dao.RdsService, oldWethAddress string, globalMarket market.GlobalMarket) *WalletServiceImpl
func (*WalletServiceImpl) ApplyTicket ¶
func (w *WalletServiceImpl) ApplyTicket(ticket Ticket) (result string, err error)
func (*WalletServiceImpl) FlexCancelOrder ¶
func (w *WalletServiceImpl) FlexCancelOrder(req CancelOrderQuery) (rst string, err error)
func (*WalletServiceImpl) GetBalance ¶
func (w *WalletServiceImpl) GetBalance(balanceQuery CommonTokenRequest) (res AccountJson, err error)
func (*WalletServiceImpl) GetContracts ¶
func (w *WalletServiceImpl) GetContracts() (contracts map[string][]string, err error)
func (*WalletServiceImpl) GetCutoff ¶
func (w *WalletServiceImpl) GetCutoff(query CutoffRequest) (result int64, err error)
func (*WalletServiceImpl) GetDepth ¶
func (w *WalletServiceImpl) GetDepth(query DepthQuery) (res Depth, err error)
func (*WalletServiceImpl) GetEstimateGasPrice ¶
func (w *WalletServiceImpl) GetEstimateGasPrice() (result string, err error)
func (*WalletServiceImpl) GetEstimatedAllocatedAllowance ¶
func (w *WalletServiceImpl) GetEstimatedAllocatedAllowance(query EstimatedAllocatedAllowanceQuery) (frozenAmount string, err error)
func (*WalletServiceImpl) GetFills ¶
func (w *WalletServiceImpl) GetFills(query FillQuery) (dao.PageResult, error)
func (*WalletServiceImpl) GetFrozenLRCFee ¶
func (w *WalletServiceImpl) GetFrozenLRCFee(query SingleOwner) (frozenAmount string, err error)
func (*WalletServiceImpl) GetGlobalMarketTicker ¶
func (w *WalletServiceImpl) GetGlobalMarketTicker(req SingleToken) (tickers map[string][]market.GlobalMarketTicker, err error)
func (*WalletServiceImpl) GetGlobalTicker ¶
func (w *WalletServiceImpl) GetGlobalTicker(req SingleToken) (ticker map[string]market.GlobalTicker, err error)
func (*WalletServiceImpl) GetGlobalTrend ¶
func (w *WalletServiceImpl) GetGlobalTrend(req SingleToken) (trend map[string][]market.GlobalTrend, err error)
func (*WalletServiceImpl) GetLatestFills ¶
func (w *WalletServiceImpl) GetLatestFills(query FillQuery) ([]LatestFill, error)
func (*WalletServiceImpl) GetLatestMarketOrders ¶
func (w *WalletServiceImpl) GetLatestMarketOrders(query LatestOrderQuery) (res []OrderJsonResult, err error)
func (*WalletServiceImpl) GetLatestOrders ¶
func (w *WalletServiceImpl) GetLatestOrders(query LatestOrderQuery) (res []OrderJsonResult, err error)
func (*WalletServiceImpl) GetLatestP2POrders ¶
func (w *WalletServiceImpl) GetLatestP2POrders(query LatestOrderQuery) (res []OrderJsonResult, err error)
func (*WalletServiceImpl) GetLatestTransactions ¶
func (w *WalletServiceImpl) GetLatestTransactions(query TransactionQuery) ([]txtyp.TransactionJsonResult, error)
func (*WalletServiceImpl) GetLooprSupportedMarket ¶
func (w *WalletServiceImpl) GetLooprSupportedMarket() (markets []string, err error)
func (*WalletServiceImpl) GetLooprSupportedTokens ¶
func (w *WalletServiceImpl) GetLooprSupportedTokens() (markets []types.Token, err error)
func (*WalletServiceImpl) GetNonce ¶
func (w *WalletServiceImpl) GetNonce(owner SingleOwner) (n int64, err error)
func (*WalletServiceImpl) GetOldVersionWethBalance ¶
func (w *WalletServiceImpl) GetOldVersionWethBalance(owner SingleOwner) (res string, err error)
func (*WalletServiceImpl) GetOrderByHash ¶
func (w *WalletServiceImpl) GetOrderByHash(query OrderQuery) (order OrderJsonResult, err error)
func (*WalletServiceImpl) GetOrderTransfer ¶
func (w *WalletServiceImpl) GetOrderTransfer(req OrderTransferQuery) (ot OrderTransfer, err error)
func (*WalletServiceImpl) GetOrders ¶
func (w *WalletServiceImpl) GetOrders(query *OrderQuery) (res PageResult, err error)
func (*WalletServiceImpl) GetPendingRawTxByHash ¶
func (w *WalletServiceImpl) GetPendingRawTxByHash(query TransactionQuery) (result TxNotify, err error)
func (*WalletServiceImpl) GetPendingTransactions ¶
func (w *WalletServiceImpl) GetPendingTransactions(query SingleOwner) (result []txtyp.TransactionJsonResult, err error)
func (*WalletServiceImpl) GetPortfolio ¶
func (w *WalletServiceImpl) GetPortfolio(query SingleOwner) (res []Portfolio, err error)
func (*WalletServiceImpl) GetPriceQuote ¶
func (w *WalletServiceImpl) GetPriceQuote(query PriceQuoteQuery) (result PriceQuote, err error)
func (*WalletServiceImpl) GetRingMined ¶
func (w *WalletServiceImpl) GetRingMined(query RingMinedQuery) (res dao.PageResult, err error)
func (*WalletServiceImpl) GetRingMinedDetail ¶
func (w *WalletServiceImpl) GetRingMinedDetail(query RingMinedQuery) (res RingMinedDetail, err error)
func (*WalletServiceImpl) GetSupportedMarket ¶
func (w *WalletServiceImpl) GetSupportedMarket() (markets []string, err error)
func (*WalletServiceImpl) GetSupportedTokens ¶
func (w *WalletServiceImpl) GetSupportedTokens() (markets []types.Token, err error)
func (*WalletServiceImpl) GetTempStore ¶
func (w *WalletServiceImpl) GetTempStore(req SimpleKey) (ts string, err error)
func (*WalletServiceImpl) GetTicker ¶
func (w *WalletServiceImpl) GetTicker() (res []market.Ticker, err error)
func (*WalletServiceImpl) GetTickers ¶
func (w *WalletServiceImpl) GetTickers(mkt SingleMarket) (result map[string]market.Ticker, err error)
func (*WalletServiceImpl) GetTransactions ¶
func (w *WalletServiceImpl) GetTransactions(query TransactionQuery) (PageResult, error)
func (*WalletServiceImpl) GetTransactionsByHash ¶
func (w *WalletServiceImpl) GetTransactionsByHash(query TransactionQuery) (result []txtyp.TransactionJsonResult, err error)
func (*WalletServiceImpl) GetTrend ¶
func (w *WalletServiceImpl) GetTrend(query TrendQuery) (res []market.Trend, err error)
func (*WalletServiceImpl) GetUnmergedOrderBook ¶
func (w *WalletServiceImpl) GetUnmergedOrderBook(query DepthQuery) (res OrderBook, err error)
func (*WalletServiceImpl) NotifyCirculr ¶
func (w *WalletServiceImpl) NotifyCirculr(req NotifyCirculrBody) (owner string, err error)
func (*WalletServiceImpl) NotifyScanLogin ¶
func (w *WalletServiceImpl) NotifyScanLogin(req SignedLoginInfo) (rst string, err error)
func (*WalletServiceImpl) NotifyTransactionSubmitted ¶
func (w *WalletServiceImpl) NotifyTransactionSubmitted(txNotify TxNotify) (result string, err error)
func (*WalletServiceImpl) QueryTicket ¶
func (w *WalletServiceImpl) QueryTicket(query TicketQuery) (ticket dao.TicketReceiver, err error)
func (*WalletServiceImpl) SetOrderTransfer ¶
func (w *WalletServiceImpl) SetOrderTransfer(req OrderTransfer) (hash string, err error)
func (*WalletServiceImpl) SetTempStore ¶
func (w *WalletServiceImpl) SetTempStore(req TempStore) (hash string, err error)
func (*WalletServiceImpl) SubmitOrder ¶
func (w *WalletServiceImpl) SubmitOrder(order *types.OrderJsonRequest) (res string, err error)
func (*WalletServiceImpl) SubmitRingForP2P ¶
func (w *WalletServiceImpl) SubmitRingForP2P(p2pRing P2PRingRequest) (res string, err error)
func (*WalletServiceImpl) TestPing ¶
func (w *WalletServiceImpl) TestPing(input int) (resp []byte, err error)
func (*WalletServiceImpl) TicketCount ¶
func (w *WalletServiceImpl) TicketCount() (int, error)
func (*WalletServiceImpl) UnlockWallet ¶
func (w *WalletServiceImpl) UnlockWallet(owner SingleOwner) (result string, err error)
func (*WalletServiceImpl) UpdateOrderTransfer ¶
func (w *WalletServiceImpl) UpdateOrderTransfer(req OrderTransfer) (hash string, err error)
type WebsocketOptions ¶
type WebsocketOptions struct {
Port string
}
type WebsocketRequest ¶
type WebsocketService ¶
type WebsocketService interface {
Start(port string)
Stop()
}
type WebsocketServiceImpl ¶
type WebsocketServiceImpl struct {
// contains filtered or unexported fields
}
func NewWebsocketService ¶
func NewWebsocketService(port string, trendManager market.TrendManager, accountManager accountmanager.AccountManager, capProvider marketcap.MarketCapProvider) *WebsocketServiceImpl
this code is not stable
func (*WebsocketServiceImpl) Start ¶
func (ws *WebsocketServiceImpl) Start()
Click to show internal directories.
Click to hide internal directories.