smcbuilder

package
v0.0.0-...-24d451d Latest Latest
Warning

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

Go to latest
Published: Jul 2, 2020 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

View Source
const AlpineImage = "alpine:latest"
View Source
const GolangImageTag = "golang:alpine"

GolangImageTag 編譯我們用 golang 的 1.11.1 版本

View Source
const ThirdPartyContract = "smcrunsvc_v1.0_3dcontract"

Variables

This section is empty.

Functions

This section is empty.

Types

type Builder

type Builder struct {
	Logger  log.Logger
	WorkDir string
	// contains filtered or unexported fields
}

Builder 是一個 Service 外部參數只需要 WorkDir

func GetInstance

func GetInstance() *Builder

GetInstance 返回單例 Builder

func Init

func Init(l log.Logger, p string) *Builder

Init 初始化

func (*Builder) BuildContract

func (b *Builder) BuildContract(transID int64, txID int64, contractMeta std.ContractMeta) std.BuildResult

BuildContract 直接一步編譯,最新的合約是通過參數傳進來,因爲還沒上鏈,返回合約方法列表/exe路徑/出錯信息 nolint gocyclo

func (*Builder) GetContractDllPath

func (b *Builder) GetContractDllPath(transID int64, txID int64, orgID string) (string, error)

GetContractDllPath 直接一步編譯,成功返回全路徑,不成功返回錯誤描述(可以認爲不是/開頭就是失敗了)

type Signature

type Signature struct {
	PubKey    string `json:"pubkey"`
	Signature string `json:"signature"`
}

Signature sig for contract code

Jump to

Keyboard shortcuts

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