Ixian SDK
IXICore.Address Class Reference

Ixian Wallet Address. This class holds a binary value of an Ixian Address and contains functions to encode that information to- or retrieve it from a bytestream. An address can be constructed either directly from address bytes or from a combination of public key and a 'nonce' value. More...

Public Member Functions

 Address ()
 
 Address (byte[] public_key_or_address, byte[] nonce=null, bool verify_checksum=true)
 Constructs an Ixian address with the given byte value or alternatively from the given public key using a nonce value. More...
 
override string ToString ()
 Converts a binary Address representation into it's textual (base58) form, which is used in the Json Api and various clients. More...
 

Static Public Member Functions

static bool validateChecksum (byte[] address)
 Validates that the given value is a valid Address by checking the embedded checksum. More...
 

Public Attributes

int version = 0
 Version of the Ixian Address. More...
 
byte [] address
 Byte value of the address. More...
 
byte [] nonce
 Address nonce value. Applicable only for v1 and above. More...
 

Detailed Description

Ixian Wallet Address. This class holds a binary value of an Ixian Address and contains functions to encode that information to- or retrieve it from a bytestream. An address can be constructed either directly from address bytes or from a combination of public key and a 'nonce' value.

All versions of addreses are supported and basic checksum verification is possible. It is recommended to always generate addresses in the latest format for best performance and security. Ixian addresses v1 and above are generated from the wallet's primary key using a 'nonce' value, allowing for fast and efficient generation of multiple addresses from the same keypair.

Definition at line 18 of file Address.cs.

Constructor & Destructor Documentation

◆ Address() [1/2]

IXICore.Address.Address ( )

Definition at line 37 of file Address.cs.

◆ Address() [2/2]

IXICore.Address.Address ( byte []  public_key_or_address,
byte []  nonce = null,
bool  verify_checksum = true 
)

Constructs an Ixian address with the given byte value or alternatively from the given public key using a nonce value.

The address can be constructed either directly from the address byte value, or indirectly via a public key and a nonce value. If the address bytes are given directly, the nonce value may be omitted.

Parameters
public_key_or_addressByte value of the address or of the wallet's public key. See Remarks.
nonceIf the value given for address bytes is a public key, this field is required to specify with actual address to generate.
verify_checksumIf true, the given address will be verified for the correct checksum.

Definition at line 53 of file Address.cs.

Member Function Documentation

◆ ToString()

override string IXICore.Address.ToString ( )

Converts a binary Address representation into it's textual (base58) form, which is used in the Json Api and various clients.

Returns
Textual representation of the wallet.

Definition at line 188 of file Address.cs.

◆ validateChecksum()

static bool IXICore.Address.validateChecksum ( byte []  address)
static

Validates that the given value is a valid Address by checking the embedded checksum.

This function accepts only the final address bytes, not a public key + nonce pair. If you are generating an Address from public key + nonce, the Address constructor will automatically embed the correct checksum, so testing it here would be pointless.

Parameters
addressBytes of an Ixian Address.
Returns
True, if the value is a valid Address.

Definition at line 202 of file Address.cs.

Member Data Documentation

◆ address

byte [] IXICore.Address.address

Byte value of the address.

It is not recommended to manipulate this directly, but the field is exposed because some DLT components rely on

Definition at line 30 of file Address.cs.

◆ nonce

byte [] IXICore.Address.nonce

Address nonce value. Applicable only for v1 and above.

Definition at line 34 of file Address.cs.

◆ version

int IXICore.Address.version = 0

Version of the Ixian Address.

Definition at line 23 of file Address.cs.


The documentation for this class was generated from the following file: