Documentation ¶
Index ¶
- func InitCfg(rcfg *types.RPC)
- func InitFilterPrintFuncBlacklist()
- func InitGrpcFuncBlacklist(cfg *types.RPC)
- func InitGrpcFuncWhitelist(cfg *types.RPC)
- func InitIPWhitelist(cfg *types.RPC)
- func InitJrpcFuncBlacklist(cfg *types.RPC)
- func InitJrpcFuncWhitelist(cfg *types.RPC)
- type Chain
- func (c *Chain) AddBlacklist(in *types.BlackPeer, result *interface{}) error
- func (c *Chain) AddPushSubscribe(in *types.PushSubscribeReq, result *interface{}) error
- func (c *Chain) ClosePeer(in *types.SetPeer, result *interface{}) error
- func (c *Chain) CloseQueue(in *types.ReqNil, result *interface{}) error
- func (c *Chain) ConvertExectoAddr(in rpctypes.ExecNameParm, result *string) error
- func (c *Chain) CreateNoBalanceTransaction(in *types.NoBalanceTx, result *string) error
- func (c *Chain) CreateNoBlanaceTxs(in *types.NoBalanceTxs, result *string) error
- func (c *Chain) CreateRawTransaction(in *rpctypes.CreateTx, result *interface{}) error
- func (c *Chain) CreateRawTxGroup(in *types.CreateTransactionGroup, result *interface{}) error
- func (c *Chain) CreateTransaction(in *rpctypes.CreateTxIn, result *interface{}) error
- func (c *Chain) DecodeRawTransaction(in *types.ReqDecodeRawTransaction, result *interface{}) error
- func (c *Chain) DelBlacklist(in *types.BlackPeer, result *interface{}) error
- func (c *Chain) DialPeer(in *types.SetPeer, result *interface{}) error
- func (c *Chain) DumpPrivkey(in *types.ReqString, result *interface{}) error
- func (c *Chain) DumpPrivkeysFile(in *types.ReqPrivkeysFile, result *interface{}) error
- func (c *Chain) ExecWallet(in *rpctypes.ChainExecutor, result *interface{}) error
- func (c *Chain) GenSeed(in *types.GenSeedLang, result *interface{}) error
- func (c *Chain) GetAccount(in *types.ReqGetAccount, result *interface{}) error
- func (c *Chain) GetAccounts(in *types.ReqAccountList, result *interface{}) error
- func (c *Chain) GetAccountsV2(in *types.ReqNil, result *interface{}) error
- func (c *Chain) GetAddrOverview(in *types.ReqAddr, result *interface{}) error
- func (c *Chain) GetAddressDrivers(in *types.ReqNil, result *interface{}) error
- func (c *Chain) GetAllExecBalance(in *types.ReqAllExecBalance, result *interface{}) error
- func (c *Chain) GetBalance(in *types.ReqBalance, result *interface{}) error
- func (c *Chain) GetBlockByHashes(in rpctypes.ReqHashes, result *interface{}) error
- func (c *Chain) GetBlockBySeq(in *types.Int64, result *interface{}) error
- func (c *Chain) GetBlockHash(in *types.ReqInt, result *interface{}) error
- func (c *Chain) GetBlockOverview(in rpctypes.QueryParm, result *interface{}) error
- func (c *Chain) GetBlockSequences(in rpctypes.BlockParam, result *interface{}) error
- func (c *Chain) GetBlocks(in rpctypes.BlockParam, result *interface{}) error
- func (c *Chain) GetChainConfig(in *types.ReqNil, result *interface{}) error
- func (c *Chain) GetChainID(in *types.ReqNil, result *interface{}) error
- func (c *Chain) GetCoinSymbol(in *types.ReqNil, result *interface{}) error
- func (c *Chain) GetCryptoList(in *types.ReqNil, result *interface{}) error
- func (c *Chain) GetExecBalance(in *types.ReqGetExecBalance, result *interface{}) error
- func (c *Chain) GetFatalFailure(in *types.ReqNil, result *interface{}) error
- func (c *Chain) GetHeaders(in *types.ReqBlocks, result *interface{}) error
- func (c *Chain) GetHexTxByHash(in rpctypes.QueryParm, result *interface{}) error
- func (c *Chain) GetLastBlockSequence(in *types.ReqNil, result *interface{}) error
- func (c *Chain) GetLastHeader(in *types.ReqNil, result *interface{}) error
- func (c *Chain) GetLastMemPool(in *types.ReqNil, result *interface{}) error
- func (c *Chain) GetMempool(in *types.ReqGetMempool, result *interface{}) error
- func (c *Chain) GetNetInfo(in *types.P2PGetNetInfoReq, result *interface{}) error
- func (c *Chain) GetParaTxByHeight(req *types.ReqParaTxByHeight, result *interface{}) error
- func (c *Chain) GetParaTxByTitle(req *types.ReqParaTxByTitle, result *interface{}) error
- func (c *Chain) GetPeerInfo(in *types.P2PGetPeerReq, result *interface{}) error
- func (c *Chain) GetProperFee(in *types.ReqProperFee, result *interface{}) error
- func (c *Chain) GetPushSeqLastNum(in *types.ReqString, result *interface{}) error
- func (c *Chain) GetSeed(in *types.GetSeedByPw, result *interface{}) error
- func (c *Chain) GetSequenceByHash(in rpctypes.ReqHashes, result *interface{}) error
- func (c *Chain) GetServerTime(in *types.ReqNil, result *interface{}) error
- func (c *Chain) GetTimeStatus(in *types.ReqNil, result *interface{}) error
- func (c *Chain) GetTotalCoins(in *types.ReqGetTotalCoins, result *interface{}) error
- func (c *Chain) GetTxByAddr(in *types.ReqAddr, result *interface{}) error
- func (c *Chain) GetTxByHashes(in rpctypes.ReqHashes, result *interface{}) error
- func (c *Chain) GetWalletRecoverAddress(req *types.ReqGetWalletRecoverAddr, result *interface{}) error
- func (c *Chain) GetWalletStatus(in *types.ReqNil, result *interface{}) error
- func (c *Chain) ImportPrivkey(in *types.ReqWalletImportPrivkey, result *interface{}) error
- func (c *Chain) ImportPrivkeysFile(in *types.ReqPrivkeysFile, result *interface{}) error
- func (c *Chain) IsNtpClockSync(in *types.ReqNil, result *interface{}) error
- func (c *Chain) IsSync(in *types.ReqNil, result *interface{}) error
- func (c *Chain) ListPushes(in *types.ReqNil, result *interface{}) error
- func (c *Chain) LoadParaTxByTitle(req *types.ReqHeightByTitle, result *interface{}) error
- func (c *Chain) Lock(in *types.ReqNil, result *interface{}) error
- func (c *Chain) MergeBalance(in *types.ReqWalletMergeBalance, result *interface{}) error
- func (c *Chain) NetProtocols(in *types.ReqNil, result *interface{}) error
- func (c *Chain) NewAccount(in *types.ReqNewAccount, result *interface{}) error
- func (c *Chain) NewRandAccount(in *types.GenSeedLang, result *interface{}) error
- func (c *Chain) PubKeyToAddr(in *types.ReqString, result *interface{}) error
- func (c *Chain) Query(in rpctypes.Query4Jrpc, result *interface{}) error
- func (c *Chain) QueryChain(in rpctypes.ChainExecutor, result *interface{}) error
- func (c *Chain) QueryTotalFee(in *types.LocalDBGet, result *interface{}) error
- func (c *Chain) QueryTransaction(in rpctypes.QueryParm, result *interface{}) error
- func (c *Chain) ReWriteRawTx(in *rpctypes.ReWriteRawTx, result *interface{}) error
- func (c *Chain) SaveSeed(in *types.SaveSeedByPw, result *interface{}) error
- func (c *Chain) SendDelayTransaction(in *types.ReqString, result *interface{}) error
- func (c *Chain) SendToAddress(in *types.ReqWalletSendToAddress, result *interface{}) error
- func (c *Chain) SendTransaction(in rpctypes.RawParm, result *interface{}) error
- func (c *Chain) SendTransactionSync(in rpctypes.RawParm, result *interface{}) error
- func (c *Chain) SendTransactions(in rpctypes.ReqStrings, result *interface{}) error
- func (c *Chain) SetLabl(in *types.ReqWalletSetLabel, result *interface{}) error
- func (c *Chain) SetPasswd(in *types.ReqWalletSetPasswd, result *interface{}) error
- func (c *Chain) SetTxFee(in *types.ReqWalletSetFee, result *interface{}) error
- func (c *Chain) ShowBlacklist(in *types.ReqNil, result *interface{}) error
- func (c *Chain) SignRawTx(in *types.ReqSignRawTx, result *interface{}) error
- func (c *Chain) SignWalletRecoverTx(req *types.ReqSignWalletRecoverTx, result *interface{}) error
- func (c *Chain) UnLock(in *types.WalletUnLock, result *interface{}) error
- func (c *Chain) Version(in *types.ReqNil, result *interface{}) error
- func (c *Chain) WalletTxList(in rpctypes.ReqWalletTransactionList, result *interface{}) error
- type Grpc
- func (g *Grpc) AddPushSubscribe(ctx context.Context, in *pb.PushSubscribeReq) (*pb.ReplySubscribePush, error)
- func (g *Grpc) CloseQueue(ctx context.Context, in *pb.ReqNil) (*pb.Reply, error)
- func (g *Grpc) ConvertExectoAddr(ctx context.Context, in *pb.ReqString) (*pb.ReplyString, error)
- func (g *Grpc) CreateNoBalanceTransaction(ctx context.Context, in *pb.NoBalanceTx) (*pb.ReplySignRawTx, error)
- func (g *Grpc) CreateNoBalanceTxs(ctx context.Context, in *pb.NoBalanceTxs) (*pb.ReplySignRawTx, error)
- func (g *Grpc) CreateRawTransaction(ctx context.Context, in *pb.CreateTx) (*pb.UnsignTx, error)
- func (g *Grpc) CreateRawTxGroup(ctx context.Context, in *pb.CreateTransactionGroup) (*pb.UnsignTx, error)
- func (g *Grpc) CreateTransaction(ctx context.Context, in *pb.CreateTxIn) (*pb.UnsignTx, error)
- func (g *Grpc) DumpPrivkey(ctx context.Context, in *pb.ReqString) (*pb.ReplyString, error)
- func (g *Grpc) DumpPrivkeysFile(ctx context.Context, in *pb.ReqPrivkeysFile) (*pb.Reply, error)
- func (g *Grpc) ExecWallet(ctx context.Context, in *pb.ChainExecutor) (*pb.Reply, error)
- func (g *Grpc) GenSeed(ctx context.Context, in *pb.GenSeedLang) (*pb.ReplySeed, error)
- func (g *Grpc) GetAccount(ctx context.Context, in *pb.ReqGetAccount) (*pb.WalletAccount, error)
- func (g *Grpc) GetAccounts(ctx context.Context, in *pb.ReqNil) (*pb.WalletAccounts, error)
- func (g *Grpc) GetAddrOverview(ctx context.Context, in *pb.ReqAddr) (*pb.AddrOverview, error)
- func (g *Grpc) GetAddressDrivers(ctx context.Context, in *pb.ReqNil) (*pb.AddressDrivers, error)
- func (g *Grpc) GetAllExecBalance(ctx context.Context, in *pb.ReqAllExecBalance) (*pb.AllExecBalance, error)
- func (g *Grpc) GetBalance(ctx context.Context, in *pb.ReqBalance) (*pb.Accounts, error)
- func (g *Grpc) GetBlockByHashes(ctx context.Context, in *pb.ReqHashes) (*pb.BlockDetails, error)
- func (g *Grpc) GetBlockBySeq(ctx context.Context, in *pb.Int64) (*pb.BlockSeq, error)
- func (g *Grpc) GetBlockHash(ctx context.Context, in *pb.ReqInt) (*pb.ReplyHash, error)
- func (g *Grpc) GetBlockOverview(ctx context.Context, in *pb.ReqHash) (*pb.BlockOverview, error)
- func (g *Grpc) GetBlockSequences(ctx context.Context, in *pb.ReqBlocks) (*pb.BlockSequences, error)
- func (g *Grpc) GetBlocks(ctx context.Context, in *pb.ReqBlocks) (*pb.Reply, error)
- func (g *Grpc) GetChainConfig(ctx context.Context, in *pb.ReqNil) (*pb.ChainConfigInfo, error)
- func (g *Grpc) GetCoinSymbol(ctx context.Context, in *pb.ReqNil) (*pb.ReplyString, error)
- func (g *Grpc) GetCryptoList(ctx context.Context, in *pb.ReqNil) (*pb.CryptoList, error)
- func (g *Grpc) GetFatalFailure(ctx context.Context, in *pb.ReqNil) (*pb.Int32, error)
- func (g *Grpc) GetFork(ctx context.Context, in *pb.ReqKey) (*pb.Int64, error)
- func (g *Grpc) GetHeaders(ctx context.Context, in *pb.ReqBlocks) (*pb.Headers, error)
- func (g *Grpc) GetHexTxByHash(ctx context.Context, in *pb.ReqHash) (*pb.HexTx, error)
- func (g *Grpc) GetLastBlockSequence(ctx context.Context, in *pb.ReqNil) (*pb.Int64, error)
- func (g *Grpc) GetLastHeader(ctx context.Context, in *pb.ReqNil) (*pb.Header, error)
- func (g *Grpc) GetLastMemPool(ctx context.Context, in *pb.ReqNil) (*pb.ReplyTxList, error)
- func (g *Grpc) GetMemPool(ctx context.Context, in *pb.ReqGetMempool) (*pb.ReplyTxList, error)
- func (g *Grpc) GetParaTxByHeight(ctx context.Context, in *pb.ReqParaTxByHeight) (*pb.ParaTxDetails, error)
- func (g *Grpc) GetParaTxByTitle(ctx context.Context, in *pb.ReqParaTxByTitle) (*pb.ParaTxDetails, error)
- func (g *Grpc) GetPeerInfo(ctx context.Context, req *pb.P2PGetPeerReq) (*pb.PeerList, error)
- func (g *Grpc) GetProperFee(ctx context.Context, in *pb.ReqProperFee) (*pb.ReplyProperFee, error)
- func (g *Grpc) GetPushSeqLastNum(ctx context.Context, in *pb.ReqString) (*pb.Int64, error)
- func (g *Grpc) GetSeed(ctx context.Context, in *pb.GetSeedByPw) (*pb.ReplySeed, error)
- func (g *Grpc) GetSequenceByHash(ctx context.Context, in *pb.ReqHash) (*pb.Int64, error)
- func (g *Grpc) GetServerTime(ctx context.Context, in *pb.ReqNil) (*pb.ServerTime, error)
- func (g *Grpc) GetTransactionByAddr(ctx context.Context, in *pb.ReqAddr) (*pb.ReplyTxInfos, error)
- func (g *Grpc) GetTransactionByHashes(ctx context.Context, in *pb.ReqHashes) (*pb.TransactionDetails, error)
- func (g *Grpc) GetWalletRecoverAddress(ctx context.Context, in *pb.ReqGetWalletRecoverAddr) (*pb.ReplyString, error)
- func (g *Grpc) GetWalletStatus(ctx context.Context, in *pb.ReqNil) (*pb.WalletStatus, error)
- func (g *Grpc) ImportPrivkey(ctx context.Context, in *pb.ReqWalletImportPrivkey) (*pb.WalletAccount, error)
- func (g *Grpc) ImportPrivkeysFile(ctx context.Context, in *pb.ReqPrivkeysFile) (*pb.Reply, error)
- func (g *Grpc) IsNtpClockSync(ctx context.Context, in *pb.ReqNil) (*pb.Reply, error)
- func (g *Grpc) IsSync(ctx context.Context, in *pb.ReqNil) (*pb.Reply, error)
- func (g *Grpc) ListPushes(ctx context.Context, in *pb.ReqNil) (*pb.PushSubscribes, error)
- func (g *Grpc) LoadParaTxByTitle(ctx context.Context, in *pb.ReqHeightByTitle) (*pb.ReplyHeightByTitle, error)
- func (g *Grpc) Lock(ctx context.Context, in *pb.ReqNil) (*pb.Reply, error)
- func (g *Grpc) MergeBalance(ctx context.Context, in *pb.ReqWalletMergeBalance) (*pb.ReplyHashes, error)
- func (g *Grpc) NetInfo(ctx context.Context, in *pb.P2PGetNetInfoReq) (*pb.NodeNetInfo, error)
- func (g *Grpc) NewAccount(ctx context.Context, in *pb.ReqNewAccount) (*pb.WalletAccount, error)
- func (g *Grpc) QueryChain(ctx context.Context, in *pb.ChainExecutor) (*pb.Reply, error)
- func (g *Grpc) QueryConsensus(ctx context.Context, in *pb.ChainExecutor) (*pb.Reply, error)
- func (g *Grpc) QueryRandNum(ctx context.Context, in *pb.ReqRandHash) (*pb.ReplyHash, error)
- func (g *Grpc) QueryTransaction(ctx context.Context, in *pb.ReqHash) (*pb.TransactionDetail, error)
- func (g *Grpc) ReWriteTx(ctx context.Context, in *pb.ReWriteRawTx) (*pb.UnsignTx, error)
- func (g *Grpc) SaveSeed(ctx context.Context, in *pb.SaveSeedByPw) (*pb.Reply, error)
- func (g *Grpc) SendDelayTransaction(ctx context.Context, in *pb.DelayTx) (*pb.Reply, error)
- func (g *Grpc) SendToAddress(ctx context.Context, in *pb.ReqWalletSendToAddress) (*pb.ReplyHash, error)
- func (g *Grpc) SendTransaction(ctx context.Context, in *pb.Transaction) (*pb.Reply, error)
- func (g *Grpc) SendTransactionSync(ctx context.Context, in *pb.Transaction) (*pb.Reply, error)
- func (g *Grpc) SendTransactions(ctx context.Context, in *pb.Transactions) (*pb.Replies, error)
- func (g *Grpc) SetLabl(ctx context.Context, in *pb.ReqWalletSetLabel) (*pb.WalletAccount, error)
- func (g *Grpc) SetPasswd(ctx context.Context, in *pb.ReqWalletSetPasswd) (*pb.Reply, error)
- func (g *Grpc) SetTxFee(ctx context.Context, in *pb.ReqWalletSetFee) (*pb.Reply, error)
- func (g *Grpc) SignRawTx(ctx context.Context, in *pb.ReqSignRawTx) (*pb.ReplySignRawTx, error)
- func (g *Grpc) SignWalletRecoverTx(ctx context.Context, in *pb.ReqSignWalletRecoverTx) (*pb.ReplySignRawTx, error)
- func (g *Grpc) SubEvent(in *pb.ReqSubscribe, resp pb.Chain_SubEventServer) error
- func (g *Grpc) UnLock(ctx context.Context, in *pb.WalletUnLock) (*pb.Reply, error)
- func (g *Grpc) UnSubEvent(ctx context.Context, in *pb.ReqString) (*pb.Reply, error)
- func (g *Grpc) Version(ctx context.Context, in *pb.ReqNil) (*pb.VersionInfo, error)
- func (g *Grpc) WalletTransactionList(ctx context.Context, in *pb.ReqWalletTransactionList) (*pb.WalletTxDetails, error)
- type Grpcserver
- type HTTPConn
- type JSONRPCServer
- type PushType
- type RPC
- func (r *RPC) Close()
- func (r *RPC) GRPC() *grpc.Server
- func (r *RPC) GetQueueClient() queue.Client
- func (r *RPC) JRPC() *rpc.Server
- func (r *RPC) Listen() (port1 int, port2 int, port3, port4 int)
- func (r *RPC) SetAPI(api client.QueueProtocolAPI)
- func (r *RPC) SetQueueClient(c queue.Client)
- func (r *RPC) SetQueueClientNoListen(c queue.Client)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitFilterPrintFuncBlacklist ¶
func InitFilterPrintFuncBlacklist()
InitFilterPrintFuncBlacklist rpc模块打印requet信息时需要过滤掉一些敏感接口的入参打印,比如钱包密码相关的
func InitGrpcFuncBlacklist ¶
InitGrpcFuncBlacklist init grpc function blacklist
func InitGrpcFuncWhitelist ¶
InitGrpcFuncWhitelist init grpc function whitelist
func InitJrpcFuncBlacklist ¶
InitJrpcFuncBlacklist init jrpc function blacklist
func InitJrpcFuncWhitelist ¶
InitJrpcFuncWhitelist init jrpc function whitelist
Types ¶
type Chain ¶
type Chain struct {
// contains filtered or unexported fields
}
Chain a channel client
func (*Chain) AddBlacklist ¶
AddBlacklist add peer to blacklist ,time deadline:10 years
func (*Chain) AddPushSubscribe ¶
func (c *Chain) AddPushSubscribe(in *types.PushSubscribeReq, result *interface{}) error
AddPushSubscribe add Seq CallBack
func (*Chain) CloseQueue ¶
CloseQueue close queue
func (*Chain) ConvertExectoAddr ¶
func (c *Chain) ConvertExectoAddr(in rpctypes.ExecNameParm, result *string) error
ConvertExectoAddr convert exec to address
func (*Chain) CreateNoBalanceTransaction ¶
func (c *Chain) CreateNoBalanceTransaction(in *types.NoBalanceTx, result *string) error
CreateNoBalanceTransaction create transaction with no balance
func (*Chain) CreateNoBlanaceTxs ¶
func (c *Chain) CreateNoBlanaceTxs(in *types.NoBalanceTxs, result *string) error
CreateNoBlanaceTxs create multiple transaction with no balance
func (*Chain) CreateRawTransaction ¶
CreateRawTransaction create rawtransaction by jrpc
func (*Chain) CreateRawTxGroup ¶
func (c *Chain) CreateRawTxGroup(in *types.CreateTransactionGroup, result *interface{}) error
CreateRawTxGroup create rawtransaction with group
func (*Chain) CreateTransaction ¶
func (c *Chain) CreateTransaction(in *rpctypes.CreateTxIn, result *interface{}) error
CreateTransaction create transaction
func (*Chain) DecodeRawTransaction ¶
func (c *Chain) DecodeRawTransaction(in *types.ReqDecodeRawTransaction, result *interface{}) error
DecodeRawTransaction 考虑交易组的解析统一返回ReplyTxList列表
func (*Chain) DelBlacklist ¶
DelBlacklist delete peer from blacklist
func (*Chain) DumpPrivkey ¶
DumpPrivkey dump privkey
func (*Chain) DumpPrivkeysFile ¶
func (c *Chain) DumpPrivkeysFile(in *types.ReqPrivkeysFile, result *interface{}) error
DumpPrivkeysFile dumps private key to file.
func (*Chain) ExecWallet ¶
func (c *Chain) ExecWallet(in *rpctypes.ChainExecutor, result *interface{}) error
ExecWallet exec wallet
func (*Chain) GenSeed ¶
func (c *Chain) GenSeed(in *types.GenSeedLang, result *interface{}) error
GenSeed seed
func (*Chain) GetAccount ¶
func (c *Chain) GetAccount(in *types.ReqGetAccount, result *interface{}) error
GetAccount getAddress by lable
func (*Chain) GetAccounts ¶
func (c *Chain) GetAccounts(in *types.ReqAccountList, result *interface{}) error
GetAccounts get accounts
func (*Chain) GetAccountsV2 ¶
GetAccountsV2 get accounts for version 2
func (*Chain) GetAddrOverview ¶
GetAddrOverview get overview of address
func (*Chain) GetAddressDrivers ¶
GetAddressDrivers 获取系统已注册地址插件
func (*Chain) GetAllExecBalance ¶
func (c *Chain) GetAllExecBalance(in *types.ReqAllExecBalance, result *interface{}) error
GetAllExecBalance get all balance of exec
func (*Chain) GetBalance ¶
func (c *Chain) GetBalance(in *types.ReqBalance, result *interface{}) error
GetBalance get balance
func (*Chain) GetBlockByHashes ¶
GetBlockByHashes get block information by hashes
func (*Chain) GetBlockBySeq ¶
GetBlockBySeq get block by seq
func (*Chain) GetBlockHash ¶
GetBlockHash get block hash
func (*Chain) GetBlockOverview ¶
GetBlockOverview get overview of block GetBlockOverview(parm *types.ReqHash) (*types.BlockOverview, error)
func (*Chain) GetBlockSequences ¶
func (c *Chain) GetBlockSequences(in rpctypes.BlockParam, result *interface{}) error
GetBlockSequences get the block loading sequence number information for the specified interval
func (*Chain) GetBlocks ¶
func (c *Chain) GetBlocks(in rpctypes.BlockParam, result *interface{}) error
GetBlocks get block information
func (*Chain) GetChainConfig ¶
GetChainConfig 获取chain config 参数
func (*Chain) GetChainID ¶
GetChainID 获取chain ID
func (*Chain) GetCoinSymbol ¶
GetCoinSymbol get coin symbol
func (*Chain) GetCryptoList ¶
GetCryptoList 获取加密列表
func (*Chain) GetExecBalance ¶
func (c *Chain) GetExecBalance(in *types.ReqGetExecBalance, result *interface{}) error
GetExecBalance get balance exec
func (*Chain) GetFatalFailure ¶
GetFatalFailure return fatal failure
func (*Chain) GetHeaders ¶
GetHeaders get headers
func (*Chain) GetHexTxByHash ¶
GetHexTxByHash get hex transaction by hash
func (*Chain) GetLastBlockSequence ¶
GetLastBlockSequence get sequence last block
func (*Chain) GetLastHeader ¶
GetLastHeader get last header
func (*Chain) GetLastMemPool ¶
GetLastMemPool get contents in last mempool
func (*Chain) GetMempool ¶
func (c *Chain) GetMempool(in *types.ReqGetMempool, result *interface{}) error
GetMempool get mempool information
func (*Chain) GetNetInfo ¶
func (c *Chain) GetNetInfo(in *types.P2PGetNetInfoReq, result *interface{}) error
GetNetInfo get net information
func (*Chain) GetParaTxByHeight ¶
func (c *Chain) GetParaTxByHeight(req *types.ReqParaTxByHeight, result *interface{}) error
GetParaTxByHeight get paraTx by block height
func (*Chain) GetParaTxByTitle ¶
func (c *Chain) GetParaTxByTitle(req *types.ReqParaTxByTitle, result *interface{}) error
GetParaTxByTitle get paraTx by title
func (*Chain) GetPeerInfo ¶
func (c *Chain) GetPeerInfo(in *types.P2PGetPeerReq, result *interface{}) error
GetPeerInfo get peer information
func (*Chain) GetProperFee ¶
func (c *Chain) GetProperFee(in *types.ReqProperFee, result *interface{}) error
GetProperFee get contents in proper fee
func (*Chain) GetPushSeqLastNum ¶
GetPushSeqLastNum Get Seq Call Back Last Num
func (*Chain) GetSeed ¶
func (c *Chain) GetSeed(in *types.GetSeedByPw, result *interface{}) error
GetSeed get seed
func (*Chain) GetSequenceByHash ¶
GetSequenceByHash get sequcen by hashes
func (*Chain) GetServerTime ¶
GetServerTime get server time
func (*Chain) GetTimeStatus ¶
GetTimeStatus get status of time
func (*Chain) GetTotalCoins ¶
func (c *Chain) GetTotalCoins(in *types.ReqGetTotalCoins, result *interface{}) error
GetTotalCoins get total coins
func (*Chain) GetTxByAddr ¶
GetTxByAddr get transaction by address GetTxByAddr(parm *types.ReqAddr) (*types.ReplyTxInfo, error)
func (*Chain) GetTxByHashes ¶
GetTxByHashes get transaction by hashes
GetTxByHashes(parm *types.ReqHashes) (*types.TransactionDetails, error) GetMempool() (*types.ReplyTxList, error) GetAccounts() (*types.WalletAccounts, error)
func (*Chain) GetWalletRecoverAddress ¶
func (c *Chain) GetWalletRecoverAddress(req *types.ReqGetWalletRecoverAddr, result *interface{}) error
GetWalletRecoverAddress get wallet recover chain addr
func (*Chain) GetWalletStatus ¶
GetWalletStatus get status of wallet
func (*Chain) ImportPrivkey ¶
func (c *Chain) ImportPrivkey(in *types.ReqWalletImportPrivkey, result *interface{}) error
ImportPrivkey import privkey of wallet
func (*Chain) ImportPrivkeysFile ¶
func (c *Chain) ImportPrivkeysFile(in *types.ReqPrivkeysFile, result *interface{}) error
ImportPrivkeysFile imports private key from file.
func (*Chain) IsNtpClockSync ¶
IsNtpClockSync is ntp clock sync
func (*Chain) ListPushes ¶
ListPushes List Seq CallBack
func (*Chain) LoadParaTxByTitle ¶
func (c *Chain) LoadParaTxByTitle(req *types.ReqHeightByTitle, result *interface{}) error
LoadParaTxByTitle load paratx by title
func (*Chain) MergeBalance ¶
func (c *Chain) MergeBalance(in *types.ReqWalletMergeBalance, result *interface{}) error
MergeBalance merge balance
func (*Chain) NetProtocols ¶
NetProtocols get net information
func (*Chain) NewAccount ¶
func (c *Chain) NewAccount(in *types.ReqNewAccount, result *interface{}) error
NewAccount new a account
func (*Chain) NewRandAccount ¶
func (c *Chain) NewRandAccount(in *types.GenSeedLang, result *interface{}) error
NewRandAccount rand new a account
func (*Chain) PubKeyToAddr ¶
PubKeyToAddr pubkey to addr
func (*Chain) Query ¶
func (c *Chain) Query(in rpctypes.Query4Jrpc, result *interface{}) error
Query query
func (*Chain) QueryChain ¶
func (c *Chain) QueryChain(in rpctypes.ChainExecutor, result *interface{}) error
QueryChain querychain by chain executor
func (*Chain) QueryTotalFee ¶
func (c *Chain) QueryTotalFee(in *types.LocalDBGet, result *interface{}) error
QueryTotalFee query total fee
func (*Chain) QueryTransaction ¶
QueryTransaction query transaction
func (*Chain) ReWriteRawTx ¶
func (c *Chain) ReWriteRawTx(in *rpctypes.ReWriteRawTx, result *interface{}) error
ReWriteRawTx re-write raw tx by jrpc
func (*Chain) SaveSeed ¶
func (c *Chain) SaveSeed(in *types.SaveSeedByPw, result *interface{}) error
SaveSeed save seed
func (*Chain) SendDelayTransaction ¶
SendDelayTransaction send delay tx
func (*Chain) SendToAddress ¶
func (c *Chain) SendToAddress(in *types.ReqWalletSendToAddress, result *interface{}) error
SendToAddress send to address of coins
func (*Chain) SendTransaction ¶
SendTransaction send transaction
func (*Chain) SendTransactionSync ¶
SendTransactionSync send transaction and wait reply
func (*Chain) SendTransactions ¶
func (c *Chain) SendTransactions(in rpctypes.ReqStrings, result *interface{}) error
SendTransactions send tx batch
func (*Chain) SetLabl ¶
func (c *Chain) SetLabl(in *types.ReqWalletSetLabel, result *interface{}) error
SetLabl set lable
func (*Chain) SetPasswd ¶
func (c *Chain) SetPasswd(in *types.ReqWalletSetPasswd, result *interface{}) error
SetPasswd set password
func (*Chain) SetTxFee ¶
func (c *Chain) SetTxFee(in *types.ReqWalletSetFee, result *interface{}) error
SetTxFee set tx fee
func (*Chain) ShowBlacklist ¶
ShowBlacklist show all peers from blacklist
func (*Chain) SignRawTx ¶
func (c *Chain) SignRawTx(in *types.ReqSignRawTx, result *interface{}) error
SignRawTx signature the rawtransaction
func (*Chain) SignWalletRecoverTx ¶
func (c *Chain) SignWalletRecoverTx(req *types.ReqSignWalletRecoverTx, result *interface{}) error
SignWalletRecoverTx sign wallet recover transaction
func (*Chain) UnLock ¶
func (c *Chain) UnLock(in *types.WalletUnLock, result *interface{}) error
UnLock wallet unlock
func (*Chain) WalletTxList ¶
func (c *Chain) WalletTxList(in rpctypes.ReqWalletTransactionList, result *interface{}) error
WalletTxList transaction list of wallet
type Grpc ¶
type Grpc struct {
// contains filtered or unexported fields
}
Grpc a channelClient
func (*Grpc) AddPushSubscribe ¶
func (g *Grpc) AddPushSubscribe(ctx context.Context, in *pb.PushSubscribeReq) (*pb.ReplySubscribePush, error)
AddPushSubscribe ...
func (*Grpc) CloseQueue ¶
CloseQueue close queue
func (*Grpc) ConvertExectoAddr ¶
ConvertExectoAddr 根据执行器的名字创建地址
func (*Grpc) CreateNoBalanceTransaction ¶
func (g *Grpc) CreateNoBalanceTransaction(ctx context.Context, in *pb.NoBalanceTx) (*pb.ReplySignRawTx, error)
CreateNoBalanceTransaction create transaction with no balance
func (*Grpc) CreateNoBalanceTxs ¶
func (g *Grpc) CreateNoBalanceTxs(ctx context.Context, in *pb.NoBalanceTxs) (*pb.ReplySignRawTx, error)
CreateNoBalanceTxs create multiple transaction with no balance
func (*Grpc) CreateRawTransaction ¶
CreateRawTransaction create rawtransaction of grpc
func (*Grpc) CreateRawTxGroup ¶
func (g *Grpc) CreateRawTxGroup(ctx context.Context, in *pb.CreateTransactionGroup) (*pb.UnsignTx, error)
CreateRawTxGroup create rawtransaction for group
func (*Grpc) CreateTransaction ¶
CreateTransaction create transaction of grpc
func (*Grpc) DumpPrivkey ¶
DumpPrivkey dump Privkey
func (*Grpc) DumpPrivkeysFile ¶
DumpPrivkeysFile dumps private key to file.
func (*Grpc) ExecWallet ¶
ExecWallet exec wallet
func (*Grpc) GetAccount ¶
func (g *Grpc) GetAccount(ctx context.Context, in *pb.ReqGetAccount) (*pb.WalletAccount, error)
GetAccount 通过地址标签获取账户地址以及账户余额信息
func (*Grpc) GetAccounts ¶
GetAccounts get accounts
func (*Grpc) GetAddrOverview ¶
GetAddrOverview get address overview
func (*Grpc) GetAddressDrivers ¶
GetAddressDrivers 获取已注册地址插件
func (*Grpc) GetAllExecBalance ¶
func (g *Grpc) GetAllExecBalance(ctx context.Context, in *pb.ReqAllExecBalance) (*pb.AllExecBalance, error)
GetAllExecBalance get balance of exec
func (*Grpc) GetBalance ¶
GetBalance get balance
func (*Grpc) GetBlockByHashes ¶
GetBlockByHashes get block by hashes
func (*Grpc) GetBlockBySeq ¶
GetBlockBySeq get block with hash by seq
func (*Grpc) GetBlockHash ¶
GetBlockHash get block hash
func (*Grpc) GetBlockOverview ¶
GetBlockOverview get block overview GetBlockOverview(parm *types.ReqHash) (*types.BlockOverview, error) //add by hyb
func (*Grpc) GetBlockSequences ¶
GetBlockSequences ...
func (*Grpc) GetChainConfig ¶
GetChainConfig 获取chain config 参数
func (*Grpc) GetCoinSymbol ¶
GetCoinSymbol get coin symbol
func (*Grpc) GetCryptoList ¶
GetCryptoList 获取加密算法列表
func (*Grpc) GetFatalFailure ¶
GetFatalFailure return fatal of failure
func (*Grpc) GetHeaders ¶
GetHeaders return headers
func (*Grpc) GetHexTxByHash ¶
GetHexTxByHash get hex transaction by hash
func (*Grpc) GetLastBlockSequence ¶
GetLastBlockSequence get last block sequence
func (*Grpc) GetLastHeader ¶
GetLastHeader get lastheader information
func (*Grpc) GetLastMemPool ¶
GetLastMemPool return last mempool contents
func (*Grpc) GetMemPool ¶
func (g *Grpc) GetMemPool(ctx context.Context, in *pb.ReqGetMempool) (*pb.ReplyTxList, error)
GetMemPool get mempool contents
func (*Grpc) GetParaTxByHeight ¶
func (g *Grpc) GetParaTxByHeight(ctx context.Context, in *pb.ReqParaTxByHeight) (*pb.ParaTxDetails, error)
GetParaTxByHeight //通过区块高度列表+title获取平行链交易
func (*Grpc) GetParaTxByTitle ¶
func (g *Grpc) GetParaTxByTitle(ctx context.Context, in *pb.ReqParaTxByTitle) (*pb.ParaTxDetails, error)
GetParaTxByTitle 通过seq以及title获取对应平行连的交易
func (*Grpc) GetPeerInfo ¶
GetPeerInfo get peer information
func (*Grpc) GetProperFee ¶
func (g *Grpc) GetProperFee(ctx context.Context, in *pb.ReqProperFee) (*pb.ReplyProperFee, error)
GetProperFee return last mempool proper fee
func (*Grpc) GetPushSeqLastNum ¶
GetPushSeqLastNum Get Seq Call Back Last Num
func (*Grpc) GetSequenceByHash ¶
GetSequenceByHash get block sequece by hash
func (*Grpc) GetServerTime ¶
GetServerTime get server time
func (*Grpc) GetTransactionByAddr ¶
GetTransactionByAddr get transaction by address
func (*Grpc) GetTransactionByHashes ¶
func (g *Grpc) GetTransactionByHashes(ctx context.Context, in *pb.ReqHashes) (*pb.TransactionDetails, error)
GetTransactionByHashes get transaction by hashes
func (*Grpc) GetWalletRecoverAddress ¶
func (g *Grpc) GetWalletRecoverAddress(ctx context.Context, in *pb.ReqGetWalletRecoverAddr) (*pb.ReplyString, error)
GetWalletRecoverAddress get recover addr
func (*Grpc) GetWalletStatus ¶
GetWalletStatus get wallet status
func (*Grpc) ImportPrivkey ¶
func (g *Grpc) ImportPrivkey(ctx context.Context, in *pb.ReqWalletImportPrivkey) (*pb.WalletAccount, error)
ImportPrivkey import privkey
func (*Grpc) ImportPrivkeysFile ¶
ImportPrivkeysFile imports private key from file.
func (*Grpc) IsNtpClockSync ¶
IsNtpClockSync is ntp clock sync
func (*Grpc) ListPushes ¶
ListPushes 列举推送服务
func (*Grpc) LoadParaTxByTitle ¶
func (g *Grpc) LoadParaTxByTitle(ctx context.Context, in *pb.ReqHeightByTitle) (*pb.ReplyHeightByTitle, error)
LoadParaTxByTitle //获取拥有此title交易的区块高度
func (*Grpc) MergeBalance ¶
func (g *Grpc) MergeBalance(ctx context.Context, in *pb.ReqWalletMergeBalance) (*pb.ReplyHashes, error)
MergeBalance merge balance of wallet
func (*Grpc) NetInfo ¶
func (g *Grpc) NetInfo(ctx context.Context, in *pb.P2PGetNetInfoReq) (*pb.NodeNetInfo, error)
NetInfo net information
func (*Grpc) NewAccount ¶
func (g *Grpc) NewAccount(ctx context.Context, in *pb.ReqNewAccount) (*pb.WalletAccount, error)
NewAccount produce new account
func (*Grpc) QueryChain ¶
QueryChain query chain
func (*Grpc) QueryConsensus ¶
QueryConsensus query consensus
func (*Grpc) QueryRandNum ¶
QueryRandNum query randHash from ticket
func (*Grpc) QueryTransaction ¶
QueryTransaction query transaction by grpc
func (*Grpc) SendDelayTransaction ¶
SendDelayTransaction send delay tx
func (*Grpc) SendToAddress ¶
func (g *Grpc) SendToAddress(ctx context.Context, in *pb.ReqWalletSendToAddress) (*pb.ReplyHash, error)
SendToAddress send to address of coins
func (*Grpc) SendTransaction ¶
SendTransaction send transaction by network
func (*Grpc) SendTransactionSync ¶
SendTransactionSync send transaction by network and query
func (*Grpc) SendTransactions ¶
SendTransactions send transaction by network
func (*Grpc) SetLabl ¶
func (g *Grpc) SetLabl(ctx context.Context, in *pb.ReqWalletSetLabel) (*pb.WalletAccount, error)
SetLabl set labl
func (*Grpc) SignRawTx ¶
func (g *Grpc) SignRawTx(ctx context.Context, in *pb.ReqSignRawTx) (*pb.ReplySignRawTx, error)
SignRawTx signature rawtransaction
func (*Grpc) SignWalletRecoverTx ¶
func (g *Grpc) SignWalletRecoverTx(ctx context.Context, in *pb.ReqSignWalletRecoverTx) (*pb.ReplySignRawTx, error)
SignWalletRecoverTx sign wallet recover tx
func (*Grpc) SubEvent ¶
func (g *Grpc) SubEvent(in *pb.ReqSubscribe, resp pb.Chain_SubEventServer) error
SubEvent 订阅消息推送服务
func (*Grpc) UnSubEvent ¶
UnSubEvent 取消订阅
func (*Grpc) WalletTransactionList ¶
func (g *Grpc) WalletTransactionList(ctx context.Context, in *pb.ReqWalletTransactionList) (*pb.WalletTxDetails, error)
WalletTransactionList transaction list of wallet
type Grpcserver ¶
type Grpcserver struct {
// contains filtered or unexported fields
}
Grpcserver a object
func NewGRpcServer ¶
func NewGRpcServer(c queue.Client, api client.QueueProtocolAPI) *Grpcserver
NewGRpcServer new grpcserver object
type HTTPConn ¶
type HTTPConn struct {
// contains filtered or unexported fields
}
HTTPConn adapt HTTP connection to ReadWriteCloser
type JSONRPCServer ¶
type JSONRPCServer struct {
// contains filtered or unexported fields
}
JSONRPCServer a json rpcserver object
func NewJSONRPCServer ¶
func NewJSONRPCServer(c queue.Client, api client.QueueProtocolAPI) *JSONRPCServer
NewJSONRPCServer new json rpcserver object
func (*JSONRPCServer) Listen ¶
func (j *JSONRPCServer) Listen() (int, error)
Listen jsonsever listen
type RPC ¶
type RPC struct {
// contains filtered or unexported fields
}
RPC a type object
func (*RPC) GetQueueClient ¶
GetQueueClient get queue client
func (*RPC) SetQueueClient ¶
SetQueueClient set queue client
func (*RPC) SetQueueClientNoListen ¶
SetQueueClientNoListen set queue client with no listen