Class SingleKeyAccount
- Namespace
- Aptos
- Assembly
- Aptos.dll
public class SingleKeyAccount : Account
- Inheritance
-
SingleKeyAccount
- Inherited Members
Constructors
SingleKeyAccount(PrivateKey)
public SingleKeyAccount(PrivateKey privateKey)
Parameters
privateKey
PrivateKey
SingleKeyAccount(PrivateKey, AccountAddress?)
public SingleKeyAccount(PrivateKey privateKey, AccountAddress? address = null)
Parameters
privateKey
PrivateKeyaddress
AccountAddress
SingleKeyAccount(PrivateKey, byte[]?)
public SingleKeyAccount(PrivateKey privateKey, byte[]? address = null)
Parameters
privateKey
PrivateKeyaddress
byte[]
SingleKeyAccount(PrivateKey, string?)
public SingleKeyAccount(PrivateKey privateKey, string? address = null)
Parameters
privateKey
PrivateKeyaddress
string
Fields
PrivateKey
public readonly PrivateKey PrivateKey
Field Value
Properties
Address
Gets the address of the account.
public override AccountAddress Address { get; }
Property Value
PublicKey
public PublicKey PublicKey { get; }
Property Value
SigningScheme
Gets the signing scheme used by the account.
public override SigningScheme SigningScheme { get; }
Property Value
VerifyingKey
Gets the public key of the account.
public override IVerifyingKey VerifyingKey { get; }
Property Value
Methods
FromDerivationPath(PublicKeyVariant, string, string)
public static SingleKeyAccount FromDerivationPath(PublicKeyVariant scheme, string path, string mnemnoic)
Parameters
scheme
PublicKeyVariantpath
stringmnemnoic
string
Returns
Generate(PublicKeyVariant)
public static SingleKeyAccount Generate(PublicKeyVariant scheme = PublicKeyVariant.Ed25519)
Parameters
scheme
PublicKeyVariant
Returns
Sign(byte[])
Signs a message with the using the signer.
public override Signature Sign(byte[] message)
Parameters
message
byte[]The message to sign as a byte array.
Returns
- Signature
The signed message.
SignWithAuthenticator(byte[])
Signs a message and returns an authenticator for the account.
public override AccountAuthenticator SignWithAuthenticator(byte[] message)
Parameters
message
byte[]The message to sign as a byte array.
Returns
- AccountAuthenticator
The authenticator containing the signature.
VerifySignature(byte[], Signature)
public bool VerifySignature(byte[] message, Signature signature)
Parameters
Returns
VerifySignature(string, Signature)
public bool VerifySignature(string message, Signature signature)