Documentation
¶
Index ¶
- type VeChainChain
- func (v *VeChainChain) CompileTransaction(input *chain_abstraction.TransactionInput, signatures [][]byte, ...) ([]byte, error)
- func (v *VeChainChain) CreateAndSignTransaction(input interface{}, privateKey []byte) ([]byte, error)
- func (v *VeChainChain) CreateWalletWithPrivateKey(privateKey string) (*chain_abstraction.Wallet, error)
- func (v *VeChainChain) GetPreimageHash(input *chain_abstraction.TransactionInput) ([]byte, []byte, error)
- func (v *VeChainChain) GetPublicKeyFromPrivateKey(privateKey []byte) ([]byte, error)
- func (v *VeChainChain) GetTransactionHash(encodedTx []byte) (string, error)
- func (v *VeChainChain) PrepareTransaction(input interface{}) (*chain_abstraction.TransactionInput, error)
- func (v *VeChainChain) Sign(preimage []byte, privateKey []byte) ([]byte, error)
- func (v *VeChainChain) ValidateAddress(address string) bool
- func (v *VeChainChain) ValidateTransactionInput(input interface{}) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type VeChainChain ¶
type VeChainChain struct {
*chain_abstraction.BaseChain
}
VeChainChain implements the Chain interface for VeChain
func NewVeChainChain ¶
func NewVeChainChain() *VeChainChain
NewVeChainChain creates a new VeChain chain instance
func (*VeChainChain) CompileTransaction ¶
func (v *VeChainChain) CompileTransaction( input *chain_abstraction.TransactionInput, signatures [][]byte, publicKeys [][]byte, ) ([]byte, error)
CompileTransaction compiles a VeChain transaction with signatures
func (*VeChainChain) CreateAndSignTransaction ¶
func (v *VeChainChain) CreateAndSignTransaction(input interface{}, privateKey []byte) ([]byte, error)
CreateAndSignTransaction creates and signs a VeChain transaction
func (*VeChainChain) CreateWalletWithPrivateKey ¶
func (v *VeChainChain) CreateWalletWithPrivateKey(privateKey string) (*chain_abstraction.Wallet, error)
CreateWalletWithPrivateKey creates a VeChain wallet from private key
func (*VeChainChain) GetPreimageHash ¶
func (v *VeChainChain) GetPreimageHash(input *chain_abstraction.TransactionInput) ([]byte, []byte, error)
GetPreimageHash gets the preimage hash for VeChain transaction
func (*VeChainChain) GetPublicKeyFromPrivateKey ¶
func (v *VeChainChain) GetPublicKeyFromPrivateKey(privateKey []byte) ([]byte, error)
GetPublicKeyFromPrivateKey uses the BaseChain implementation
func (*VeChainChain) GetTransactionHash ¶
func (v *VeChainChain) GetTransactionHash(encodedTx []byte) (string, error)
GetTransactionHash gets the transaction hash
func (*VeChainChain) PrepareTransaction ¶
func (v *VeChainChain) PrepareTransaction(input interface{}) (*chain_abstraction.TransactionInput, error)
PrepareTransaction prepares a VeChain transaction for external signing
func (*VeChainChain) Sign ¶
func (v *VeChainChain) Sign(preimage []byte, privateKey []byte) ([]byte, error)
Sign signs a preimage with the given private key
func (*VeChainChain) ValidateAddress ¶
func (v *VeChainChain) ValidateAddress(address string) bool
ValidateAddress validates a VeChain address
func (*VeChainChain) ValidateTransactionInput ¶
func (v *VeChainChain) ValidateTransactionInput(input interface{}) error
ValidateTransactionInput validates VeChain transaction input