Documentation ¶
Overview ¶
Package rpc chain33 RPC模块包含JSONRpc以及grpc
Index ¶
- func InitCfg(cfg *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 Chain33
- func (c *Chain33) AddBlacklist(in *types.BlackPeer, result *interface{}) error
- func (c *Chain33) AddPushSubscribe(in *types.PushSubscribeReq, result *interface{}) error
- func (c *Chain33) ClosePeer(in *types.SetPeer, result *interface{}) error
- func (c *Chain33) CloseQueue(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) ConvertExectoAddr(in rpctypes.ExecNameParm, result *string) error
- func (c *Chain33) CreateNoBalanceTransaction(in *types.NoBalanceTx, result *string) error
- func (c *Chain33) CreateNoBlanaceTxs(in *types.NoBalanceTxs, result *string) error
- func (c *Chain33) CreateRawTransaction(in *rpctypes.CreateTx, result *interface{}) error
- func (c *Chain33) CreateRawTxGroup(in *types.CreateTransactionGroup, result *interface{}) error
- func (c *Chain33) CreateTransaction(in *rpctypes.CreateTxIn, result *interface{}) error
- func (c *Chain33) DecodeRawTransaction(in *types.ReqDecodeRawTransaction, result *interface{}) error
- func (c *Chain33) DelBlacklist(in *types.BlackPeer, result *interface{}) error
- func (c *Chain33) DialPeer(in *types.SetPeer, result *interface{}) error
- func (c *Chain33) DumpPrivkey(in *types.ReqString, result *interface{}) error
- func (c *Chain33) DumpPrivkeysFile(in *types.ReqPrivkeysFile, result *interface{}) error
- func (c *Chain33) ExecWallet(in *rpctypes.ChainExecutor, result *interface{}) error
- func (c *Chain33) GenSeed(in *types.GenSeedLang, result *interface{}) error
- func (c *Chain33) GetAccount(in *types.ReqGetAccount, result *interface{}) error
- func (c *Chain33) GetAccounts(in *types.ReqAccountList, result *interface{}) error
- func (c *Chain33) GetAccountsV2(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) GetAddrOverview(in *types.ReqAddr, result *interface{}) error
- func (c *Chain33) GetAddressDrivers(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) GetAllExecBalance(in *types.ReqAllExecBalance, result *interface{}) error
- func (c *Chain33) GetBalance(in *types.ReqBalance, result *interface{}) error
- func (c *Chain33) GetBlockByHashes(in rpctypes.ReqHashes, result *interface{}) error
- func (c *Chain33) GetBlockBySeq(in *types.Int64, result *interface{}) error
- func (c *Chain33) GetBlockHash(in *types.ReqInt, result *interface{}) error
- func (c *Chain33) GetBlockOverview(in rpctypes.QueryParm, result *interface{}) error
- func (c *Chain33) GetBlockSequences(in rpctypes.BlockParam, result *interface{}) error
- func (c *Chain33) GetBlocks(in rpctypes.BlockParam, result *interface{}) error
- func (c *Chain33) GetChainConfig(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) GetChainID(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) GetCoinSymbol(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) GetCryptoList(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) GetExecBalance(in *types.ReqGetExecBalance, result *interface{}) error
- func (c *Chain33) GetFatalFailure(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) GetHeaders(in *types.ReqBlocks, result *interface{}) error
- func (c *Chain33) GetHexTxByHash(in rpctypes.QueryParm, result *interface{}) error
- func (c *Chain33) GetLastBlockSequence(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) GetLastHeader(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) GetLastMemPool(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) GetMempool(in *types.ReqGetMempool, result *interface{}) error
- func (c *Chain33) GetNetInfo(in *types.P2PGetNetInfoReq, result *interface{}) error
- func (c *Chain33) GetParaTxByHeight(req *types.ReqParaTxByHeight, result *interface{}) error
- func (c *Chain33) GetParaTxByTitle(req *types.ReqParaTxByTitle, result *interface{}) error
- func (c *Chain33) GetPeerInfo(in *types.P2PGetPeerReq, result *interface{}) error
- func (c *Chain33) GetProperFee(in *types.ReqProperFee, result *interface{}) error
- func (c *Chain33) GetPushSeqLastNum(in *types.ReqString, result *interface{}) error
- func (c *Chain33) GetSeed(in *types.GetSeedByPw, result *interface{}) error
- func (c *Chain33) GetSequenceByHash(in rpctypes.ReqHashes, result *interface{}) error
- func (c *Chain33) GetServerTime(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) GetTimeStatus(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) GetTotalCoins(in *types.ReqGetTotalCoins, result *interface{}) error
- func (c *Chain33) GetTxByAddr(in *types.ReqAddr, result *interface{}) error
- func (c *Chain33) GetTxByHashes(in rpctypes.ReqHashes, result *interface{}) error
- func (c *Chain33) GetWalletRecoverAddress(req *types.ReqGetWalletRecoverAddr, result *interface{}) error
- func (c *Chain33) GetWalletStatus(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) ImportPrivkey(in *types.ReqWalletImportPrivkey, result *interface{}) error
- func (c *Chain33) ImportPrivkeysFile(in *types.ReqPrivkeysFile, result *interface{}) error
- func (c *Chain33) IsNtpClockSync(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) IsSync(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) ListPushes(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) LoadParaTxByTitle(req *types.ReqHeightByTitle, result *interface{}) error
- func (c *Chain33) Lock(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) MergeBalance(in *types.ReqWalletMergeBalance, result *interface{}) error
- func (c *Chain33) NetProtocols(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) NewAccount(in *types.ReqNewAccount, result *interface{}) error
- func (c *Chain33) NewRandAccount(in *types.GenSeedLang, result *interface{}) error
- func (c *Chain33) PubKeyToAddr(in *types.ReqString, result *interface{}) error
- func (c *Chain33) Query(in rpctypes.Query4Jrpc, result *interface{}) error
- func (c *Chain33) QueryChain(in rpctypes.ChainExecutor, result *interface{}) error
- func (c *Chain33) QueryTotalFee(in *types.LocalDBGet, result *interface{}) error
- func (c *Chain33) QueryTransaction(in rpctypes.QueryParm, result *interface{}) error
- func (c *Chain33) ReWriteRawTx(in *rpctypes.ReWriteRawTx, result *interface{}) error
- func (c *Chain33) SaveSeed(in *types.SaveSeedByPw, result *interface{}) error
- func (c *Chain33) SendDelayTransaction(in *types.ReqString, result *interface{}) error
- func (c *Chain33) SendToAddress(in *types.ReqWalletSendToAddress, result *interface{}) error
- func (c *Chain33) SendTransaction(in rpctypes.RawParm, result *interface{}) error
- func (c *Chain33) SendTransactionSync(in rpctypes.RawParm, result *interface{}) error
- func (c *Chain33) SendTransactions(in rpctypes.ReqStrings, result *interface{}) error
- func (c *Chain33) SetLabl(in *types.ReqWalletSetLabel, result *interface{}) error
- func (c *Chain33) SetPasswd(in *types.ReqWalletSetPasswd, result *interface{}) error
- func (c *Chain33) SetTxFee(in *types.ReqWalletSetFee, result *interface{}) error
- func (c *Chain33) ShowBlacklist(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) SignRawTx(in *types.ReqSignRawTx, result *interface{}) error
- func (c *Chain33) SignWalletRecoverTx(req *types.ReqSignWalletRecoverTx, result *interface{}) error
- func (c *Chain33) UnLock(in *types.WalletUnLock, result *interface{}) error
- func (c *Chain33) Version(in *types.ReqNil, result *interface{}) error
- func (c *Chain33) 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.Chain33_SubEventServer) error
- func (g *Grpc) UnLock(ctx context.Context, in *pb.WalletUnLock) (*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)
- 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 Chain33 ¶
type Chain33 struct {
// contains filtered or unexported fields
}
Chain33 a channel client
func (*Chain33) AddBlacklist ¶ added in v1.65.3
AddBlacklist add peer to blacklist ,time deadline:10 years
func (*Chain33) AddPushSubscribe ¶ added in v1.65.0
func (c *Chain33) AddPushSubscribe(in *types.PushSubscribeReq, result *interface{}) error
AddPushSubscribe add Seq CallBack
func (*Chain33) CloseQueue ¶
CloseQueue close queue
func (*Chain33) ConvertExectoAddr ¶
func (c *Chain33) ConvertExectoAddr(in rpctypes.ExecNameParm, result *string) error
ConvertExectoAddr convert exec to address
func (*Chain33) CreateNoBalanceTransaction ¶
func (c *Chain33) CreateNoBalanceTransaction(in *types.NoBalanceTx, result *string) error
CreateNoBalanceTransaction create transaction with no balance
func (*Chain33) CreateNoBlanaceTxs ¶
func (c *Chain33) CreateNoBlanaceTxs(in *types.NoBalanceTxs, result *string) error
CreateNoBlanaceTxs create multiple transaction with no balance
func (*Chain33) CreateRawTransaction ¶
CreateRawTransaction create rawtransaction by jrpc
func (*Chain33) CreateRawTxGroup ¶
func (c *Chain33) CreateRawTxGroup(in *types.CreateTransactionGroup, result *interface{}) error
CreateRawTxGroup create rawtransaction with group
func (*Chain33) CreateTransaction ¶
func (c *Chain33) CreateTransaction(in *rpctypes.CreateTxIn, result *interface{}) error
CreateTransaction create transaction
func (*Chain33) DecodeRawTransaction ¶
func (c *Chain33) DecodeRawTransaction(in *types.ReqDecodeRawTransaction, result *interface{}) error
DecodeRawTransaction 考虑交易组的解析统一返回ReplyTxList列表
func (*Chain33) DelBlacklist ¶ added in v1.65.3
DelBlacklist delete peer from blacklist
func (*Chain33) DumpPrivkey ¶
DumpPrivkey dump privkey
func (*Chain33) DumpPrivkeysFile ¶
func (c *Chain33) DumpPrivkeysFile(in *types.ReqPrivkeysFile, result *interface{}) error
DumpPrivkeysFile dumps private key to file.
func (*Chain33) ExecWallet ¶
func (c *Chain33) ExecWallet(in *rpctypes.ChainExecutor, result *interface{}) error
ExecWallet exec wallet
func (*Chain33) GenSeed ¶
func (c *Chain33) GenSeed(in *types.GenSeedLang, result *interface{}) error
GenSeed seed
func (*Chain33) GetAccount ¶ added in v1.65.0
func (c *Chain33) GetAccount(in *types.ReqGetAccount, result *interface{}) error
GetAccount getAddress by lable
func (*Chain33) GetAccounts ¶
func (c *Chain33) GetAccounts(in *types.ReqAccountList, result *interface{}) error
GetAccounts get accounts
func (*Chain33) GetAccountsV2 ¶
GetAccountsV2 get accounts for version 2
func (*Chain33) GetAddrOverview ¶
GetAddrOverview get overview of address
func (*Chain33) GetAddressDrivers ¶ added in v1.67.1
GetAddressDrivers 获取系统已注册地址插件
func (*Chain33) GetAllExecBalance ¶
func (c *Chain33) GetAllExecBalance(in *types.ReqAllExecBalance, result *interface{}) error
GetAllExecBalance get all balance of exec
func (*Chain33) GetBalance ¶
func (c *Chain33) GetBalance(in *types.ReqBalance, result *interface{}) error
GetBalance get balance
func (*Chain33) GetBlockByHashes ¶
GetBlockByHashes get block information by hashes
func (*Chain33) GetBlockBySeq ¶ added in v1.65.1
GetBlockBySeq get block by seq
func (*Chain33) GetBlockHash ¶
GetBlockHash get block hash
func (*Chain33) GetBlockOverview ¶
GetBlockOverview get overview of block GetBlockOverview(parm *types.ReqHash) (*types.BlockOverview, error)
func (*Chain33) GetBlockSequences ¶
func (c *Chain33) GetBlockSequences(in rpctypes.BlockParam, result *interface{}) error
GetBlockSequences get the block loading sequence number information for the specified interval
func (*Chain33) GetBlocks ¶
func (c *Chain33) GetBlocks(in rpctypes.BlockParam, result *interface{}) error
GetBlocks get block information
func (*Chain33) GetChainConfig ¶ added in v1.65.3
GetChainConfig 获取chain config 参数
func (*Chain33) GetChainID ¶ added in v1.65.3
GetChainID 获取chain ID
func (*Chain33) GetCoinSymbol ¶
GetCoinSymbol get coin symbol
func (*Chain33) GetCryptoList ¶ added in v1.65.3
GetCryptoList 获取加密列表
func (*Chain33) GetExecBalance ¶
func (c *Chain33) GetExecBalance(in *types.ReqGetExecBalance, result *interface{}) error
GetExecBalance get balance exec
func (*Chain33) GetFatalFailure ¶
GetFatalFailure return fatal failure
func (*Chain33) GetHeaders ¶
GetHeaders get headers
func (*Chain33) GetHexTxByHash ¶
GetHexTxByHash get hex transaction by hash
func (*Chain33) GetLastBlockSequence ¶
GetLastBlockSequence get sequence last block
func (*Chain33) GetLastHeader ¶
GetLastHeader get last header
func (*Chain33) GetLastMemPool ¶
GetLastMemPool get contents in last mempool
func (*Chain33) GetMempool ¶
func (c *Chain33) GetMempool(in *types.ReqGetMempool, result *interface{}) error
GetMempool get mempool information
func (*Chain33) GetNetInfo ¶
func (c *Chain33) GetNetInfo(in *types.P2PGetNetInfoReq, result *interface{}) error
GetNetInfo get net information
func (*Chain33) GetParaTxByHeight ¶ added in v1.65.1
func (c *Chain33) GetParaTxByHeight(req *types.ReqParaTxByHeight, result *interface{}) error
GetParaTxByHeight get paraTx by block height
func (*Chain33) GetParaTxByTitle ¶ added in v1.65.1
func (c *Chain33) GetParaTxByTitle(req *types.ReqParaTxByTitle, result *interface{}) error
GetParaTxByTitle get paraTx by title
func (*Chain33) GetPeerInfo ¶
func (c *Chain33) GetPeerInfo(in *types.P2PGetPeerReq, result *interface{}) error
GetPeerInfo get peer information
func (*Chain33) GetProperFee ¶
func (c *Chain33) GetProperFee(in *types.ReqProperFee, result *interface{}) error
GetProperFee get contents in proper fee
func (*Chain33) GetPushSeqLastNum ¶ added in v1.65.0
GetPushSeqLastNum Get Seq Call Back Last Num
func (*Chain33) GetSeed ¶
func (c *Chain33) GetSeed(in *types.GetSeedByPw, result *interface{}) error
GetSeed get seed
func (*Chain33) GetSequenceByHash ¶ added in v1.65.1
GetSequenceByHash get sequcen by hashes
func (*Chain33) GetServerTime ¶ added in v1.65.1
GetServerTime get server time
func (*Chain33) GetTimeStatus ¶
GetTimeStatus get status of time
func (*Chain33) GetTotalCoins ¶
func (c *Chain33) GetTotalCoins(in *types.ReqGetTotalCoins, result *interface{}) error
GetTotalCoins get total coins
func (*Chain33) GetTxByAddr ¶
GetTxByAddr get transaction by address GetTxByAddr(parm *types.ReqAddr) (*types.ReplyTxInfo, error)
func (*Chain33) GetTxByHashes ¶
GetTxByHashes get transaction by hashes
GetTxByHashes(parm *types.ReqHashes) (*types.TransactionDetails, error) GetMempool() (*types.ReplyTxList, error) GetAccounts() (*types.WalletAccounts, error)
func (*Chain33) GetWalletRecoverAddress ¶ added in v1.65.3
func (c *Chain33) GetWalletRecoverAddress(req *types.ReqGetWalletRecoverAddr, result *interface{}) error
GetWalletRecoverAddress get wallet recover chain33 addr
func (*Chain33) GetWalletStatus ¶
GetWalletStatus get status of wallet
func (*Chain33) ImportPrivkey ¶
func (c *Chain33) ImportPrivkey(in *types.ReqWalletImportPrivkey, result *interface{}) error
ImportPrivkey import privkey of wallet
func (*Chain33) ImportPrivkeysFile ¶
func (c *Chain33) ImportPrivkeysFile(in *types.ReqPrivkeysFile, result *interface{}) error
ImportPrivkeysFile imports private key from file.
func (*Chain33) IsNtpClockSync ¶
IsNtpClockSync is ntp clock sync
func (*Chain33) ListPushes ¶ added in v1.65.0
ListPushes List Seq CallBack
func (*Chain33) LoadParaTxByTitle ¶ added in v1.65.1
func (c *Chain33) LoadParaTxByTitle(req *types.ReqHeightByTitle, result *interface{}) error
LoadParaTxByTitle load paratx by title
func (*Chain33) MergeBalance ¶
func (c *Chain33) MergeBalance(in *types.ReqWalletMergeBalance, result *interface{}) error
MergeBalance merge balance
func (*Chain33) NetProtocols ¶ added in v1.65.0
NetProtocols get net information
func (*Chain33) NewAccount ¶
func (c *Chain33) NewAccount(in *types.ReqNewAccount, result *interface{}) error
NewAccount new a account
func (*Chain33) NewRandAccount ¶ added in v1.65.3
func (c *Chain33) NewRandAccount(in *types.GenSeedLang, result *interface{}) error
NewRandAccount rand new a account
func (*Chain33) PubKeyToAddr ¶ added in v1.65.3
PubKeyToAddr pubkey to addr
func (*Chain33) Query ¶
func (c *Chain33) Query(in rpctypes.Query4Jrpc, result *interface{}) error
Query query
func (*Chain33) QueryChain ¶ added in v1.65.1
func (c *Chain33) QueryChain(in rpctypes.ChainExecutor, result *interface{}) error
QueryChain querychain by chain executor
func (*Chain33) QueryTotalFee ¶
func (c *Chain33) QueryTotalFee(in *types.LocalDBGet, result *interface{}) error
QueryTotalFee query total fee
func (*Chain33) QueryTransaction ¶
QueryTransaction query transaction
func (*Chain33) ReWriteRawTx ¶
func (c *Chain33) ReWriteRawTx(in *rpctypes.ReWriteRawTx, result *interface{}) error
ReWriteRawTx re-write raw tx by jrpc
func (*Chain33) SaveSeed ¶
func (c *Chain33) SaveSeed(in *types.SaveSeedByPw, result *interface{}) error
SaveSeed save seed
func (*Chain33) SendDelayTransaction ¶ added in v1.65.3
SendDelayTransaction send delay tx
func (*Chain33) SendToAddress ¶
func (c *Chain33) SendToAddress(in *types.ReqWalletSendToAddress, result *interface{}) error
SendToAddress send to address of coins
func (*Chain33) SendTransaction ¶
SendTransaction send transaction
func (*Chain33) SendTransactionSync ¶ added in v1.65.1
SendTransactionSync send transaction and wait reply
func (*Chain33) SendTransactions ¶ added in v1.65.3
func (c *Chain33) SendTransactions(in rpctypes.ReqStrings, result *interface{}) error
SendTransactions send tx batch
func (*Chain33) SetLabl ¶
func (c *Chain33) SetLabl(in *types.ReqWalletSetLabel, result *interface{}) error
SetLabl set lable
func (*Chain33) SetPasswd ¶
func (c *Chain33) SetPasswd(in *types.ReqWalletSetPasswd, result *interface{}) error
SetPasswd set password
func (*Chain33) SetTxFee ¶
func (c *Chain33) SetTxFee(in *types.ReqWalletSetFee, result *interface{}) error
SetTxFee set tx fee
func (*Chain33) ShowBlacklist ¶ added in v1.65.3
ShowBlacklist show all peers from blacklist
func (*Chain33) SignRawTx ¶
func (c *Chain33) SignRawTx(in *types.ReqSignRawTx, result *interface{}) error
SignRawTx signature the rawtransaction
func (*Chain33) SignWalletRecoverTx ¶ added in v1.65.3
func (c *Chain33) SignWalletRecoverTx(req *types.ReqSignWalletRecoverTx, result *interface{}) error
SignWalletRecoverTx sign wallet recover transaction
func (*Chain33) UnLock ¶
func (c *Chain33) UnLock(in *types.WalletUnLock, result *interface{}) error
UnLock wallet unlock
func (*Chain33) WalletTxList ¶
func (c *Chain33) 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 ¶ added in v1.66.1
func (g *Grpc) AddPushSubscribe(ctx context.Context, in *pb.PushSubscribeReq) (*pb.ReplySubscribePush, error)
AddPushSubscribe ...
func (*Grpc) CloseQueue ¶
CloseQueue close queue
func (*Grpc) ConvertExectoAddr ¶ added in v1.66.1
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 ¶ added in v1.65.0
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 ¶ added in v1.67.1
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 ¶ added in v1.66.1
GetBlockSequences ...
func (*Grpc) GetChainConfig ¶ added in v1.65.3
GetChainConfig 获取chain config 参数
func (*Grpc) GetCoinSymbol ¶ added in v1.66.1
GetCoinSymbol get coin symbol
func (*Grpc) GetCryptoList ¶ added in v1.65.3
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 ¶ added in v1.66.1
GetPushSeqLastNum Get Seq Call Back Last Num
func (*Grpc) GetSequenceByHash ¶
GetSequenceByHash get block sequece by hash
func (*Grpc) GetServerTime ¶ added in v1.65.1
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 ¶ added in v1.65.3
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 ¶ added in v1.66.1
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 ¶ added in v1.65.3
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 ¶ added in v1.65.1
SendTransactionSync send transaction by network and query
func (*Grpc) SendTransactions ¶ added in v1.65.3
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 ¶ added in v1.65.3
func (g *Grpc) SignWalletRecoverTx(ctx context.Context, in *pb.ReqSignWalletRecoverTx) (*pb.ReplySignRawTx, error)
SignWalletRecoverTx sign wallet recover tx
func (*Grpc) SubEvent ¶ added in v1.66.1
func (g *Grpc) SubEvent(in *pb.ReqSubscribe, resp pb.Chain33_SubEventServer) error
SubEvent 订阅消息推送服务
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
Directories ¶
Path | Synopsis |
---|---|
Package jsonclient 实现JSON rpc客户端请求功能
|
Package jsonclient 实现JSON rpc客户端请求功能 |
Package types rpc相关的一些结构体定义以及转化函数
|
Package types rpc相关的一些结构体定义以及转化函数 |