cli

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 1, 2020 License: GPL-3.0 Imports: 25 Imported by: 0

Documentation

Overview

Genesis block related commands for VM module.

Index

Constants

View Source
const (
	FlagOutput          = "to-file"
	FlagCompilerAddr    = "compiler"
	FlagCompilerDefault = "127.0.0.1:50053"
	FlagCompilerUsage   = "--compiler 127.0.0.1:50053"
)

Variables

This section is empty.

Functions

func Compile

func Compile(addr string, sourceFile *vm_grpc.MvIrSourceFile) ([]byte, error)

Compile script via grpc compiler.

func CompileModule

func CompileModule(cdc *codec.Codec) *cobra.Command

Compile Mvir module.

func CompileScript

func CompileScript(cdc *codec.Codec) *cobra.Command

Compile Mvir script.

func CreateConnection

func CreateConnection(addr string) (*grpc.ClientConn, error)

Create connection to vm.

func DeployContract

func DeployContract(cdc *codec.Codec) *cobra.Command

Deploy contract cli TX command.

func ExecuteScript

func ExecuteScript(cdc *codec.Codec) *cobra.Command

Execute script contract.

func ExtractArguments

func ExtractArguments(addr string, bytecode []byte) ([]vm_grpc.VMTypeTag, error)

Extract arguments from bytecode with compiler.

func GenesisWSFromFile

func GenesisWSFromFile(ctx *server.Context, cdc *codec.Codec) *cobra.Command

Reading genesis state from file generated by Move VM. File contains write set operations for standard libraries.

func GetData

func GetData(queryRoute string, cdc *codec.Codec) *cobra.Command

Get data from data source by access path.

func GetDenomHex

func GetDenomHex(cdc *codec.Codec) *cobra.Command

func GetQueriesCmd

func GetQueriesCmd(cdc *codec.Codec) *cobra.Command

Get query commands for VM module.

func GetTxCmd

func GetTxCmd(cdc *codec.Codec) *cobra.Command

Return TX commands for CLI.

Types

type MVFile

type MVFile struct {
	Code string `json:"code"`
}

MVFile struct contains code from file in hex.

func GetMVFromFile

func GetMVFromFile(filePath string) (MVFile, error)

Read MVir file contains code in hex.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL