C# Class Paymetheus.Rpc.WalletClient

Inheritance: IDisposable
Show file Open project: decred/Paymetheus Class Usage Examples

Public Methods

Method Description
AccountsAsync ( ) : Task
CancelRequests ( ) : void
CloseWallet ( ) : Task
ConnectAsync ( string networkAddress, string rootCertificate ) : Task
CreateWallet ( string pubPassphrase, string privPassphrase, byte seed ) : Task
Disconnect ( ) : Task
DiscoverAccountsAsync ( string passphrase ) : Task
DiscoverAddressesAsync ( ) : Task
Dispose ( ) : void
FetchHeadersAsync ( ) : BlockIdentity?>>.Task
FundTransactionAsync ( Account account, Amount targetAmount, int requiredConfirmations ) : Amount>>.Task
GetTransactionsAsync ( int minRecentTransactions, int minRecentBlocks ) : Task
ImportPrivateKeyAsync ( Account account, string privateKeyWif, bool rescan, string passphrase ) : Task
ImportScriptAsync ( byte scriptBytes, bool rescan, int scanFrom, string passphrase ) : Task
Initialize ( ) : void
LoadActiveDataFiltersAsync ( ) : Task
NetworkAsync ( ) : Task
NextAccountAsync ( string passphrase, string accountName ) : Task
NextExternalAddressAsync ( Account account ) : string>>.Task

Queries the RPC server for the next external BIP0044 address for an account

NextInternalAddressAsync ( Account account ) : Task
OpenWallet ( string pubPassphrase ) : Task
PublishTransactionAsync ( byte signedTransaction ) : Task
PurchaseTicketsAsync ( Account account, Amount spendLimit, int reqConfs, Paymetheus.Decred.Wallet.Address ticketAddress, uint number, Paymetheus.Decred.Wallet.Address poolAddress, double poolFees, uint expiry, Amount txFee, Amount ticketFee, string passphrase ) : Task>
RenameAccountAsync ( Account account, string newAccountName ) : Task
RescanFromBlockHeightAsync ( int beginHeight, Action progressCallback = null ) : Task
SelectUnspentOutputs ( Account account, Amount targetAmount, int requiredConfirmations ) : Amount>>.Task
SignTransactionAsync ( string passphrase, Paymetheus.Decred.Transaction tx ) : bool>>.Task
StakeDifficultyAsync ( ) : Task
StakeInfoAsync ( ) : Task
StartConsensusRpc ( ConsensusServerRpcOptions options ) : Task
SubscribeToBlockNotificationsAsync ( ) : Task
Synchronize ( EventHandler walletEventHandler ) : Task>>.Task

Begins synchronization of the client with the remote wallet process. A delegate must be passed to be connected to the wallet's ChangesProcessed event to avoid a race where additional notifications are processed in the sync task before the caller can connect the event. The caller is responsible for disconnecting the delegate from the event handler when finished.

WalletExistsAsync ( ) : Task

Private Methods

Method Description
ReadFileAsync ( string filePath ) : Task
WalletClient ( Grpc.Core.Channel channel ) : Google.Protobuf

Method Details

AccountsAsync() public method

public AccountsAsync ( ) : Task
return Task

CancelRequests() public method

public CancelRequests ( ) : void
return void

CloseWallet() public method

public CloseWallet ( ) : Task
return Task

ConnectAsync() public static method

public static ConnectAsync ( string networkAddress, string rootCertificate ) : Task
networkAddress string
rootCertificate string
return Task

CreateWallet() public method

public CreateWallet ( string pubPassphrase, string privPassphrase, byte seed ) : Task
pubPassphrase string
privPassphrase string
seed byte
return Task

Disconnect() public method

public Disconnect ( ) : Task
return Task

DiscoverAccountsAsync() public method

public DiscoverAccountsAsync ( string passphrase ) : Task
passphrase string
return Task

DiscoverAddressesAsync() public method

public DiscoverAddressesAsync ( ) : Task
return Task

Dispose() public method

public Dispose ( ) : void
return void

FetchHeadersAsync() public method

public FetchHeadersAsync ( ) : BlockIdentity?>>.Task
return BlockIdentity?>>.Task

FundTransactionAsync() public method

public FundTransactionAsync ( Account account, Amount targetAmount, int requiredConfirmations ) : Amount>>.Task
account Account
targetAmount Paymetheus.Decred.Amount
requiredConfirmations int
return Amount>>.Task

GetTransactionsAsync() public method

public GetTransactionsAsync ( int minRecentTransactions, int minRecentBlocks ) : Task
minRecentTransactions int
minRecentBlocks int
return Task

ImportPrivateKeyAsync() public method

public ImportPrivateKeyAsync ( Account account, string privateKeyWif, bool rescan, string passphrase ) : Task
account Account
privateKeyWif string
rescan bool
passphrase string
return Task

ImportScriptAsync() public method

public ImportScriptAsync ( byte scriptBytes, bool rescan, int scanFrom, string passphrase ) : Task
scriptBytes byte
rescan bool
scanFrom int
passphrase string
return Task

Initialize() public static method

public static Initialize ( ) : void
return void

LoadActiveDataFiltersAsync() public method

public LoadActiveDataFiltersAsync ( ) : Task
return Task

NetworkAsync() public method

public NetworkAsync ( ) : Task
return Task

NextAccountAsync() public method

public NextAccountAsync ( string passphrase, string accountName ) : Task
passphrase string
accountName string
return Task

NextExternalAddressAsync() public method

Queries the RPC server for the next external BIP0044 address for an account
public NextExternalAddressAsync ( Account account ) : string>>.Task
account Account Account to create address for
return string>>.Task

NextInternalAddressAsync() public method

public NextInternalAddressAsync ( Account account ) : Task
account Account
return Task

OpenWallet() public method

public OpenWallet ( string pubPassphrase ) : Task
pubPassphrase string
return Task

PublishTransactionAsync() public method

public PublishTransactionAsync ( byte signedTransaction ) : Task
signedTransaction byte
return Task

PurchaseTicketsAsync() public method

public PurchaseTicketsAsync ( Account account, Amount spendLimit, int reqConfs, Paymetheus.Decred.Wallet.Address ticketAddress, uint number, Paymetheus.Decred.Wallet.Address poolAddress, double poolFees, uint expiry, Amount txFee, Amount ticketFee, string passphrase ) : Task>
account Account
spendLimit Paymetheus.Decred.Amount
reqConfs int
ticketAddress Paymetheus.Decred.Wallet.Address
number uint
poolAddress Paymetheus.Decred.Wallet.Address
poolFees double
expiry uint
txFee Paymetheus.Decred.Amount
ticketFee Paymetheus.Decred.Amount
passphrase string
return Task>

RenameAccountAsync() public method

public RenameAccountAsync ( Account account, string newAccountName ) : Task
account Account
newAccountName string
return Task

RescanFromBlockHeightAsync() public method

public RescanFromBlockHeightAsync ( int beginHeight, Action progressCallback = null ) : Task
beginHeight int
progressCallback Action
return Task

SelectUnspentOutputs() public method

public SelectUnspentOutputs ( Account account, Amount targetAmount, int requiredConfirmations ) : Amount>>.Task
account Account
targetAmount Paymetheus.Decred.Amount
requiredConfirmations int
return Amount>>.Task

SignTransactionAsync() public method

public SignTransactionAsync ( string passphrase, Paymetheus.Decred.Transaction tx ) : bool>>.Task
passphrase string
tx Paymetheus.Decred.Transaction
return bool>>.Task

StakeDifficultyAsync() public method

public StakeDifficultyAsync ( ) : Task
return Task

StakeInfoAsync() public method

public StakeInfoAsync ( ) : Task
return Task

StartConsensusRpc() public method

public StartConsensusRpc ( ConsensusServerRpcOptions options ) : Task
options ConsensusServerRpcOptions
return Task

SubscribeToBlockNotificationsAsync() public method

public SubscribeToBlockNotificationsAsync ( ) : Task
return Task

Synchronize() public method

Begins synchronization of the client with the remote wallet process. A delegate must be passed to be connected to the wallet's ChangesProcessed event to avoid a race where additional notifications are processed in the sync task before the caller can connect the event. The caller is responsible for disconnecting the delegate from the event handler when finished.
public Synchronize ( EventHandler walletEventHandler ) : Task>>.Task
walletEventHandler EventHandler Event handler for changes to wallet as new transactions are processed.
return Task>>.Task

WalletExistsAsync() public method

public WalletExistsAsync ( ) : Task
return Task