laksadart library

Classes

ABI
ABIObject
Account
Account instance with keystore encrypt/decrypt
AccountState
Address
BaseAccount
BaseContract
BaseProvider
BaseTransaction
BaseWallet<E>
Bech32
Bech32Codec
Bech32Decoder
Bech32Encoder
Bech32Validations
Generic validations for Bech32 standard.
Blockchain
ConfigItem
Contract
Contracts
DartRandom
Utility to use dart:math's Random class to generate numbers used by pointycastle.
DRBG<T>
Endpoint
ErrorMiddleware
HMAC
HttpProvider
IsolateFunction
KeyStore
Laksa
Messenger
Middleware
MiddlewarePair<R, S>
ReqMiddleware<I>
ResMiddleware<O>
RPCError
RPCErrorCode
RPCMethod
RPCMiddleWare
RPCRequest<T>
RPCRequestOptions
RPCRequestPayload<T>
RPCResponseBase
RPCResponseBody<R, E>
RPCResult
SchnorrSignature
SHA256
Signature
Signer
SuccessMiddleware
TestScilla
Transaction
TransactionFactory
TransactionSent
TxParams
Unit
UseMiddleware
Wallet
ZilAddress
extends the Address to Zillia Standard
ZilliqaConfig
ZilliqaModule<M, F>

Constants

bech32 → const Bech32Codec
const Bech32Codec()
charset → const List<String>
const ["q", "p", "z", "r", "y", "9", "x", "8", "g", "f", "2", "t", "v"…
generator → const List<int>
const [0x3b6a57b2, 0x26508e6d, 0x1ea119fa, 0x3d4233dd, 0x2a1462b3]
mil → const Duration
const Duration(milliseconds: 1)
separator → const String
"1"

Properties

ALG → List<int>
final
ALG_LEN → int
final
ALGO_IDENTIFIER → String
final
DefaultConfig ZilliqaConfig
read / write
ENT_LEN → int
final
HRP → String
final
params ECDomainParameters
final
PUBKEY_COMPRESSED_SIZE_BYTES → int
final
unitMap ↔ Map<Units, String>
read / write

Functions

asyncDecrypt(Map<String, dynamic> keyStore, String psw) → Future
asyncEncrypt(String prvKey, [ String psw, [ Map<String, dynamic> options ]) → Future
asyncGeneratePrivateKey() → Future
asyncGetAddressFromPrivateKey(String privateKey) → Future
asyncGetAddressFromPublicKey(String pubKey) → Future
asyncGetPubKeyFromPrivateKey(String privateKey) → Future
asyncSchnorrSign(String privateKey, Map<String, dynamic> txnDetails) → Future
bytesToHex(List<int> bytes, { bool include0x: false }) → String
Converts the bytes given as a list of integers into a hexadecimal representation. [...]
bytesToInt(List<int> bytes) → BigInt
Converts the bytes from that list (big endian) to a BigInt.
decrypt(Map<String, dynamic> keyStore, String passphrase) → Future<String>
encodeTransactionProto(Map<String, dynamic> tx) → Uint8List
encrypt(String privateKey, [ String passphrase, [ Map<String, dynamic> options ]) → Future<String>
fromBech32Address(String address) → String
fromQaFunc(BigInt qa, Units unit, { dynamic pad: false }) → String
generateNewPrivateKey(Random random) → BigInt
Generates a new private key using the random instance provided. Please make sure you're using a cryptographically secure generator.
generatePrivateKey() → String
getAddressFromPrivateKey(String privateKey) → String
address calculation with privateKey for Zilliqa
getAddressFromPublicKey(String publicKey) → String
address calculation with publicKey for zilliqa
getDerivedKey(String kdf, Map<String, dynamic> params) → _KeyDerivator
getDerivedKey by kdf type
getDRBG(List<int> msg) DRBG
getParamTypes(List<Map> list) → List<String>
getPubKeyFromPrivateKey(String privateKey) → String
publicKey calculation for Zilliqa
getPublic(BigInt private) → String
hash(BigInt q, List<int> pubkey List<int> msg) → BigInt
TODO: need to implementing this bool verifyPrivateKey(String privateKey) {}
hexToBytes(String hexStr) → List<int>
Converts the hexadecimal string, which can be prefixed with 0x, to a byte sequence.
hexToInt(String hex) → BigInt
Takes the hexadecimal input and creates a BigInt.
intToBytes(BigInt number, { int length }) → List<int>
big int to bytes
isAddress(String str) → bool
isBech32(String str) → bool
isByteString(String byStr, { int length }) → bool
isPrivateKey(String str) → bool
isPublicKey(String str) → bool
isSignature(String str) → bool
isUrl(String url) → bool
isValidChecksumAddress(String str) → bool
numberToBytes(dynamic number) → List<int>
Converts the given number, either a int or a BigInt to a list of bytes representing the same value.
numberToHexArray(int number int size) → List<String>
pack(int CHAIN_ID int rawVersion) → int
performRPC(String url, Map headers, Map<String, dynamic> request) → Future<RPCMiddleWare>
privateKeyToPublic(Uint8List privateKey) → String
Generates a public key for the given private key using the ecdsa curve which Ethereum uses.
randomBytes(int byteLength) → List<int>
randomHex(int hexLength) → String
SchnorrSign(String privateKey, Map<String, dynamic> txnDetails) → Map<String, dynamic>
setParamValues(List<Map> rawParams List<Map> newValues) → List<Map>
sign(List<int> msg List<int> privKey List<int> pubKey) SchnorrSignature
sleep({int ms, Function callback }) → Timer
strip0x(String hex) → String
If present, removes the 0x from the start of a hex-string.
toBech32Address(String address) → String
toChecksum(String address) → String
toHex(dynamic number, { bool pad: false, bool include0x: false, int forcePadLen }) → String
Converts the number, which can either be a dart int or a BigInt, into a hexadecimal representation. The number needs to be positive or zero. [...]
toQaFunc(String input, Units unit) → BigInt
toSignature(List<int> serialised) SchnorrSignature
trySign(List<int> msg BigInt k, BigInt privKey, List<int> pubKey) SchnorrSignature
unPack(int versioned int CHAIN_ID) → int
verify(List<int> msg BigInt sigR, BigInt sigS, List<int> key) → bool

Enums

AddressType
ContractStatus
MiddlewareType
TxStatus
Units

Typedefs

MiddleWareFn(List list) → dynamic
SignedTransaction(String privateKey, Map txnDetails) → Map<String, dynamic>
Transformer<I, O>(I payload) → O

Exceptions / Errors

InvalidAddress
InvalidChecksum
InvalidHrp
InvalidPadding
InvalidProgramLength
InvalidSeparator
InvalidWitnessVersion
MixedCase
OutOfBoundChars
OutOfRangeHrpCharacters
TooLong
TooShortChecksum
TooShortHrp