Addr class¶
Static methods¶
Class methods¶
-
addrStrHex()¶ Returns: A stringcontaining a Semux-address (without leading ‘0x’).Method to get a HEX representation of itself (aka Semux-address).Example:// Get address as str hex var addr_str_hex_rs = next_hd_addr.addrStrHex(); if (typeof addr_str_hex_rs.error != "undefined") { console.log(addr_str_hex_rs.error); } else { var addr_str_hex = addr_str_hex_rs.res; console.log("HEX address: " + "0x" + addr_str_hex); }
-
sign1(transaction)¶ Arguments: - transaction – An object of
Transaction()class.
Returns: An
objectofTransactionSign()class.Performs a signature of aTransaction()object.Example:var sign_rs = next_hd_addr.sign1(transaction); if (typeof sign_rs.error != "undefined") { console.log(sign_rs.error); } else { var sign = sign_rs.res; }
- transaction – An object of
-
nonce()¶ Returns: A stringcontaining the current Nonce (string representation of SINT64 - max value is 9,223,372,036,854,775,807).Method to get the current Nonce, which was set bysetNonce()method or was incremented byincNonce()method.