From ebfd7e4147d74f7e583883a08aae5ed91d70bc09 Mon Sep 17 00:00:00 2001 From: Mike Hearn Date: Thu, 24 Mar 2011 09:25:54 +0000 Subject: [PATCH] Refresh JavaDocs --- build.xml | 2 +- docs/allclasses-frame.html | 8 +- docs/allclasses-noframe.html | 8 +- docs/com/google/bitcoin/core/Address.html | 6 +- .../bitcoin/core/AddressFormatException.html | 6 +- .../google/bitcoin/core/AddressMessage.html | 8 +- docs/com/google/bitcoin/core/Base58.html | 6 +- docs/com/google/bitcoin/core/Block.html | 96 ++++++++--- docs/com/google/bitcoin/core/BlockChain.html | 132 +++++++++++++-- docs/com/google/bitcoin/core/ECKey.html | 10 +- .../google/bitcoin/core/GetBlocksMessage.html | 8 +- .../google/bitcoin/core/GetDataMessage.html | 8 +- .../bitcoin/core/InventoryItem.Type.html | 6 +- .../google/bitcoin/core/InventoryItem.html | 6 +- .../google/bitcoin/core/InventoryMessage.html | 8 +- docs/com/google/bitcoin/core/Message.html | 24 ++- .../bitcoin/core/NetworkConnection.html | 27 ++- .../bitcoin/core/NetworkParameters.html | 80 ++++++++- docs/com/google/bitcoin/core/Peer.html | 13 +- docs/com/google/bitcoin/core/PeerAddress.html | 18 +- .../bitcoin/core/ProtocolException.html | 6 +- docs/com/google/bitcoin/core/Script.html | 6 +- .../google/bitcoin/core/ScriptException.html | 6 +- .../bitcoin/core/Transaction.SigHash.html | 6 +- docs/com/google/bitcoin/core/Transaction.html | 45 ++++- .../google/bitcoin/core/TransactionInput.html | 8 +- .../bitcoin/core/TransactionOutPoint.html | 10 +- .../bitcoin/core/TransactionOutput.html | 8 +- .../google/bitcoin/core/UnknownMessage.html | 8 +- docs/com/google/bitcoin/core/Utils.html | 6 +- docs/com/google/bitcoin/core/VarInt.html | 6 +- .../bitcoin/core/VerificationException.html | 6 +- .../google/bitcoin/core/VersionMessage.html | 115 ++++++++++--- docs/com/google/bitcoin/core/Wallet.html | 30 ++-- .../bitcoin/core/WalletEventListener.html | 112 +++++++++++-- .../google/bitcoin/core/package-frame.html | 17 +- .../google/bitcoin/core/package-summary.html | 35 ++-- .../com/google/bitcoin/core/package-tree.html | 22 +-- .../google/bitcoin/examples/PrivateKeys.html | 5 +- .../bitcoin/examples/package-summary.html | 6 +- docs/constant-values.html | 34 ++-- docs/deprecated-list.html | 10 +- docs/help-doc.html | 16 +- docs/index-all.html | 123 ++++++++------ docs/index.html | 7 +- docs/overview-tree.html | 21 +-- docs/package-list | 1 - docs/serialized-form.html | 155 +++++++++++++++++- .../bitcoin/core/NetworkParameters.java | 16 +- .../google/bitcoin/examples/PrivateKeys.java | 6 +- 50 files changed, 923 insertions(+), 409 deletions(-) diff --git a/build.xml b/build.xml index 4797f4758..426d06101 100644 --- a/build.xml +++ b/build.xml @@ -16,7 +16,7 @@ diff --git a/docs/allclasses-frame.html b/docs/allclasses-frame.html index 0c8375b34..338026260 100644 --- a/docs/allclasses-frame.html +++ b/docs/allclasses-frame.html @@ -31,7 +31,7 @@ All Classes
BlockChain
-DumpWallet +BlockStoreException
ECKey
@@ -55,10 +55,6 @@ All Classes
PeerAddress
-PingService -
-PrivateKeys -
ProtocolException
Script @@ -87,7 +83,7 @@ All Classes
Wallet
-WalletEventListener +WalletEventListener
diff --git a/docs/allclasses-noframe.html b/docs/allclasses-noframe.html index 3e5dad0a6..26bcc38c9 100644 --- a/docs/allclasses-noframe.html +++ b/docs/allclasses-noframe.html @@ -31,7 +31,7 @@ All Classes
BlockChain
-DumpWallet +BlockStoreException
ECKey
@@ -55,10 +55,6 @@ All Classes
PeerAddress
-PingService -
-PrivateKeys -
ProtocolException
Script @@ -87,7 +83,7 @@ All Classes
Wallet
-WalletEventListener +WalletEventListener
diff --git a/docs/com/google/bitcoin/core/Address.html b/docs/com/google/bitcoin/core/Address.html index 15b4cdcc4..c112f7c11 100644 --- a/docs/com/google/bitcoin/core/Address.html +++ b/docs/com/google/bitcoin/core/Address.html @@ -35,8 +35,7 @@ function windowTitle() - - + @@ -312,8 +311,7 @@ public java.lang.String toString()
- - + diff --git a/docs/com/google/bitcoin/core/AddressFormatException.html b/docs/com/google/bitcoin/core/AddressFormatException.html index 8a6d39476..763cff115 100644 --- a/docs/com/google/bitcoin/core/AddressFormatException.html +++ b/docs/com/google/bitcoin/core/AddressFormatException.html @@ -35,8 +35,7 @@ function windowTitle()
- - + @@ -198,8 +197,7 @@ public AddressFormatException(java.lang.String message)
- - + diff --git a/docs/com/google/bitcoin/core/AddressMessage.html b/docs/com/google/bitcoin/core/AddressMessage.html index 32526c339..04f321fdb 100644 --- a/docs/com/google/bitcoin/core/AddressMessage.html +++ b/docs/com/google/bitcoin/core/AddressMessage.html @@ -35,8 +35,7 @@ function windowTitle()
- - + @@ -122,7 +121,7 @@ java.lang.Object - +
Fields inherited from class com.google.bitcoin.core.Message
bytes, cursor, MAX_SIZE, offset, paramsbytes, cursor, MAX_SIZE, offset, params, protocolVersion
  @@ -199,8 +198,7 @@ public java.lang.String toString() - - + diff --git a/docs/com/google/bitcoin/core/Base58.html b/docs/com/google/bitcoin/core/Base58.html index 093c5a1ae..841b66723 100644 --- a/docs/com/google/bitcoin/core/Base58.html +++ b/docs/com/google/bitcoin/core/Base58.html @@ -35,8 +35,7 @@ function windowTitle()
- - + @@ -249,8 +248,7 @@ public static java.math.BigInteger decodeToBigInteger(java.lang.String&nb
- - + diff --git a/docs/com/google/bitcoin/core/Block.html b/docs/com/google/bitcoin/core/Block.html index b33355dd7..80f80b829 100644 --- a/docs/com/google/bitcoin/core/Block.html +++ b/docs/com/google/bitcoin/core/Block.html @@ -35,8 +35,7 @@ function windowTitle()
- - + @@ -104,10 +103,10 @@ java.lang.Object

A block is the foundation of the BitCoin system. It records a set of Transactions together with some data that links it into a place in the global block chain, and proves that a difficult calculation was done - over its contents. See the BitCoin technical paper for more detail on blocks. + over its contents. See the BitCoin technical paper for more detail on blocks.

- To get a block, you can either build one from the raw bytes you can get from another implementation, or more likely - you grab it from a downloaded BlockChain. + To get a block, you can either build one from the raw bytes you can get from another implementation, + or request one specifically using Peer.getBlock(byte[]), or grab one from a downloaded BlockChain.

@@ -131,7 +130,7 @@ A block is the foundation of the BitCoin system. It records a set of Fields inherited from class com.google.bitcoin.core.Message

- +
bytes, cursor, MAX_SIZE, offset, paramsbytes, cursor, MAX_SIZE, offset, params, protocolVersion
  @@ -170,6 +169,14 @@ A block is the foundation of the BitCoin system. It records a set of + Block +cloneAsHeader() + +
+          Returns a copy of the block, but without any transactions. + + +  boolean equals(java.lang.Object o) @@ -187,7 +194,7 @@ A block is the foundation of the BitCoin system. It records a set of  java.math.BigInteger -getDifficultyTargetBI() +getDifficultyTargetAsInteger()
          Returns the difficulty target as a 256 bit value that can be compared to a SHA-256 hash. @@ -252,6 +259,14 @@ A block is the foundation of the BitCoin system. It records a set of + java.math.BigInteger +getWork() + +
+          Returns the work represented by this block. + + +  int hashCode() @@ -407,6 +422,39 @@ public byte[] getHash()
+

+getWork

+
+public java.math.BigInteger getWork()
+                             throws VerificationException
+
+
Returns the work represented by this block.

+ + Work is defined as the number of tries needed to solve a block in the average case. Consider a difficulty + target that covers 5% of all possible hash values. Then the work of the block will be 20. As the target gets + lower, the amount of work goes up. +

+

+ +
Throws: +
VerificationException
+
+
+
+ +

+cloneAsHeader

+
+public Block cloneAsHeader()
+
+
Returns a copy of the block, but without any transactions. +

+

+
+
+
+
+

toString

@@ -424,6 +472,24 @@ public java.lang.String toString()

+

+getDifficultyTargetAsInteger

+
+public java.math.BigInteger getDifficultyTargetAsInteger()
+                                                  throws VerificationException
+
+
Returns the difficulty target as a 256 bit value that can be compared to a SHA-256 hash. Inside a block the + target is represented using a compact form. If this form decodes to a value that is out of bounds, + an exception is thrown. +

+

+ +
Throws: +
VerificationException
+
+
+
+

verify

@@ -595,19 +661,6 @@ public long getDifficultyTarget()

-

-getDifficultyTargetBI

-
-public java.math.BigInteger getDifficultyTargetBI()
-
-
Returns the difficulty target as a 256 bit value that can be compared to a SHA-256 hash. -

-

-
-
-
-
-

setDifficultyTarget

@@ -655,8 +708,7 @@ public void setNonce(long nonce)
- - + diff --git a/docs/com/google/bitcoin/core/BlockChain.html b/docs/com/google/bitcoin/core/BlockChain.html index 6b1567e74..11e74e3f6 100644 --- a/docs/com/google/bitcoin/core/BlockChain.html +++ b/docs/com/google/bitcoin/core/BlockChain.html @@ -35,8 +35,7 @@ function windowTitle()
- - + @@ -53,7 +52,7 @@ function windowTitle() + NEXT CLASS + SUMMARY: NESTED | FIELD | CONSTR | METHOD +DETAIL: FIELD | CONSTR | METHOD
@@ -126,7 +125,48 @@ A BlockChain holds a series of + + + + + + + + + + + + + + + + + + + + +
+Field Summary
+protected  com.google.bitcoin.core.BlockStoreblockStore + +
+          Keeps a map of block hashes to StoredBlocks.
+protected  com.google.bitcoin.core.StoredBlockchainHead + +
+          Tracks the top of the best known chain.
+protected  NetworkParametersparams + +
+           
+protected  Walletwallet + +
+           
@@ -162,11 +202,11 @@ A BlockChain holds a series of - Block -getTopBlock() + com.google.bitcoin.core.StoredBlock +getChainHead()
-          Returns the highest known block or null if the chain is empty (top block is genesis). +          Returns the block at the head of the current best chain. @@ -189,6 +229,64 @@ A BlockChain holds a series of + + + + +
+Field Detail
+ +

+blockStore

+
+protected com.google.bitcoin.core.BlockStore blockStore
+
+
Keeps a map of block hashes to StoredBlocks. +

+

+
+
+
+ +

+chainHead

+
+protected com.google.bitcoin.core.StoredBlock chainHead
+
+
Tracks the top of the best known chain.

+ + Following this one down to the genesis block produces the story of the economy from the creation of BitCoin + until the present day. The chain head can change if a new set of blocks is received that results in a chain of + greater work than the one obtained by following this one down. In that case a reorganize is triggered, + potentially invalidating transactions in our wallet. +

+

+
+
+
+ +

+params

+
+protected final NetworkParameters params
+
+
+
+
+
+ +

+wallet

+
+protected final Wallet wallet
+
+
+
+
+ @@ -237,12 +335,13 @@ public boolean add(

-getTopBlock

+

+getChainHead

-public Block getTopBlock()
+public com.google.bitcoin.core.StoredBlock getChainHead()
-
Returns the highest known block or null if the chain is empty (top block is genesis). +
Returns the block at the head of the current best chain. This is the block which represents the greatest + amount of cumulative work done.

@@ -274,8 +373,7 @@ public - - + @@ -292,7 +390,7 @@ public  PREV CLASS  - NEXT CLASSNEXT CLASS + SUMMARY: NESTED | FIELD | CONSTR | METHOD +DETAIL: FIELD | CONSTR | METHOD
diff --git a/docs/com/google/bitcoin/core/ECKey.html b/docs/com/google/bitcoin/core/ECKey.html index 482476cf9..97f3c208d 100644 --- a/docs/com/google/bitcoin/core/ECKey.html +++ b/docs/com/google/bitcoin/core/ECKey.html @@ -35,8 +35,7 @@ function windowTitle() - - + @@ -52,7 +51,7 @@ function windowTitle() + + + + +          Calculates the sum of the outputs that are sending coins to a key in the wallet. - +
 java.math.BigIntegergetValueSentFromMe(Wallet wallet) + +
+          Calculates the sum of the inputs that are spending coins with keys in the wallet.
+ java.math.BigInteger getValueSentToMe(Wallet wallet)
-          Returns the sum of the outputs that are sending coins to a key in our wallet.
@@ -418,13 +425,36 @@ getValueSentToMe
 public java.math.BigInteger getValueSentToMe(Wallet wallet)
-
Returns the sum of the outputs that are sending coins to a key in our wallet. +
Calculates the sum of the outputs that are sending coins to a key in the wallet.

+ +
Returns:
sum in nanocoins
+
+
+ +

+getValueSentFromMe

+
+public java.math.BigInteger getValueSentFromMe(Wallet wallet)
+                                        throws ScriptException
+
+
Calculates the sum of the inputs that are spending coins with keys in the wallet. This requires the + transactions sending coins to those keys to be in the wallet. This method will not attempt to download the + blocks containing the input transactions if the key is in the wallet but the transactions are not. +

+

+
+
+
+ +
Returns:
sum in nanocoins. +
Throws: +
ScriptException

@@ -507,7 +537,7 @@ public void signInputs( - - + diff --git a/docs/com/google/bitcoin/core/TransactionInput.html b/docs/com/google/bitcoin/core/TransactionInput.html index 0497438b5..487009fd1 100644 --- a/docs/com/google/bitcoin/core/TransactionInput.html +++ b/docs/com/google/bitcoin/core/TransactionInput.html @@ -35,8 +35,7 @@ function windowTitle()
- - + @@ -137,7 +136,7 @@ A transfer of coins from one address to another creates a transaction in which t - +
Fields inherited from class com.google.bitcoin.core.Message
bytes, cursor, MAX_SIZE, offset, paramsbytes, cursor, MAX_SIZE, offset, params, protocolVersion
  @@ -385,8 +384,7 @@ public java.lang.String toString() - - + diff --git a/docs/com/google/bitcoin/core/TransactionOutPoint.html b/docs/com/google/bitcoin/core/TransactionOutPoint.html index 16eedfc26..4a6a992aa 100644 --- a/docs/com/google/bitcoin/core/TransactionOutPoint.html +++ b/docs/com/google/bitcoin/core/TransactionOutPoint.html @@ -35,8 +35,7 @@ function windowTitle()
- - + @@ -102,7 +101,7 @@ java.lang.Object

-This message is effectively a reference or pointer to a transaction output. +This message is a reference or pointer to an output of a different transaction.

@@ -126,7 +125,7 @@ This message is effectively a reference or pointer to a transaction output.

- +
Fields inherited from class com.google.bitcoin.core.Message
bytes, cursor, MAX_SIZE, offset, paramsbytes, cursor, MAX_SIZE, offset, params, protocolVersion
  @@ -253,8 +252,7 @@ public void bitcoinSerializeToStream(java.io.OutputStream stream) - - + diff --git a/docs/com/google/bitcoin/core/TransactionOutput.html b/docs/com/google/bitcoin/core/TransactionOutput.html index a89db60c7..0a60c4203 100644 --- a/docs/com/google/bitcoin/core/TransactionOutput.html +++ b/docs/com/google/bitcoin/core/TransactionOutput.html @@ -35,8 +35,7 @@ function windowTitle()
- - + @@ -127,7 +126,7 @@ A TransactionOutput message contains a scriptPubKey that controls who is able to - +
Fields inherited from class com.google.bitcoin.core.Message
bytes, cursor, MAX_SIZE, offset, paramsbytes, cursor, MAX_SIZE, offset, params, protocolVersion
  @@ -376,8 +375,7 @@ public java.lang.String toString() - - + diff --git a/docs/com/google/bitcoin/core/UnknownMessage.html b/docs/com/google/bitcoin/core/UnknownMessage.html index 3b95e8ba5..623b92838 100644 --- a/docs/com/google/bitcoin/core/UnknownMessage.html +++ b/docs/com/google/bitcoin/core/UnknownMessage.html @@ -35,8 +35,7 @@ function windowTitle()
- - + @@ -122,7 +121,7 @@ java.lang.Object - +
Fields inherited from class com.google.bitcoin.core.Message
bytes, cursor, MAX_SIZE, offset, paramsbytes, cursor, MAX_SIZE, offset, params, protocolVersion
  @@ -266,8 +265,7 @@ public void parse() - - + diff --git a/docs/com/google/bitcoin/core/Utils.html b/docs/com/google/bitcoin/core/Utils.html index 0a409098b..79b0ba885 100644 --- a/docs/com/google/bitcoin/core/Utils.html +++ b/docs/com/google/bitcoin/core/Utils.html @@ -35,8 +35,7 @@ function windowTitle()
- - + @@ -584,8 +583,7 @@ public static java.lang.String bitcoinValueToFriendlyString(java.math.Big
- - + diff --git a/docs/com/google/bitcoin/core/VarInt.html b/docs/com/google/bitcoin/core/VarInt.html index c5df59ce8..a9ff2f68d 100644 --- a/docs/com/google/bitcoin/core/VarInt.html +++ b/docs/com/google/bitcoin/core/VarInt.html @@ -35,8 +35,7 @@ function windowTitle()
- - + @@ -286,8 +285,7 @@ public byte[] encodeBE()
- - + diff --git a/docs/com/google/bitcoin/core/VerificationException.html b/docs/com/google/bitcoin/core/VerificationException.html index 21c6aa3ec..f532cd22b 100644 --- a/docs/com/google/bitcoin/core/VerificationException.html +++ b/docs/com/google/bitcoin/core/VerificationException.html @@ -35,8 +35,7 @@ function windowTitle()
- - + @@ -184,8 +183,7 @@ public VerificationException(java.lang.String msg)
- - + diff --git a/docs/com/google/bitcoin/core/VersionMessage.html b/docs/com/google/bitcoin/core/VersionMessage.html index b5b2e836a..2f0819ea6 100644 --- a/docs/com/google/bitcoin/core/VersionMessage.html +++ b/docs/com/google/bitcoin/core/VersionMessage.html @@ -35,8 +35,7 @@ function windowTitle()
- - + @@ -117,11 +116,19 @@ java.lang.Object + + + + +          The version number of the protocol spoken. +          Flags defining what is supported. + + + + - + +          An additional string that today the official client sets to the empty string. + PeerAddress + + + + +          What the other side believes the current time to be, in seconds.
+ longbestHeight + +
+          How many blocks are in the chain, according to the other side.
 int clientVersion
-           
@@ -129,7 +136,15 @@ java.lang.Object localServices
-           
+ PeerAddressmyAddr + +
+          What the other side believes the address of this program is.
@@ -141,19 +156,27 @@ java.lang.Object
-static intPROTOCOL_VERSION + java.lang.StringsubVer
-          The protocol version this library implements.
- java.math.BigIntegertheirAddr + +
+          What the other side believes their own address is.
+ long time
-           
  @@ -162,7 +185,7 @@ java.lang.Object
Fields inherited from class com.google.bitcoin.core.Message
bytes, cursor, MAX_SIZE, offset, paramsbytes, cursor, MAX_SIZE, offset, params, protocolVersion
  @@ -254,18 +277,6 @@ java.lang.Object -

-PROTOCOL_VERSION

-
-public static final int PROTOCOL_VERSION
-
-
The protocol version this library implements. A value of 31800 means 0.3.18.00. -

-

-
See Also:
Constant Field Values
-
-
-

NODE_NETWORK

@@ -283,6 +294,8 @@ clientVersion
 
 public int clientVersion
+
The version number of the protocol spoken. +

@@ -293,6 +306,8 @@ localServices
 public long localServices
+
Flags defining what is supported. Right now NODE_NETWORK is the only flag defined. +

@@ -301,8 +316,59 @@ public long localServices

time

-public java.math.BigInteger time
+public long time
+
What the other side believes the current time to be, in seconds. +

+

+
+
+
+ +

+myAddr

+
+public PeerAddress myAddr
+
+
What the other side believes the address of this program is. Not used. +

+

+
+
+
+ +

+theirAddr

+
+public PeerAddress theirAddr
+
+
What the other side believes their own address is. Not used. +

+

+
+
+
+ +

+subVer

+
+public java.lang.String subVer
+
+
An additional string that today the official client sets to the empty string. We treat it as something like an + HTTP User-Agent header. +

+

+
+
+
+ +

+bestHeight

+
+public long bestHeight
+
+
How many blocks are in the chain, according to the other side. +

@@ -410,8 +476,7 @@ public boolean hasBlockChain() - - + diff --git a/docs/com/google/bitcoin/core/Wallet.html b/docs/com/google/bitcoin/core/Wallet.html index 8f829383f..dd1e0855c 100644 --- a/docs/com/google/bitcoin/core/Wallet.html +++ b/docs/com/google/bitcoin/core/Wallet.html @@ -35,8 +35,7 @@ function windowTitle()
- - + @@ -53,7 +52,7 @@ function windowTitle() + NEXT CLASS +          A list of public/private EC keys owned by this user. +          A list of transactions with outputs we can spend.
keychain
-           
@@ -138,7 +137,7 @@ A Wallet stores keys and a record of transactions that have not yet been spent. unspent
-           
  @@ -169,7 +168,7 @@ A Wallet stores keys and a record of transactions that have not yet been spent.  void -addEventListener(WalletEventListener listener) +addEventListener(WalletEventListener listener)
          Adds an event listener object. @@ -269,6 +268,11 @@ unspent
 public final java.util.ArrayList<Transaction> unspent
+
A list of transactions with outputs we can spend. Note that some of these transactions may be partially spent, + that is, they have outputs some of which are redeemed and others which aren't already. The spentness of each + output is tracked in the TransactionOutput object. The value of all unspent outputs is the balance of the + wallet. +

@@ -279,6 +283,8 @@ keychain
 public final java.util.ArrayList<ECKey> keychain
+
A list of public/private EC keys owned by this user. +

@@ -372,7 +378,7 @@ public boolean isTransactionPresent(

addEventListener

-public void addEventListener(WalletEventListener listener)
+public void addEventListener(WalletEventListener listener)
Adds an event listener object. Methods on this object are called when something interesting happens, like receiving money.

@@ -434,13 +440,14 @@ findKeyFromPubHash public ECKey findKeyFromPubHash(byte[] pubkeyHash)

Locates a keypair from the keychain given the hash of the public key. This is needed when finding out which - key we need to use to redeem a transaction output. Returns null if no key was found. + key we need to use to redeem a transaction output.

-
+ +
Returns:
ECKey object or null if no such key was found.

@@ -486,8 +493,7 @@ public java.lang.String toString() - - + @@ -504,7 +510,7 @@ public java.lang.String toString() + NEXT CLASS + + + + +
+ voidonReorganize() + +
+          This is called on a Peer thread when a block is received that triggers a block chain re-organization.
+ + + + + + +
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

+ + + + + + + +
+Constructor Detail
+ +

+WalletEventListener

+
+public WalletEventListener()
+
+
+ @@ -138,20 +193,42 @@ Implementing WalletEventListener allows you to learn when a wallets balance has

onCoinsReceived

-void onCoinsReceived(Wallet wallet,
-                     Transaction tx,
-                     java.math.BigInteger prevBalance,
-                     java.math.BigInteger newBalance)
+public void onCoinsReceived(Wallet wallet, + Transaction tx, + java.math.BigInteger prevBalance, + java.math.BigInteger newBalance)
This is called on a Peer thread when a block is received that sends some coins to you. Note that this will - also be called when downloading the block chain as the wallet balance catches up, - so if you don't want that register the event listener after the chain is downloaded. It's safe to use methods - of wallet during the execution of this callback. + also be called when downloading the block chain as the wallet balance catches up so if you don't want that + register the event listener after the chain is downloaded. It's safe to use methods of wallet during the + execution of this callback.

Parameters:
wallet - The wallet object that received the coins/
tx - The transaction which sent us the coins.
prevBalance - Balance before the coins were received.
newBalance - Current balance of the wallet.
+
+ +

+onReorganize

+
+public void onReorganize()
+
+
This is called on a Peer thread when a block is received that triggers a block chain re-organization.

+ + A re-organize means that the consensus (chain) of the network has diverged and now changed from what we + believed it was previously. Usually this won't matter because the new consensus will include all our old + transactions assuming we are playing by the rules. However it's theoretically possible for our balance to + change in arbitrary ways, most likely, we could lose some money we thought we had.

+ + It is safe to use methods of wallet whilst inside this callback. + + TODO: Finish this interface. +

+

+
+
+

@@ -165,8 +242,7 @@ void onCoinsReceived( - - + @@ -203,9 +279,9 @@ void onCoinsReceived( - SUMMARY: NESTED | FIELD | CONSTR | METHOD + SUMMARY: NESTED | FIELD | CONSTR | METHOD +DETAIL: FIELD | CONSTR | METHOD
diff --git a/docs/com/google/bitcoin/core/package-frame.html b/docs/com/google/bitcoin/core/package-frame.html index 8c29a84ab..d81b79b13 100644 --- a/docs/com/google/bitcoin/core/package-frame.html +++ b/docs/com/google/bitcoin/core/package-frame.html @@ -15,17 +15,6 @@ com.google.bitcoin.core com.google.bitcoin.core - - - - -
-Interfaces  - -
-WalletEventListener
- - +Wallet +
+WalletEventListener
@@ -80,7 +69,9 @@ Classes 
VersionMessage
-Wallet
@@ -106,6 +97,8 @@ Exceptions
 
AddressFormatException
+BlockStoreException +
ProtocolException
ScriptException diff --git a/docs/com/google/bitcoin/core/package-summary.html b/docs/com/google/bitcoin/core/package-summary.html index aba8baae9..93420b770 100644 --- a/docs/com/google/bitcoin/core/package-summary.html +++ b/docs/com/google/bitcoin/core/package-summary.html @@ -35,8 +35,7 @@ function windowTitle() - - + @@ -53,7 +52,7 @@ function windowTitle() + NEXT PACKAGE + + + + @@ -265,8 +259,7 @@ Package com.google.bitcoin.core
 
BlockStoreExceptionThrown when something goes wrong with storing a block.
ProtocolException  
- - + @@ -283,7 +276,7 @@ Package com.google.bitcoin.core + NEXT PACKAGE