Documentation ¶
Index ¶
- Constants
- Variables
- func ByteArrayToString(byteArray []byte) string
- func BytesFromPublicKey(pub *ecdsa.PublicKey) []byte
- func ConvertScriptHashToAddressString(scriptHash string) (util.Uint160, string, error)
- func CreateTransactionFromFunctionCall(contractScriptHash string, operation string, network RPC_NETWORK, ...) (util.Uint256, *transaction.Transaction, error)
- func GasToken(cli client.Client) (util.Uint160, error)
- func GenerateEphemeralAccount() (*wallet.Account, error)
- func GenerateMultiSignWalletFromSigners()
- func GenerateNewSecureWallet(path, name, password string) (*wallet.Wallet, error)
- func GenerateNewWallet(path string) (*wallet.Wallet, error)
- func GetCredentialsFromPath(path, address, password string) (ecdsa.PrivateKey, error)
- func GetCredentialsFromWallet(address, password string, w *wallet.Wallet) (ecdsa.PrivateKey, error)
- func GetLogForTransaction(network RPC_NETWORK, transactionID util.Uint256) (*result.ApplicationLog, error)
- func GetNep17Balances(walletAddress string, network RPC_NETWORK) (map[string]Nep17Tokens, error)
- func GetPeers(ntwk RPC_NETWORK) ([]result.Peer, error)
- func GetWalletFromPrivateKey(key ecdsa.PrivateKey) *wallet.Account
- func PrettyPrint(data interface{}) (string, error)
- func PrivateKeyFromHexString(hexString string) (*ecdsa.PrivateKey, error)
- func RetrieveWallet(path string) (*wallet.Wallet, error)
- func StringToUint160(s string) (u util.Uint160, err error)
- func Uint160ToString(u util.Uint160) string
- func UnlockWallet(path, address, password string) (*wallet.Account, error)
- type Nep17Tokens
- type RPC_NETWORK
Constants ¶
View Source
const ( // NEO2Prefix is the first byte of address for NEO2. NEO2Prefix byte = 0x17 // NEO3Prefix is the first byte of address for NEO3. NEO3Prefix byte = 0x35 )
Variables ¶
View Source
var Prefix = NEO3Prefix
Prefix is the byte used to prepend to addresses when encoding them, it can be changed and defaults to 53 (0x35), the standard NEO prefix.
Functions ¶
func ByteArrayToString ¶
func BytesFromPublicKey ¶
func CreateTransactionFromFunctionCall ¶
func CreateTransactionFromFunctionCall(contractScriptHash string, operation string, network RPC_NETWORK, acc *wallet.Account, params []smartcontract.Parameter) (util.Uint256, *transaction.Transaction, error)
CreateTransactionFromFunctionCall creates a transaction to call a function on a smart contract) that still requires executing Before this is ready for sending Consider using https://pkg.go.dev/github.com/nspcc-dev/neo-go/pkg/rpc/client#Client.CreateTxFromScript as an alternative
func GenerateNewSecureWallet ¶
func GetCredentialsFromPath ¶
func GetCredentialsFromPath(path, address, password string) (ecdsa.PrivateKey, error)
func GetLogForTransaction ¶
func GetLogForTransaction(network RPC_NETWORK, transactionID util.Uint256) (*result.ApplicationLog, error)
func GetNep17Balances ¶
func GetNep17Balances(walletAddress string, network RPC_NETWORK) (map[string]Nep17Tokens, error)
func GetWalletFromPrivateKey ¶
func GetWalletFromPrivateKey(key ecdsa.PrivateKey) *wallet.Account
func PrettyPrint ¶
func PrivateKeyFromHexString ¶
func PrivateKeyFromHexString(hexString string) (*ecdsa.PrivateKey, error)
func StringToUint160 ¶
StringToUint160 attempts to decode the given NEO address string into an Uint160.
func Uint160ToString ¶
Uint160ToString returns the "NEO address" from the given Uint160.
Types ¶
type Nep17Tokens ¶
type RPC_NETWORK ¶
type RPC_NETWORK string
Click to show internal directories.
Click to hide internal directories.