|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.google.bitcoin.core.VersionedChecksummedBytes
com.google.bitcoin.core.Address
public class Address
A BitCoin address is fundamentally derived from an elliptic curve public key and a set of network parameters. It has several possible representations:
One may question whether the base58 form is really an improvement over the hash160 form, given they are both very unfriendly for typists. More useful representations might include qrcodes and identicons.
Note that an address is specific to a network because the first byte is a discriminator value.
Field Summary |
---|
Fields inherited from class com.google.bitcoin.core.VersionedChecksummedBytes |
---|
bytes, version |
Constructor Summary | |
---|---|
Address(NetworkParameters params,
byte[] hash160)
Construct an address from parameters and the hash160 form. |
|
Address(NetworkParameters params,
String address)
Construct an address from parameters and the standard "human readable" form. |
Method Summary | |
---|---|
byte[] |
getHash160()
The (big endian) 20 byte hash that is the core of a BitCoin address. |
Methods inherited from class com.google.bitcoin.core.VersionedChecksummedBytes |
---|
equals, getVersion, hashCode, toString |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Address(NetworkParameters params, byte[] hash160)
new Address(NetworkParameters.prodNet(), Hex.decode("4a22c3c4cbb31e4d03b15550636762bda0baf85a"));
public Address(NetworkParameters params, String address) throws AddressFormatException
new Address(NetworkParameters.prodNet(), "17kzeh4N8g49GFvdDzSf8PjaPfyoD1MndL");
AddressFormatException
Method Detail |
---|
public byte[] getHash160()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |