For each wallet you want to query the balance of, you will need to sync
the blockchain. You can batch-process a number of wallets at the same
time though, as you can add multiple wallets to PeerGroup.

Bitcoinj does not "download" the blockchain, at least it doesn't keep
enough information to query balances (UTXOs).



On 06/30/2017 02:36 PM, [email protected] wrote:
> I have a myWallet.dat file which has 3 BTC . I have created a program to
> listen changes in a directory (/opt/bitcoin/wallet) and i have used this
> listener program with my bitcoin project , What i want is that if i put
> myWallet.dat file in that directory i want it to synchronize with block
> chain and get actual balance from it. 
> 
> If i use *Wallet.loadFromFile("WALLET_LOCATION")* method to get wallet
> object of wallet file and add to block chain like this
> *abstractBlockChainObject.addWallet(wallet) , *Consider The block chain
> is 100% downloaded , So my question is if i add wallet object like this
> will it synchronize my wallet with block chain. 
> 
> -- 
> You received this message because you are subscribed to the Google
> Groups "bitcoinj" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to [email protected]
> <mailto:[email protected]>.
> For more options, visit https://groups.google.com/d/optout.


-- 
You received this message because you are subscribed to the Google Groups 
"bitcoinj" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to