-
public class Synchronizer.Companion
-
-
Field Summary
Fields Modifier and Type Field Description public final static Synchronizer.CompanionINSTANCE
-
Method Summary
Modifier and Type Method Description final CloseableSynchronizernew(String alias, BlockHeight birthday, Context context, LightWalletEndpoint lightWalletEndpoint, AccountCreateSetup setup, WalletInitMode walletInitMode, ZcashNetwork zcashNetwork, Boolean isTorEnabled, Boolean isExchangeRateEnabled)Primary method that SDK clients will use to construct a synchronizer. final CloseableSynchronizernewBlocking(String alias, BlockHeight birthday, Context context, LightWalletEndpoint lightWalletEndpoint, AccountCreateSetup setup, WalletInitMode walletInitMode, ZcashNetwork zcashNetwork, Boolean isTorEnabled, Boolean isExchangeRateEnabled)Effectively the same as new although designed to be a blocking call with better interoperability with Java clients. final Booleanerase(Context appContext, ZcashNetwork network, String alias)Delete the databases associated with this wallet. -
-
Method Detail
-
new
final CloseableSynchronizer new(String alias, BlockHeight birthday, Context context, LightWalletEndpoint lightWalletEndpoint, AccountCreateSetup setup, WalletInitMode walletInitMode, ZcashNetwork zcashNetwork, Boolean isTorEnabled, Boolean isExchangeRateEnabled)
Primary method that SDK clients will use to construct a synchronizer.
- Parameters:
alias- A string used to segregate multiple wallets in the filesystem.birthday- Block height representing the "birthday" of the wallet.lightWalletEndpoint- Server endpoint.setup- An optional Account setup data that holds seed and other account related information.walletInitMode- a required parameter with one of WalletInitMode values.zcashNetwork- the network to use.
-
newBlocking
final CloseableSynchronizer newBlocking(String alias, BlockHeight birthday, Context context, LightWalletEndpoint lightWalletEndpoint, AccountCreateSetup setup, WalletInitMode walletInitMode, ZcashNetwork zcashNetwork, Boolean isTorEnabled, Boolean isExchangeRateEnabled)
Effectively the same as new although designed to be a blocking call with better interoperability with Java clients.
This is a blocking call, so it should not be called from the main thread.
-
erase
final Boolean erase(Context appContext, ZcashNetwork network, String alias)
Delete the databases associated with this wallet. This removes all compact blocks and data derived from those blocks. Although most data can be regenerated by setting up a new Synchronizer instance with the seed, there are two special cases where data is not retained:
Outputs created with a
nullOVKThe UA to which a transaction was sent (recovery from seed will only reveal the receiver, not the full UA)
- Parameters:
appContext- the application context.network- the network associated with the data to be erased.alias- the alias used to create the local data.
-
-
-
-