Package org.bitcoinj.base
Interface AddressParser
-
- All Known Implementing Classes:
DefaultAddressParser
public interface AddressParser
Interface for parsing and validating address strings.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interface
AddressParser.Strict
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Address
parseAddress(java.lang.String addressString, Network network)
Parse an address and validate for specified networkAddress
parseAddressAnyNetwork(java.lang.String addressString)
Parse an address that could be for any network
-
-
-
Method Detail
-
parseAddressAnyNetwork
Address parseAddressAnyNetwork(java.lang.String addressString) throws AddressFormatException
Parse an address that could be for any network- Parameters:
addressString
- string representation of address- Returns:
- A validated address object
- Throws:
AddressFormatException
- invalid address string
-
parseAddress
Address parseAddress(java.lang.String addressString, Network network) throws AddressFormatException
Parse an address and validate for specified network- Parameters:
addressString
- string representation of addressnetwork
- the network the address string must represent- Returns:
- A validated address object
- Throws:
AddressFormatException
- invalid address string or not valid for specified network
-
-