Documentation ¶
Overview ¶
in api interface, you can add comment tags to the function Note: Rule[perm:admin,ignore:true] perm: read,write,sign,admin jwt token permission check ignore: bool the func in the api whether needs to be added to the client for external exposure
TODO: 1. Support global FUNC injection
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FullNode ¶
type FullNode interface { IBlockService IBlockStore IChain IConfig IDiscovery IMarket IMining IMessagePool IMultiSig INetwork IPaychan ISyncer IWallet IJwtAuthAPI }
type IBeacon ¶
type IBeacon interface { // Rule[perm:read] BeaconGetEntry(ctx context.Context, epoch abi.ChainEpoch) (*types.BeaconEntry, error) }
type IBlockService ¶
type IBlockService interface { // Rule[perm:read] DAGGetNode(ctx context.Context, ref string) (interface{}, error) // Rule[perm:read] DAGGetFileSize(ctx context.Context, c cid.Cid) (uint64, error) // Rule[perm:read] DAGCat(ctx context.Context, c cid.Cid) (io.Reader, error) // Rule[perm:read] DAGImportData(ctx context.Context, data io.Reader) (ipld.Node, error) }
type IBlockStore ¶
type IBlockStore interface { // Rule[perm:read] ChainReadObj(ctx context.Context, ocid cid.Cid) ([]byte, error) // Rule[perm:read] ChainDeleteObj(ctx context.Context, obj cid.Cid) error // Rule[perm:read] ChainHasObj(ctx context.Context, obj cid.Cid) (bool, error) // Rule[perm:read] ChainStatObj(ctx context.Context, obj cid.Cid, base cid.Cid) (apitypes.ObjStat, error) }
type IChain ¶
type IChain interface { IAccount IActor IBeacon IMinerState IChainInfo }
type IChainInfo ¶
type IChainInfo interface { // Rule[perm:read] BlockTime(ctx context.Context) time.Duration // Rule[perm:read] ChainList(ctx context.Context, tsKey types.TipSetKey, count int) ([]types.TipSetKey, error) // Rule[perm:read] ChainHead(ctx context.Context) (*types.TipSet, error) // Rule[perm:read] ChainSetHead(ctx context.Context, key types.TipSetKey) error // Rule[perm:read] ChainGetTipSet(ctx context.Context, key types.TipSetKey) (*types.TipSet, error) // Rule[perm:read] ChainGetTipSetByHeight(ctx context.Context, height abi.ChainEpoch, tsk types.TipSetKey) (*types.TipSet, error) // Rule[perm:read] ChainGetRandomnessFromBeacon(ctx context.Context, key types.TipSetKey, personalization acrypto.DomainSeparationTag, randEpoch abi.ChainEpoch, entropy []byte) (abi.Randomness, error) // Rule[perm:read] ChainGetRandomnessFromTickets(ctx context.Context, tsk types.TipSetKey, personalization acrypto.DomainSeparationTag, randEpoch abi.ChainEpoch, entropy []byte) (abi.Randomness, error) // Rule[perm:read] ChainGetBlock(ctx context.Context, id cid.Cid) (*types.BlockHeader, error) // Rule[perm:read] ChainGetMessage(ctx context.Context, msgID cid.Cid) (*types.UnsignedMessage, error) // Rule[perm:read] ChainGetBlockMessages(ctx context.Context, bid cid.Cid) (*apitypes.BlockMessages, error) // Rule[perm:read] ChainGetReceipts(ctx context.Context, id cid.Cid) ([]types.MessageReceipt, error) // Rule[perm:read] ChainGetParentMessages(ctx context.Context, bcid cid.Cid) ([]apitypes.Message, error) // Rule[perm:read] ChainGetParentReceipts(ctx context.Context, bcid cid.Cid) ([]*types.MessageReceipt, error) // Rule[perm:read] ChainNotify(ctx context.Context) chan []*chain.HeadChange // Rule[perm:read] GetFullBlock(ctx context.Context, id cid.Cid) (*types.FullBlock, error) // Rule[perm:read] GetActor(ctx context.Context, addr address.Address) (*types.Actor, error) // Rule[perm:read] GetParentStateRootActor(ctx context.Context, ts *types.TipSet, addr address.Address) (*types.Actor, error) // Rule[perm:read] GetEntry(ctx context.Context, height abi.ChainEpoch, round uint64) (*types.BeaconEntry, error) // Rule[perm:read] MessageWait(ctx context.Context, msgCid cid.Cid, confidence, lookback abi.ChainEpoch) (*chain.ChainMessage, error) // Rule[perm:read] ProtocolParameters(ctx context.Context) (*apitypes.ProtocolParams, error) // Rule[perm:read] ResolveToKeyAddr(ctx context.Context, addr address.Address, ts *types.TipSet) (address.Address, error) // Rule[perm:read] StateNetworkName(ctx context.Context) (apitypes.NetworkName, error) // StateSearchMsg looks back up to limit epochs in the chain for a message, and returns its receipt and the tipset where it was executed // // NOTE: If a replacing message is found on chain, this method will return // a MsgLookup for the replacing message - the MsgLookup.Message will be a different // CID than the one provided in the 'cid' param, MsgLookup.Receipt will contain the // result of the execution of the replacing message. // // If the caller wants to ensure that exactly the requested message was executed, // they must check that MsgLookup.Message is equal to the provided 'cid', or set the // `allowReplaced` parameter to false. Without this check, and with `allowReplaced` // set to true, both the requested and original message may appear as // successfully executed on-chain, which may look like a double-spend. // // A replacing message is a message with a different CID, any of Gas values, and // different signature, but with all other parameters matching (source/destination, // nonce, params, etc.) // Rule[perm:read] StateSearchMsg(ctx context.Context, from types.TipSetKey, msg cid.Cid, limit abi.ChainEpoch, allowReplaced bool) (*apitypes.MsgLookup, error) // StateWaitMsg looks back up to limit epochs in the chain for a message. // If not found, it blocks until the message arrives on chain, and gets to the // indicated confidence depth. // // NOTE: If a replacing message is found on chain, this method will return // a MsgLookup for the replacing message - the MsgLookup.Message will be a different // CID than the one provided in the 'cid' param, MsgLookup.Receipt will contain the // result of the execution of the replacing message. // // If the caller wants to ensure that exactly the requested message was executed, // they must check that MsgLookup.Message is equal to the provided 'cid', or set the // `allowReplaced` parameter to false. Without this check, and with `allowReplaced` // set to true, both the requested and original message may appear as // successfully executed on-chain, which may look like a double-spend. // // A replacing message is a message with a different CID, any of Gas values, and // different signature, but with all other parameters matching (source/destination, // nonce, params, etc.) // Rule[perm:read] StateWaitMsg(ctx context.Context, cid cid.Cid, confidence uint64, limit abi.ChainEpoch, allowReplaced bool) (*apitypes.MsgLookup, error) // Rule[perm:read] StateNetworkVersion(ctx context.Context, tsk types.TipSetKey) (network.Version, error) // Rule[perm:read] VerifyEntry(parent, child *types.BeaconEntry, height abi.ChainEpoch) bool }
type IDiscovery ¶
type IDiscovery interface { }
type IJwtAuthAPI ¶
type IMessagePool ¶
type IMessagePool interface { // Rule[perm:read] MpoolDeleteByAdress(ctx context.Context, addr address.Address) error // Rule[perm:read] MpoolPublishByAddr(context.Context, address.Address) error // Rule[perm:read] MpoolPublishMessage(ctx context.Context, smsg *types.SignedMessage) error // Rule[perm:read] MpoolPush(ctx context.Context, smsg *types.SignedMessage) (cid.Cid, error) // Rule[perm:read] MpoolGetConfig(context.Context) (*messagepool.MpoolConfig, error) // Rule[perm:read] MpoolSetConfig(ctx context.Context, cfg *messagepool.MpoolConfig) error // Rule[perm:read] MpoolSelect(context.Context, types.TipSetKey, float64) ([]*types.SignedMessage, error) // Rule[perm:read] MpoolSelects(context.Context, types.TipSetKey, []float64) ([][]*types.SignedMessage, error) // Rule[perm:read] MpoolPending(ctx context.Context, tsk types.TipSetKey) ([]*types.SignedMessage, error) // Rule[perm:read] MpoolClear(ctx context.Context, local bool) error // Rule[perm:read] MpoolPushUntrusted(ctx context.Context, smsg *types.SignedMessage) (cid.Cid, error) // Rule[perm:read] MpoolPushMessage(ctx context.Context, msg *types.UnsignedMessage, spec *types.MessageSendSpec) (*types.SignedMessage, error) // Rule[perm:read] MpoolBatchPush(ctx context.Context, smsgs []*types.SignedMessage) ([]cid.Cid, error) // Rule[perm:read] MpoolBatchPushUntrusted(ctx context.Context, smsgs []*types.SignedMessage) ([]cid.Cid, error) // Rule[perm:read] MpoolBatchPushMessage(ctx context.Context, msgs []*types.UnsignedMessage, spec *types.MessageSendSpec) ([]*types.SignedMessage, error) // Rule[perm:read] MpoolGetNonce(ctx context.Context, addr address.Address) (uint64, error) // Rule[perm:read] MpoolSub(ctx context.Context) (<-chan messagepool.MpoolUpdate, error) // Rule[perm:read] GasEstimateMessageGas(ctx context.Context, msg *types.UnsignedMessage, spec *types.MessageSendSpec, tsk types.TipSetKey) (*types.UnsignedMessage, error) // Rule[perm:read] GasBatchEstimateMessageGas(ctx context.Context, estimateMessages []*types.EstimateMessage, fromNonce uint64, tsk types.TipSetKey) ([]*types.EstimateResult, error) // Rule[perm:read] GasEstimateFeeCap(ctx context.Context, msg *types.UnsignedMessage, maxqueueblks int64, tsk types.TipSetKey) (big.Int, error) // Rule[perm:read] GasEstimateGasPremium(ctx context.Context, nblocksincl uint64, sender address.Address, gaslimit int64, tsk types.TipSetKey) (big.Int, error) // Rule[perm:read] GasEstimateGasLimit(ctx context.Context, msgIn *types.UnsignedMessage, tsk types.TipSetKey) (int64, error) // MpoolCheckMessages performs logical checks on a batch of messages // Rule[perm:read] MpoolCheckMessages(ctx context.Context, protos []*apitypes.MessagePrototype) ([][]apitypes.MessageCheckStatus, error) // MpoolCheckPendingMessages performs logical checks for all pending messages from a given address // Rule[perm:read] MpoolCheckPendingMessages(ctx context.Context, addr address.Address) ([][]apitypes.MessageCheckStatus, error) // MpoolCheckReplaceMessages performs logical checks on pending messages with replacement // Rule[perm:read] MpoolCheckReplaceMessages(ctx context.Context, msg []*types.Message) ([][]apitypes.MessageCheckStatus, error) }
type IMinerState ¶
type IMinerState interface { // Rule[perm:read] StateMinerSectorAllocated(ctx context.Context, maddr address.Address, s abi.SectorNumber, tsk types.TipSetKey) (bool, error) // Rule[perm:read] StateSectorPreCommitInfo(ctx context.Context, maddr address.Address, n abi.SectorNumber, tsk types.TipSetKey) (miner.SectorPreCommitOnChainInfo, error) // Rule[perm:read] StateSectorGetInfo(ctx context.Context, maddr address.Address, n abi.SectorNumber, tsk types.TipSetKey) (*miner.SectorOnChainInfo, error) // Rule[perm:read] StateSectorPartition(ctx context.Context, maddr address.Address, sectorNumber abi.SectorNumber, tsk types.TipSetKey) (*miner.SectorLocation, error) // Rule[perm:read] StateMinerSectorSize(ctx context.Context, maddr address.Address, tsk types.TipSetKey) (abi.SectorSize, error) // Rule[perm:read] StateMinerInfo(ctx context.Context, maddr address.Address, tsk types.TipSetKey) (miner.MinerInfo, error) // Rule[perm:read] StateMinerWorkerAddress(ctx context.Context, maddr address.Address, tsk types.TipSetKey) (address.Address, error) // Rule[perm:read] StateMinerRecoveries(ctx context.Context, maddr address.Address, tsk types.TipSetKey) (bitfield.BitField, error) // Rule[perm:read] StateMinerFaults(ctx context.Context, maddr address.Address, tsk types.TipSetKey) (bitfield.BitField, error) // Rule[perm:read] StateMinerProvingDeadline(ctx context.Context, maddr address.Address, tsk types.TipSetKey) (*dline.Info, error) // Rule[perm:read] StateMinerPartitions(ctx context.Context, maddr address.Address, dlIdx uint64, tsk types.TipSetKey) ([]apitypes.Partition, error) // Rule[perm:read] StateMinerDeadlines(ctx context.Context, maddr address.Address, tsk types.TipSetKey) ([]apitypes.Deadline, error) // Rule[perm:read] StateMinerSectors(ctx context.Context, maddr address.Address, sectorNos *bitfield.BitField, tsk types.TipSetKey) ([]*miner.SectorOnChainInfo, error) // Rule[perm:read] StateMarketStorageDeal(ctx context.Context, dealID abi.DealID, tsk types.TipSetKey) (*apitypes.MarketDeal, error) // Rule[perm:read] StateMinerPreCommitDepositForPower(ctx context.Context, maddr address.Address, pci miner.SectorPreCommitInfo, tsk types.TipSetKey) (big.Int, error) // Rule[perm:read] StateMinerInitialPledgeCollateral(ctx context.Context, maddr address.Address, pci miner.SectorPreCommitInfo, tsk types.TipSetKey) (big.Int, error) // Rule[perm:read] StateVMCirculatingSupplyInternal(ctx context.Context, tsk types.TipSetKey) (chain.CirculatingSupply, error) // Rule[perm:read] StateCirculatingSupply(ctx context.Context, tsk types.TipSetKey) (abi.TokenAmount, error) // Rule[perm:read] StateMarketDeals(ctx context.Context, tsk types.TipSetKey) (map[string]pstate.MarketDeal, error) // Rule[perm:read] StateMinerActiveSectors(ctx context.Context, maddr address.Address, tsk types.TipSetKey) ([]*miner.SectorOnChainInfo, error) // Rule[perm:read] StateLookupID(ctx context.Context, addr address.Address, tsk types.TipSetKey) (address.Address, error) // Rule[perm:read] StateListMiners(ctx context.Context, tsk types.TipSetKey) ([]address.Address, error) // Rule[perm:read] StateListActors(ctx context.Context, tsk types.TipSetKey) ([]address.Address, error) // Rule[perm:read] StateMinerPower(ctx context.Context, addr address.Address, tsk types.TipSetKey) (*apitypes.MinerPower, error) // Rule[perm:read] StateMinerAvailableBalance(ctx context.Context, maddr address.Address, tsk types.TipSetKey) (big.Int, error) // Rule[perm:read] StateSectorExpiration(ctx context.Context, maddr address.Address, sectorNumber abi.SectorNumber, tsk types.TipSetKey) (*miner.SectorExpiration, error) // Rule[perm:read] StateMinerSectorCount(ctx context.Context, addr address.Address, tsk types.TipSetKey) (apitypes.MinerSectors, error) // Rule[perm:read] StateMarketBalance(ctx context.Context, addr address.Address, tsk types.TipSetKey) (apitypes.MarketBalance, error) }
type IMultiSig ¶
type IMultiSig interface { // Rule[perm:read] MsigCreate(ctx context.Context, req uint64, addrs []address.Address, duration abi.ChainEpoch, val types.BigInt, src address.Address, gp types.BigInt) (*apitypes.MessagePrototype, error) // Rule[perm:read] MsigPropose(ctx context.Context, msig address.Address, to address.Address, amt types.BigInt, src address.Address, method uint64, params []byte) (*apitypes.MessagePrototype, error) // Rule[perm:read] MsigAddPropose(ctx context.Context, msig address.Address, src address.Address, newAdd address.Address, inc bool) (*apitypes.MessagePrototype, error) // Rule[perm:read] MsigAddApprove(ctx context.Context, msig address.Address, src address.Address, txID uint64, proposer address.Address, newAdd address.Address, inc bool) (*apitypes.MessagePrototype, error) // Rule[perm:read] MsigAddCancel(ctx context.Context, msig address.Address, src address.Address, txID uint64, newAdd address.Address, inc bool) (*apitypes.MessagePrototype, error) // Rule[perm:read] MsigSwapPropose(ctx context.Context, msig address.Address, src address.Address, oldAdd address.Address, newAdd address.Address) (*apitypes.MessagePrototype, error) // Rule[perm:read] MsigSwapApprove(ctx context.Context, msig address.Address, src address.Address, txID uint64, proposer address.Address, oldAdd address.Address, newAdd address.Address) (*apitypes.MessagePrototype, error) // Rule[perm:read] MsigSwapCancel(ctx context.Context, msig address.Address, src address.Address, txID uint64, oldAdd address.Address, newAdd address.Address) (*apitypes.MessagePrototype, error) // Rule[perm:read] MsigApprove(ctx context.Context, msig address.Address, txID uint64, src address.Address) (*apitypes.MessagePrototype, error) // Rule[perm:read] MsigApproveTxnHash(ctx context.Context, msig address.Address, txID uint64, proposer address.Address, to address.Address, amt types.BigInt, src address.Address, method uint64, params []byte) (*apitypes.MessagePrototype, error) // Rule[perm:read] MsigCancel(ctx context.Context, msig address.Address, txID uint64, to address.Address, amt types.BigInt, src address.Address, method uint64, params []byte) (*apitypes.MessagePrototype, error) // Rule[perm:read] MsigRemoveSigner(ctx context.Context, msig address.Address, proposer address.Address, toRemove address.Address, decrease bool) (*apitypes.MessagePrototype, error) // Rule[perm:read] MsigGetVested(ctx context.Context, addr address.Address, start types.TipSetKey, end types.TipSetKey) (types.BigInt, error) }
type INetwork ¶
type INetwork interface { // Rule[perm:admin] NetworkGetBandwidthStats(ctx context.Context) metrics.Stats // Rule[perm:admin] NetworkGetPeerAddresses(ctx context.Context) []ma.Multiaddr // Rule[perm:admin] NetworkGetPeerID(ctx context.Context) peer.ID // Rule[perm:read] NetworkFindProvidersAsync(ctx context.Context, key cid.Cid, count int) <-chan peer.AddrInfo // Rule[perm:read] NetworkGetClosestPeers(ctx context.Context, key string) (<-chan peer.ID, error) // Rule[perm:read] NetworkFindPeer(ctx context.Context, peerID peer.ID) (peer.AddrInfo, error) // Rule[perm:read] NetworkConnect(ctx context.Context, addrs []string) (<-chan net.ConnectionResult, error) // Rule[perm:read] NetworkPeers(ctx context.Context, verbose, latency, streams bool) (*net.SwarmConnInfos, error) // Rule[perm:read] Version(context.Context) (apitypes.Version, error) // Rule[perm:read] NetAddrsListen(context.Context) (peer.AddrInfo, error) }
type IPaychan ¶
type IPaychan interface { // PaychGet creates a payment channel to a provider with a amount of FIL // @from: the payment channel sender // @to: the payment channel recipient // @amt: the deposits funds in the payment channel // Rule[perm:read] PaychGet(ctx context.Context, from, to address.Address, amt big.Int) (*apitypes.ChannelInfo, error) // PaychAvailableFunds get the status of an outbound payment channel // @pch: payment channel address // Rule[perm:read] PaychAvailableFunds(ctx context.Context, ch address.Address) (*apitypes.ChannelAvailableFunds, error) // PaychAvailableFundsByFromTo get the status of an outbound payment channel // @from: the payment channel sender // @to: he payment channel recipient // Rule[perm:read] PaychAvailableFundsByFromTo(ctx context.Context, from, to address.Address) (*apitypes.ChannelAvailableFunds, error) // PaychGetWaitReady waits until the create channel / add funds message with the sentinel // @sentinel: given message CID arrives. // @ch: the returned channel address can safely be used against the Manager methods. // Rule[perm:read] PaychGetWaitReady(ctx context.Context, sentinel cid.Cid) (address.Address, error) // PaychAllocateLane Allocate late creates a lane within a payment channel so that calls to // CreatePaymentVoucher will automatically make vouchers only for the difference in total // Rule[perm:read] PaychAllocateLane(ctx context.Context, ch address.Address) (uint64, error) // PaychNewPayment aggregate vouchers into a new lane // @from: the payment channel sender // @to: the payment channel recipient // @vouchers: the outstanding (non-redeemed) vouchers // Rule[perm:read] PaychNewPayment(ctx context.Context, from, to address.Address, vouchers []apitypes.VoucherSpec) (*apitypes.PaymentInfo, error) // PaychList list the addresses of all channels that have been created // Rule[perm:read] PaychList(ctx context.Context) ([]address.Address, error) // PaychStatus get the payment channel status // @pch: payment channel address // Rule[perm:read] PaychStatus(ctx context.Context, pch address.Address) (*types.PaychStatus, error) // PaychSettle update payment channel status to settle // After a settlement period (currently 12 hours) either party to the payment channel can call collect on chain // @pch: payment channel address // Rule[perm:read] PaychSettle(ctx context.Context, addr address.Address) (cid.Cid, error) // PaychCollect update payment channel status to collect // Collect sends the value of submitted vouchers to the channel recipient (the provider), // and refunds the remaining channel balance to the channel creator (the client). // @pch: payment channel address // Rule[perm:read] PaychCollect(ctx context.Context, addr address.Address) (cid.Cid, error) // PaychVoucherCheckValid checks if the given voucher is valid (is or could become spendable at some point). // If the channel is not in the store, fetches the channel from state (and checks that // the channel To address is owned by the wallet). // @pch: payment channel address // @sv: voucher // Rule[perm:read] PaychVoucherCheckValid(ctx context.Context, ch address.Address, sv *paych.SignedVoucher) error // PaychVoucherCheckSpendable checks if the given voucher is currently spendable // @pch: payment channel address // @sv: voucher // Rule[perm:read] PaychVoucherCheckSpendable(ctx context.Context, ch address.Address, sv *paych.SignedVoucher, secret []byte, proof []byte) (bool, error) // PaychVoucherAdd adds a voucher for an inbound channel. // If the channel is not in the store, fetches the channel from state (and checks that // the channel To address is owned by the wallet). // Rule[perm:read] PaychVoucherAdd(ctx context.Context, ch address.Address, sv *paych.SignedVoucher, proof []byte, minDelta big.Int) (big.Int, error) // PaychVoucherCreate creates a new signed voucher on the given payment channel // with the given lane and amount. The value passed in is exactly the value // that will be used to create the voucher, so if previous vouchers exist, the // actual additional value of this voucher will only be the difference between // the two. // If there are insufficient funds in the channel to create the voucher, // returns a nil voucher and the shortfall. // Rule[perm:read] PaychVoucherCreate(ctx context.Context, pch address.Address, amt big.Int, lane uint64) (*apitypes.VoucherCreateResult, error) // PaychVoucherList list vouchers in payment channel // @pch: payment channel address // Rule[perm:read] PaychVoucherList(ctx context.Context, pch address.Address) ([]*paych.SignedVoucher, error) // PaychVoucherSubmit Submit voucher to chain to update payment channel state // @pch: payment channel address // @sv: voucher in payment channel // Rule[perm:read] PaychVoucherSubmit(ctx context.Context, ch address.Address, sv *paych.SignedVoucher, secret []byte, proof []byte) (cid.Cid, error) }
type ISyncer ¶
type ISyncer interface { // Rule[perm:read] ChainSyncHandleNewTipSet(ctx context.Context, ci *types.ChainInfo) error // Rule[perm:read] SetConcurrent(ctx context.Context, concurrent int64) error // Rule[perm:read] SyncerTracker(ctx context.Context) *syncTypes.TargetTracker // Rule[perm:read] Concurrent(ctx context.Context) int64 // Rule[perm:read] ChainTipSetWeight(ctx context.Context, tsk types.TipSetKey) (big.Int, error) // Rule[perm:read] SyncSubmitBlock(ctx context.Context, blk *types.BlockMsg) error // Rule[perm:read] StateCall(ctx context.Context, msg *types.UnsignedMessage, tsk types.TipSetKey) (*apitypes.InvocResult, error) // Rule[perm:read] SyncState(ctx context.Context) (*apitypes.SyncState, error) }
type IWallet ¶
type IWallet interface { // Rule[perm:sign] WalletSign(ctx context.Context, k address.Address, msg []byte, meta wallet.MsgMeta) (*crypto.Signature, error) // Rule[perm:admin] WalletExport(addr address.Address, password string) (*crypto.KeyInfo, error) // Rule[perm:admin] WalletImport(key *crypto.KeyInfo) (address.Address, error) // Rule[perm:write] WalletHas(ctx context.Context, addr address.Address) (bool, error) // Rule[perm:write] WalletNewAddress(protocol address.Protocol) (address.Address, error) // Rule[perm:read] WalletBalance(ctx context.Context, addr address.Address) (abi.TokenAmount, error) //not exists in remote // Rule[perm:write] WalletDefaultAddress(ctx context.Context) (address.Address, error) //not exists in remote // Rule[perm:admin] WalletAddresses(ctx context.Context) []address.Address // Rule[perm:admin] WalletSetDefault(ctx context.Context, addr address.Address) error //not exists in remote // Rule[perm:sign] WalletSignMessage(ctx context.Context, k address.Address, msg *types.UnsignedMessage) (*types.SignedMessage, error) // Rule[perm:admin] LockWallet(ctx context.Context) error // Rule[perm:admin] UnLockWallet(ctx context.Context, password []byte) error // Rule[perm:admin] SetPassword(Context context.Context, password []byte) error // Rule[perm:admin] HasPassword(Context context.Context) bool // Rule[perm:admin] WalletState(Context context.Context) int }
Source Files ¶
Click to show internal directories.
Click to hide internal directories.