overflow

package
v1.0.0-rc1 Latest Latest
Warning

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

Go to latest
Published: Jul 19, 2022 License: MIT Imports: 46 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Addresses

func Addresses(name string, value ...string) func(ftb *FlowInteractionBuilder)

func Arg

func Arg(name string, value interface{}) func(ftb *FlowInteractionBuilder)

/ Send an argument into a transaction / @param name: string the name of the parameter / @param value: the value of the argument, se below / / The value is treated in the given way depending on type / - cadence.Value is sent as straight argument / - string argument are resolved into cadence.Value using flowkit / - ofther values are converted to string with %v and resolved into cadence.Value using flowkit / - if the type of the paramter is Address and the string you send in is a valid account in flow.json it will resolve / / Examples: / If you want to send the UFix64 number "42.0" into a transaciton you have to use it as a string since %v of fmt.Sprintf will make it 42

func Args

func Args(args ...interface{}) func(ftb *FlowInteractionBuilder)

func ArgsM

func ArgsM(args map[string]interface{}) func(ftb *FlowInteractionBuilder)

func CadenceString

func CadenceString(input string) cadence.String

func CadenceValueToInterface

func CadenceValueToInterface(field cadence.Value) interface{}

CadenceValueToInterface convert a candence.Value into interface{}

func CadenceValueToJsonString

func CadenceValueToJsonString(value cadence.Value) string

CadenceValueToJsonString converts a cadence.Value into a json pretty printed string

func DateTimeArg

func DateTimeArg(name string, dateString string, timezone string) func(ftb *FlowInteractionBuilder)

func DoNotPrependNetworkToAccountNames

func DoNotPrependNetworkToAccountNames() func(o *OverflowBuilder)

DoNotPrependNetworkToAccountNames will not prepend the name of the network to account names

func EventFilter

func EventFilter(filter OverflowEventFilter) func(ftb *FlowInteractionBuilder)

func FormatCode

func FormatCode(input string) string

func Gas

func Gas(gas uint64) func(ftb *FlowInteractionBuilder)

func HexToAddress

func HexToAddress(h string) (*cadence.Address, error)

HexToAddress converts a hex string to an Address.

func IgnoreGlobalEventFilters

func IgnoreGlobalEventFilters() func(ftb *FlowInteractionBuilder)

func ParseEvents

func ParseEvents(events []flow.Event) (OverflowEvents, OverflowEvent)

func PayloadSigner

func PayloadSigner(signer ...string) func(ftb *FlowInteractionBuilder)

func PrintEvents

func PrintEvents(events []flow.Event, ignoreFields map[string][]string)

PrintEvents prints th events, ignoring fields specified for the given event typeID Deprecated use PrintEvent on overflowResult

func ProposeAs

func ProposeAs(proposer string) func(ftb *FlowInteractionBuilder)

func ProposeAsServiceAccount

func ProposeAsServiceAccount() func(ftb *FlowInteractionBuilder)

func SignProposeAndPayAs

func SignProposeAndPayAs(signer string) func(ftb *FlowInteractionBuilder)

func SignProposeAndPayAsServiceAccount

func SignProposeAndPayAsServiceAccount() func(ftb *FlowInteractionBuilder)

func WithBasePath

func WithBasePath(path string) func(o *OverflowBuilder)

WithBasePath will change the standard basepath `.` to another folder

func WithEmptyDepoitWithdrawEvents

func WithEmptyDepoitWithdrawEvents() func(o *OverflowBuilder)

func WithEmulatorLog

func WithEmulatorLog() func(opt *PrintOptions)

func WithEventFilter

func WithEventFilter(filter OverflowEventFilter) func(opt *PrintOptions)

func WithExistingEmulator

func WithExistingEmulator() func(o *OverflowBuilder)

WithExistingEmulator will attach to an existing emulator, not deploying contracts and creating accounts

func WithFeesEvents

func WithFeesEvents() func(o *OverflowBuilder)

WithTransactionFolderName will overwite the default script subdir for transactions `transactions`

func WithFlowConfig

func WithFlowConfig(files ...string) func(o *OverflowBuilder)

WithFlowConfig will set the path to one or more flow.json config files The default is ~/flow.json and ./flow.json.

func WithGas

func WithGas(gas int) func(o *OverflowBuilder)

WithGas set the default gas limit, standard is 9999 (max)

func WithGlobalEventTilter

func WithGlobalEventTilter(filter OverflowEventFilter) func(o *OverflowBuilder)

func WithInMemory

func WithInMemory() func(o *OverflowBuilder)

WithInMemory will set that this instance is an in memoy instance createing accounts/deploying contracts

func WithMeter

func WithMeter() func(opt *PrintOptions)

func WithNetwork

func WithNetwork(network string) func(o *OverflowBuilder)

WithNetwork will start overflow with the given network. This function will also set up other options that are common for a given Network. - embedded: starts in memory, will deploy contracts and create accounts, info log - testing: starts in memory, will deploy contracts and create accounts, no log - testnet|mainnet: will only set network, not deploy contracts or create accounts

func WithNoLog

func WithNoLog() func(o *OverflowBuilder)

WithNoLog will start emulator with no output

func WithScriptFolderName

func WithScriptFolderName(name string) func(o *OverflowBuilder)

WithScriptFolderName will overwite the default script subdir for scripts `scripts`

func WithServiceAccountSuffix

func WithServiceAccountSuffix(suffix string) func(o *OverflowBuilder)

WithServiceAccountSuffix will set the suffix of the service account

func WithTransactionFolderName

func WithTransactionFolderName(name string) func(o *OverflowBuilder)

WithTransactionFolderName will overwite the default script subdir for transactions `transactions`

func WithoutEvents

func WithoutEvents() func(opt *PrintOptions)

Types

type CodeWithSpec

type CodeWithSpec struct {
	Code string           `json:"code"`
	Spec *DeclarationInfo `json:"spec"`
}

type DeclarationInfo

type DeclarationInfo struct {
	ParameterOrder []string          `json:"order"`
	Parameters     map[string]string `json:"parameters"`
}

type EventFetcherBuilder

type EventFetcherBuilder struct {
	OverflowState         *OverflowState
	EventsAndIgnoreFields OverflowEventFilter
	FromIndex             int64
	EndAtCurrentHeight    bool
	EndIndex              uint64
	ProgressFile          string
	NumberOfWorkers       int
	EventBatchSize        uint64
}

EventFetcherBuilder builder to hold info about eventhook context.

func (EventFetcherBuilder) BatchSize

func (e EventFetcherBuilder) BatchSize(batchSize uint64) EventFetcherBuilder

BatchSize sets the size of a batch

func (EventFetcherBuilder) End

func (e EventFetcherBuilder) End(blockHeight uint64) EventFetcherBuilder

End specify what index to end at

func (EventFetcherBuilder) Event

func (e EventFetcherBuilder) Event(eventName string) EventFetcherBuilder

Event fetches and Events and all its fields

func (EventFetcherBuilder) EventIgnoringFields

func (e EventFetcherBuilder) EventIgnoringFields(eventName string, ignoreFields []string) EventFetcherBuilder

EventIgnoringFields fetch event and ignore the specified fields

func (EventFetcherBuilder) From

func (e EventFetcherBuilder) From(blockHeight int64) EventFetcherBuilder

From specify what blockHeight to fetch from. This can be negative related to end.

func (EventFetcherBuilder) Last

Last fetch events from the number last blocks

func (EventFetcherBuilder) Run

func (e EventFetcherBuilder) Run() ([]*FormatedEvent, error)

Run runs the eventfetcher returning events or an error

func (EventFetcherBuilder) Start

func (e EventFetcherBuilder) Start(blockHeight int64) EventFetcherBuilder

Start specify what blockHeight to fetch starting atm. This can be negative related to end/until

func (EventFetcherBuilder) TrackProgressIn

func (e EventFetcherBuilder) TrackProgressIn(fileName string) EventFetcherBuilder

TrackProgressIn Specify a file to store progress in

func (EventFetcherBuilder) Until

func (e EventFetcherBuilder) Until(blockHeight uint64) EventFetcherBuilder

Until specify what index to end at

func (EventFetcherBuilder) UntilCurrent

func (e EventFetcherBuilder) UntilCurrent() EventFetcherBuilder

UntilCurrent Specify to fetch events until the current Block

func (EventFetcherBuilder) Workers

func (e EventFetcherBuilder) Workers(workers int) EventFetcherBuilder

Workers sets the number of workers.

type EventFetcherOption

type EventFetcherOption func(*EventFetcherBuilder)

A function to customize the transaction builder

func TrackProgressIn

func TrackProgressIn(fileName string) EventFetcherOption

func UntilBlock

func UntilBlock(blockHeight uint64) EventFetcherOption

func UntilCurrentBlock

func UntilCurrentBlock() EventFetcherOption

func WithBatchSize

func WithBatchSize(size uint64) EventFetcherOption

func WithEndIndex

func WithEndIndex(blockHeight uint64) EventFetcherOption

func WithEvent

func WithEvent(eventName string) EventFetcherOption

func WithEventIgnoringField

func WithEventIgnoringField(eventName string, ignoreFields []string) EventFetcherOption

func WithFromIndex

func WithFromIndex(blockHeight int64) EventFetcherOption

func WithLastBlocks

func WithLastBlocks(number uint64) EventFetcherOption

func WithStartHeight

func WithStartHeight(blockHeight int64) EventFetcherOption

func WithWorkers

func WithWorkers(workers int) EventFetcherOption

type EventFetcherResult

type EventFetcherResult struct {
	Err    error
	Events *OverflowEvents
}

type FlowArgumentsBuilder

type FlowArgumentsBuilder struct {
	Overflow  *OverflowState
	Arguments []cadence.Value
	Error     error
}

FlowArgumentsBuilder used to create a builder pattern for a transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Account

Account add an address as an argument Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) AccountArray

func (a *FlowArgumentsBuilder) AccountArray(value ...string) *FlowArgumentsBuilder

Argument add a RawAddressArray to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Address

Account add an address as an argument Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Argument

Argument add an argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Boolean

func (a *FlowArgumentsBuilder) Boolean(value bool) *FlowArgumentsBuilder

Boolean add a Boolean Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Build deprecated

func (a *FlowArgumentsBuilder) Build() []cadence.Value

Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Bytes

func (a *FlowArgumentsBuilder) Bytes(value []byte) *FlowArgumentsBuilder

Bytes add a Bytes Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) DateStringAsUnixTimestamp

func (a *FlowArgumentsBuilder) DateStringAsUnixTimestamp(dateString string, timezone string) *FlowArgumentsBuilder

DateStringAsUnixTimestamp sends a dateString parsed in the timezone as a unix timeszone ufix Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Fix64

Fix64 add a Fix64 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Int

Int add an Int Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Int128

func (a *FlowArgumentsBuilder) Int128(value int) *FlowArgumentsBuilder

Int128 add an Int128 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Int16

Int16 add an Int16 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Int256

func (a *FlowArgumentsBuilder) Int256(value int) *FlowArgumentsBuilder

Int256 add an Int256 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Int32

Int32 add an Int32 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Int64

Int64 add an Int64 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Int8

Int8 add an Int8 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) PrivatePath

func (a *FlowArgumentsBuilder) PrivatePath(input string) *FlowArgumentsBuilder

PrivatePath argument Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) PublicPath

func (a *FlowArgumentsBuilder) PublicPath(input string) *FlowArgumentsBuilder

PublicPath argument Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) RawAccount

func (a *FlowArgumentsBuilder) RawAccount(address string) *FlowArgumentsBuilder

RawAccount add an address from a string as an argument Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) RawAddress

func (a *FlowArgumentsBuilder) RawAddress(address string) *FlowArgumentsBuilder

RawAccount add an address from a string as an argument Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) RawAddressArray

func (a *FlowArgumentsBuilder) RawAddressArray(value ...string) *FlowArgumentsBuilder

Argument add a RawAddressArray to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) ScalarMap

func (a *FlowArgumentsBuilder) ScalarMap(input map[string]string) *FlowArgumentsBuilder
add an {String:UFix64} to the transaction

Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) ScalarMapArray

func (a *FlowArgumentsBuilder) ScalarMapArray(value ...map[string]string) *FlowArgumentsBuilder

Argument add an StringArray to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) StoragePath

func (a *FlowArgumentsBuilder) StoragePath(input string) *FlowArgumentsBuilder

StoragePath argument Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) String

String add a String Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) StringArray

func (a *FlowArgumentsBuilder) StringArray(value ...string) *FlowArgumentsBuilder

Argument add an StringArray to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) StringMap

func (a *FlowArgumentsBuilder) StringMap(input map[string]string) *FlowArgumentsBuilder
add an {String:String} to the transaction

Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) StringMapArray

func (a *FlowArgumentsBuilder) StringMapArray(value ...map[string]string) *FlowArgumentsBuilder

Argument add an StringMapArray to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) UFix64

UFix64 add a UFix64 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) UFix64Array

func (a *FlowArgumentsBuilder) UFix64Array(value ...float64) *FlowArgumentsBuilder

Argument add an argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) UInt

UInt add an UInt Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) UInt128

func (a *FlowArgumentsBuilder) UInt128(value uint) *FlowArgumentsBuilder

UInt128 add an UInt128 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) UInt16

UInt16 add an UInt16 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) UInt256

func (a *FlowArgumentsBuilder) UInt256(value uint) *FlowArgumentsBuilder

UInt256 add an UInt256 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) UInt32

UInt32 add an UInt32 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) UInt64

UInt64 add an UInt64 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) UInt64Array

func (a *FlowArgumentsBuilder) UInt64Array(value ...uint64) *FlowArgumentsBuilder

Argument add an argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) UInt8

UInt8 add an UInt8 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) UInt8Array

func (a *FlowArgumentsBuilder) UInt8Array(value ...uint8) *FlowArgumentsBuilder

Argument add an argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Word16

Word16 add a Word16 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Word32

Word32 add a Word32 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Word64

Word64 add a Word64 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*FlowArgumentsBuilder) Word8

Word8 add a Word8 Argument to the transaction Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

type FlowInteractionBuilder

type FlowInteractionBuilder struct {
	Overflow       *OverflowState
	FileName       string
	Content        string
	Arguments      []cadence.Value
	MainSigner     *flowkit.Account
	PayloadSigners []*flowkit.Account
	GasLimit       uint64
	BasePath       string
	Error          error

	//these are used for v3, but can still be here for v2
	TransactionCode []byte
	NamedArgs       map[string]interface{}
	Proposer        *flowkit.Account

	EventFilter              OverflowEventFilter
	IgnoreGlobalEventFilters bool
}

FlowInteractionBuilder used to create a builder pattern for a transaction

func (FlowInteractionBuilder) Args

Specify arguments to send to transaction using a builder you send in Deprecated: Use Arg

func (FlowInteractionBuilder) ArgsFn

Specify arguments to send to transaction using a function that takes a builder where you call the builder Deprecated: Use Arg

func (FlowInteractionBuilder) ArgsV

Specify arguments to send to transaction using a raw list of values Deprecated: Use Args

func (FlowInteractionBuilder) Gas deprecated

Deprecated: Use Tx function Gas sets the gas limit for this transaction

func (FlowInteractionBuilder) NamedArguments deprecated

func (t FlowInteractionBuilder) NamedArguments(args map[string]string) FlowInteractionBuilder

Deprecated: Use ArgM

func (FlowInteractionBuilder) PayloadSigner deprecated

func (t FlowInteractionBuilder) PayloadSigner(value string) FlowInteractionBuilder

Deprecated: Use Tx function PayloadSigner set a signer for the payload

func (FlowInteractionBuilder) Run

func (t FlowInteractionBuilder) Run() []flow.Event

Run run the transaction deprecated: use Send and get entire result

func (FlowInteractionBuilder) RunE

func (t FlowInteractionBuilder) RunE() ([]flow.Event, error)

RunE runs returns events and error Deprecated: use Send()

func (FlowInteractionBuilder) RunGetEventsWithName deprecated

func (t FlowInteractionBuilder) RunGetEventsWithName(eventName string) []FormatedEvent

Deprecated: Use Send().GetEventsWithName()

func (FlowInteractionBuilder) RunGetEventsWithNameOrError

func (t FlowInteractionBuilder) RunGetEventsWithNameOrError(eventName string) ([]FormatedEvent, error)

/ Deprecated: use Tx().GetEventsWithName

func (FlowInteractionBuilder) RunGetIdFromEvent

func (t FlowInteractionBuilder) RunGetIdFromEvent(eventName string, fieldName string) uint64

Deprecated, use Send().GetIdFromEvent

func (FlowInteractionBuilder) RunGetIdFromEventPrintAll deprecated

func (t FlowInteractionBuilder) RunGetIdFromEventPrintAll(eventName string, fieldName string) uint64

Deprecated: Use Tx().Print().GetIdFromEvent

func (FlowInteractionBuilder) RunGetIds deprecated

func (t FlowInteractionBuilder) RunGetIds(eventName string, fieldName string) ([]uint64, error)

Deprecated: Use Tx().Print().GetIdsFromEvent

func (FlowInteractionBuilder) RunPrintEvents

func (t FlowInteractionBuilder) RunPrintEvents(ignoreFields map[string][]string)

RunPrintEvents will run a transaction and print all events ignoring some fields Deprecated use Send().PrintEventsFiltered()

func (FlowInteractionBuilder) RunPrintEventsFull

func (t FlowInteractionBuilder) RunPrintEventsFull()

RunPrintEventsFull will run a transaction and print all events Deprecated use Send().PrintEvents()

func (FlowInteractionBuilder) Send

Send a intereaction builder as a Transaction returning an overflow result

func (FlowInteractionBuilder) SignProposeAndPayAs deprecated

func (t FlowInteractionBuilder) SignProposeAndPayAs(signer string) FlowInteractionBuilder

Deprecated: Use Tx function SignProposeAndPayAs set the payer, proposer and envelope signer

func (FlowInteractionBuilder) SignProposeAndPayAsService deprecated

func (t FlowInteractionBuilder) SignProposeAndPayAsService() FlowInteractionBuilder

Deprecated: Use Tx function SignProposeAndPayAsService set the payer, proposer and envelope signer

func (FlowInteractionBuilder) Test deprecated

Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (FlowInteractionBuilder) TransactionPath deprecated

func (t FlowInteractionBuilder) TransactionPath(path string) FlowInteractionBuilder

Deprecated: Use Tx function

type FlowScriptBuilder

type FlowScriptBuilder struct {
	Overflow       *OverflowState
	FileName       string
	Arguments      []cadence.Value
	ScriptAsString string
	BasePath       string
	Error          error
}

FlowScriptBuilder is a struct to hold information for running a script Deprecation use FlowInteractionBuilder and the Script method

func (FlowScriptBuilder) Args

Specify arguments to send to transaction using a builder you send in Deprecation use FlowInteractionBuilder and the Script method

func (FlowScriptBuilder) ArgsFn

Specify arguments to send to transaction using a function that takes a builder where you call the builder Deprecation use FlowInteractionBuilder and the Script method

func (FlowScriptBuilder) ArgsV

Specify arguments to send to transaction using a raw list of values Deprecation use FlowInteractionBuilder and the Script method

func (FlowScriptBuilder) NamedArguments

func (t FlowScriptBuilder) NamedArguments(args map[string]string) FlowScriptBuilder

Deprecation use FlowInteractionBuilder and the Script method

func (FlowScriptBuilder) Run

func (t FlowScriptBuilder) Run()

Run executes a read only script Deprecation use FlowInteractionBuilder and the Script method

func (FlowScriptBuilder) RunFailOnError

func (t FlowScriptBuilder) RunFailOnError() cadence.Value

Deprecation use FlowInteractionBuilder and the Script method

func (FlowScriptBuilder) RunMarshalAs

func (t FlowScriptBuilder) RunMarshalAs(value interface{}) error

RunMarshalAs runs the script and marshals the result into the provided value, returning an error if any Deprecation use FlowInteractionBuilder and the Script method

func (FlowScriptBuilder) RunReturns

func (t FlowScriptBuilder) RunReturns() (cadence.Value, error)

RunReturns executes a read only script Deprecation use FlowInteractionBuilder and the Script method

func (FlowScriptBuilder) RunReturnsInterface

func (t FlowScriptBuilder) RunReturnsInterface() interface{}

RunReturnsInterface runs the script and returns interface{} Deprecation use FlowInteractionBuilder and the Script method

func (FlowScriptBuilder) RunReturnsJsonString

func (t FlowScriptBuilder) RunReturnsJsonString() string

RunReturnsJsonString runs the script and returns pretty printed json string Deprecation use FlowInteractionBuilder and the Script method

func (FlowScriptBuilder) ScriptPath

func (t FlowScriptBuilder) ScriptPath(path string) FlowScriptBuilder

Deprecation use FlowInteractionBuilder and the Script method

type FormatedEvent

type FormatedEvent struct {
	Name        string                 `json:"name"`
	BlockHeight uint64                 `json:"blockHeight,omitempty"`
	Time        time.Time              `json:"time,omitempty"`
	Fields      map[string]interface{} `json:"fields"`
}

FormatedEvent event in a more condensed formated form

func FormatEvents

func FormatEvents(blockEvents []flow.BlockEvents, ignoreFields map[string][]string) []*FormatedEvent

FormatEvents

func NewTestEvent

func NewTestEvent(name string, fields map[string]interface{}) *FormatedEvent

func ParseEvent

func ParseEvent(event flow.Event, blockHeight uint64, time time.Time, ignoreFields []string) *FormatedEvent

ParseEvent parses a flow event into a more terse representation

func (FormatedEvent) ExistIn

func (o FormatedEvent) ExistIn(events []*FormatedEvent) bool

func (FormatedEvent) GetFieldAsUInt64

func (e FormatedEvent) GetFieldAsUInt64(field string) uint64

func (FormatedEvent) ShortName

func (fe FormatedEvent) ShortName() string

func (FormatedEvent) String

func (e FormatedEvent) String() string

String pretty print an event as a String

type InteractionOption

type InteractionOption func(*FlowInteractionBuilder)

A function to customize the transaction builder

type LogrusMessage

type LogrusMessage struct {
	ComputationUsed int       `json:"computationUsed"`
	Level           string    `json:"level"`
	Msg             string    `json:"msg"`
	Time            time.Time `json:"time"`
	TxID            string    `json:"txID"`
}

LogrusMessage a log message from the logrus implementation used in the flow emulator

type MergedSolution

type MergedSolution struct {
	Networks map[string]MergedSolutionNetwork `json:"networks"`
}

type MergedSolutionNetwork

type MergedSolutionNetwork struct {
	Scripts      map[string]CodeWithSpec `json:"scripts"`
	Transactions map[string]CodeWithSpec `json:"transactions,omitempty"`
	Contracts    *map[string]string      `json:"contracts,omitempty"`
}

type Meter

type Meter struct {
	LedgerInteractionUsed  int                           `json:"ledgerInteractionUsed"`
	ComputationUsed        int                           `json:"computationUsed"`
	MemoryUsed             int                           `json:"memoryUsed"`
	ComputationIntensities MeteredComputationIntensities `json:"computationIntensities"`
	MemoryIntensities      MeteredMemoryIntensities      `json:"memoryIntensities"`
}

func (Meter) FunctionInvocations

func (m Meter) FunctionInvocations() int

func (Meter) Loops

func (m Meter) Loops() int

func (Meter) Statements

func (m Meter) Statements() int

type MeteredComputationIntensities

type MeteredComputationIntensities map[common.ComputationKind]uint

type MeteredMemoryIntensities

type MeteredMemoryIntensities map[common.MemoryKind]uint

type OverflowBuilder

type OverflowBuilder struct {
	Network                             string
	InMemory                            bool
	DeployContracts                     bool
	GasLimit                            int
	Path                                string
	LogLevel                            int
	InitializeAccounts                  bool
	PrependNetworkName                  bool
	ServiceSuffix                       string
	ConfigFiles                         []string
	TransactionFolderName               string
	ScriptFolderName                    string
	FilterOutFeeEvents                  bool
	FilterOutEmptyWithDrawDepositEvents bool
	GlobalEventFilter                   OverflowEventFilter
}

OverflowBuilder is the struct used to gather up configuration when building an overflow instance

func NewOverflow

func NewOverflow() *OverflowBuilder

Deprecated use Overflow function with builder

func NewOverflowBuilder

func NewOverflowBuilder(network string, newEmulator bool, logLevel int) *OverflowBuilder

Deprecated use Overflow function with builder

func NewOverflowEmulator

func NewOverflowEmulator() *OverflowBuilder

NewOverflowEmulator create a new client Deprecated use Overflow function with builder

func NewOverflowForNetwork

func NewOverflowForNetwork(network string) *OverflowBuilder

NewOverflowForNetwork creates a new overflow client for the provided network Deprecated use Overflow function with builder

func NewOverflowInMemoryEmulator

func NewOverflowInMemoryEmulator() *OverflowBuilder

NewOverflowInMemoryEmulator this method is used to create an in memory emulator, deploy all contracts for the emulator and create all accounts Deprecated use Overflow function with builder

func NewOverflowMainnet

func NewOverflowMainnet() *OverflowBuilder

NewOverflowMainnet creates a new gwft client for mainnet Deprecated use Overflow function with builder

func NewOverflowTestnet

func NewOverflowTestnet() *OverflowBuilder

NewOverflowTestnet creates a new overflow client for devnet/testnet Deprecated use Overflow function with builder

func NewTestingEmulator

func NewTestingEmulator() *OverflowBuilder

NewTestingEmulator starts an embeded emulator with no log to be used most often in tests Deprecated use Overflow function with builder

func (*OverflowBuilder) BasePath

func (o *OverflowBuilder) BasePath(path string) *OverflowBuilder

BasePath set the base path for transactions/scripts/contracts Deprecated use Overflow function with builder

func (*OverflowBuilder) Config

func (o *OverflowBuilder) Config(files ...string) *OverflowBuilder

Config sets the file path to the flow.json config files to use Deprecated use Overflow function with builder

func (*OverflowBuilder) DefaultGas

func (o *OverflowBuilder) DefaultGas(gas int) *OverflowBuilder

DefaultGas sets the default gas limit to use Deprecated use Overflow function with builder

func (*OverflowBuilder) DoNotPrependNetworkToAccountNames

func (o *OverflowBuilder) DoNotPrependNetworkToAccountNames() *OverflowBuilder

DoNotPrependNetworkToAccountNames sets that network names will not be prepends to account names Deprecated use Overflow function with builder

func (*OverflowBuilder) ExistingEmulator

func (o *OverflowBuilder) ExistingEmulator() *OverflowBuilder

ExistingEmulator this if you are using an existing emulator and you do not want to create contracts or initializeAccounts Deprecated use Overflow function with builder

func (*OverflowBuilder) NoneLog

func (o *OverflowBuilder) NoneLog() *OverflowBuilder

NoneLog will turn of logging, making the script work well in batch jobs Deprecated use Overflow function with builder

func (*OverflowBuilder) SetServiceSuffix

func (o *OverflowBuilder) SetServiceSuffix(suffix string) *OverflowBuilder

SetServiceSuffix will set the suffix to use for the service account. The default is `account` Deprecated use Overflow function with builder

func (*OverflowBuilder) Start

func (ob *OverflowBuilder) Start() *OverflowState

Start will start the overflow builder and return OverflowState, will panic if there are errors Deprecated use Overflow function with builder

func (*OverflowBuilder) StartE

func (o *OverflowBuilder) StartE() (*OverflowState, error)

StartE will start Overflow and return State and error if any Deprecated use Overflow function with builder

type OverflowEvent

type OverflowEvent map[string]interface{}

a type representing the terse output of an raw Flow Event

func (OverflowEvent) ExistIn

func (o OverflowEvent) ExistIn(events []OverflowEvent) bool

type OverflowEventFilter

type OverflowEventFilter map[string][]string

A type alias to an OverflowEventFilter to filter out all events with a given suffix and the fields with given suffixes

type OverflowEvents

type OverflowEvents map[string][]OverflowEvent

a type holding all events that are emitted from a Transaction

func (OverflowEvents) FilterEvents

func (overflowEvents OverflowEvents) FilterEvents(ignoreFields OverflowEventFilter) OverflowEvents

func (OverflowEvents) FilterFees

func (overflowEvents OverflowEvents) FilterFees(fee float64) OverflowEvents

func (OverflowEvents) FilterTempWithdrawDeposit

func (overflowEvents OverflowEvents) FilterTempWithdrawDeposit() OverflowEvents

type OverflowOption

type OverflowOption func(*OverflowBuilder)

OverflowOption and option function that you can send in to configure Overflow

type OverflowPastEvent

type OverflowPastEvent struct {
	Name        string        `json:"name"`
	BlockHeight uint64        `json:"blockHeight,omitempty"`
	Time        time.Time     `json:"time,omitempty"`
	Fields      OverflowEvent `json:"fields"`
}

func NewTestPastEvent

func NewTestPastEvent(name string, fields map[string]interface{}) *OverflowPastEvent

func (OverflowPastEvent) GetFieldAsUInt64

func (e OverflowPastEvent) GetFieldAsUInt64(field string) uint64

func (OverflowPastEvent) String

func (e OverflowPastEvent) String() string

String pretty print an event as a String

type OverflowResult

type OverflowResult struct {
	//The error if any
	Err error

	//The id of the transaction
	Id flow.Identifier

	//If running on an emulator
	//the meter that contains useful debug information on memory and interactions
	Meter *Meter
	//The Raw log from the emulator
	RawLog []LogrusMessage
	// The log from the emulator
	EmulatorLog []string

	//The computation used
	ComputationUsed int

	//The raw unfiltered events
	RawEvents []flow.Event

	//Events that are filtered and parsed into a terse format
	Events OverflowEvents

	//The underlying transaction if we need to look into that
	Transaction *flow.Transaction

	//TODO: consider marshalling this as a struct for convenience
	//The fee event if any
	Fee map[string]interface{}

	//The logger to log output to
	Logger output.Logger

	//The name of the Transaction
	Name string
}

OverflowResult represents the state after running an transaction

func (OverflowResult) AssertComputationLessThenOrEqual

func (o OverflowResult) AssertComputationLessThenOrEqual(t *testing.T, computation int) OverflowResult

func (OverflowResult) AssertComputationUsed

func (o OverflowResult) AssertComputationUsed(t *testing.T, computation int) OverflowResult

func (OverflowResult) AssertEmitEventName

func (o OverflowResult) AssertEmitEventName(t *testing.T, event ...string) OverflowResult

func (OverflowResult) AssertEmulatorLog

func (o OverflowResult) AssertEmulatorLog(t *testing.T, message string) OverflowResult

func (OverflowResult) AssertEvent

func (o OverflowResult) AssertEvent(t *testing.T, name string, fields OverflowEvent) OverflowResult

func (OverflowResult) AssertEventCount

func (o OverflowResult) AssertEventCount(t *testing.T, number int) OverflowResult

func (OverflowResult) AssertFailure

func (o OverflowResult) AssertFailure(t *testing.T, msg string) OverflowResult

func (OverflowResult) AssertNoEvents

func (o OverflowResult) AssertNoEvents(t *testing.T) OverflowResult

func (OverflowResult) AssertSuccess

func (o OverflowResult) AssertSuccess(t *testing.T) OverflowResult

func (OverflowResult) GetEventsWithName

func (o OverflowResult) GetEventsWithName(eventName string) []OverflowEvent

func (OverflowResult) GetIdFromEvent

func (o OverflowResult) GetIdFromEvent(eventName string, fieldName string) uint64

func (OverflowResult) GetIdsFromEvent

func (o OverflowResult) GetIdsFromEvent(eventName string, fieldName string) []uint64

func (OverflowResult) Print

func (o OverflowResult) Print(opts ...PrinterOption) OverflowResult

type OverflowScriptResult

type OverflowScriptResult struct {
	Err    error
	Result cadence.Value
	Input  *FlowInteractionBuilder
	Log    []LogrusMessage
	Output interface{}
}

func (*OverflowScriptResult) AssertLengthWithPointer

func (osr *OverflowScriptResult) AssertLengthWithPointer(t *testing.T, pointer string, length int) *OverflowScriptResult

func (*OverflowScriptResult) AssertWant

func (osr *OverflowScriptResult) AssertWant(t *testing.T, want autogold.Value) *OverflowScriptResult

func (*OverflowScriptResult) AssertWithPointer

func (osr *OverflowScriptResult) AssertWithPointer(t *testing.T, pointer string, value interface{}) *OverflowScriptResult

func (*OverflowScriptResult) AssertWithPointerError

func (osr *OverflowScriptResult) AssertWithPointerError(t *testing.T, pointer string, message string) *OverflowScriptResult

func (*OverflowScriptResult) AssertWithPointerWant

func (osr *OverflowScriptResult) AssertWithPointerWant(t *testing.T, pointer string, want autogold.Value) *OverflowScriptResult

func (*OverflowScriptResult) GetAsInterface

func (osr *OverflowScriptResult) GetAsInterface() interface{}

func (*OverflowScriptResult) GetAsJson

func (osr *OverflowScriptResult) GetAsJson() string

func (*OverflowScriptResult) GetWithPointer

func (osr *OverflowScriptResult) GetWithPointer(pointer string) (interface{}, error)

func (*OverflowScriptResult) MarhalAs

func (osr *OverflowScriptResult) MarhalAs(value interface{}) error

func (*OverflowScriptResult) MarshalPointerAs

func (osr *OverflowScriptResult) MarshalPointerAs(pointer string, marshalTo interface{}) error

func (*OverflowScriptResult) Print

func (osr *OverflowScriptResult) Print()

type OverflowState

type OverflowState struct {

	//State is the current state of the configured overflow instance
	State *flowkit.State

	//the services from flowkit to performed operations on
	Services *services.Services

	//Configured variables that are taken from the builder since we need them in the execution of overflow later on
	Network                      string
	PrependNetworkToAccountNames bool
	ServiceAccountSuffix         string
	Gas                          int

	//flowkit, emulator and emulator debug log uses three different logging technologies so we have them all stored here
	Logger output.Logger
	Log    *bytes.Buffer

	//https://github.com/bjartek/overflow/issues/45
	//This is not populated with anything yet since the emulator version that has this change is not in mainline yet
	EmulatorLog *bytes.Buffer

	//If there was an error starting overflow it is stored here
	Error error

	//Paths that points to where .cdc files are stored and the posibilty to specify something besides the standard `transactions`/`scripts`subdirectories
	BasePath            string
	TransactionBasePath string
	ScriptBasePath      string

	//Filters to events to remove uneeded noise
	FilterOutFeeEvents                  bool
	FilterOutEmptyWithDrawDepositEvents bool
	GlobalEventFilter                   OverflowEventFilter
}

OverflowState contains information about how to Overflow is confitured and the current runnig state

func Overflow

func Overflow(opts ...OverflowOption) *OverflowState
 Overflow will start an  Overflow instance that panics if there are initialization errors

 Will read the following ENV vars as default:
  OVERFLOW_ENV : set to "mainnet|testnet|emulator|embedded", default embedded
	OVERFLOW_LOGGING: set from 0-3 to get increasing amount of log output, default 3
	OVERFLOW_CONTINUE: to continue this overflow on an already running emulator., default false

 Starting overflow without env vars will make it start in embedded mode deploying all contracts creating accounts

 You can then chose to override this setting with the builder methods example
 `
  Overflow(WithNetwork("mainnet"))
 `

 Setting the network in this way will reset other builder methods if appropriate so use with care.

func OverflowE

func OverflowE(opts ...OverflowOption) (*OverflowState, error)

OverfloewE will start overflow and return state or an error if there is one See Overflow doc comment for an better docs

func OverflowTesting

func OverflowTesting(opts ...OverflowOption) (*OverflowState, error)

OverflowTesting starts an overflow emulator that is suitable for testing that will print no logs to stdout

func (*OverflowState) AccountE

func (f *OverflowState) AccountE(key string) (*flowkit.Account, error)

AccountE fetch an account from State Note that if `PrependNetworkToAccountNames` is specified it is prefixed with the network so that you can use the same logical name accross networks

func (*OverflowState) Arguments deprecated

func (f *OverflowState) Arguments() *FlowArgumentsBuilder

Deprecated: This builder and all its methods are deprecated. Use the new Tx/Script methods and its argument method

func (*OverflowState) BuildInteraction

func (o *OverflowState) BuildInteraction(filename string, interactionType string, opts ...InteractionOption) *FlowInteractionBuilder

func (*OverflowState) CreateAccountsE

func (f *OverflowState) CreateAccountsE() (*OverflowState, error)

CreateAccountsE ensures that all accounts present in the deployment block for the given network is present

func (*OverflowState) DownloadAndUploadFile

func (o *OverflowState) DownloadAndUploadFile(url string, accountName string) error

DownloadAndUploadFile reads a file, base64 encodes it and chunk upload to /storage/upload

func (*OverflowState) DownloadImageAndUploadAsDataUrl

func (o *OverflowState) DownloadImageAndUploadAsDataUrl(url, accountName string) error

DownloadImageAndUploadAsDataUrl download an image and upload as data url

func (*OverflowState) EventFetcher

func (o *OverflowState) EventFetcher() EventFetcherBuilder

EventFetcher create an event fetcher builder.

func (*OverflowState) FetchEvents

func (o *OverflowState) FetchEvents(opts ...EventFetcherOption) ([]OverflowPastEvent, error)

EventFetcher create an event fetcher builder.

func (*OverflowState) FillUpStorage

func (o *OverflowState) FillUpStorage(accountName string)

A method to fill up a users storage, useful when testing

func (*OverflowState) GetAccount

func (f *OverflowState) GetAccount(key string) (*flow.Account, error)

GetAccount takes the account name and returns the state of that account on the given network. TODO: consider renaming this method as this is getting a remove account a flow account not a flowkit account

func (*OverflowState) GetBlockAtHeight

func (f *OverflowState) GetBlockAtHeight(height uint64) (*flow.Block, error)

func (*OverflowState) GetBlockById

func (f *OverflowState) GetBlockById(blockId string) (*flow.Block, error)

blockId should be a hexadecimal string

func (*OverflowState) GetFreeCapacity

func (o *OverflowState) GetFreeCapacity(accountName string) int

Get the free capacity in an account

func (*OverflowState) GetLatestBlock

func (f *OverflowState) GetLatestBlock() (*flow.Block, error)

func (*OverflowState) InitializeContracts

func (o *OverflowState) InitializeContracts() *OverflowState

InitializeContracts installs all contracts in the deployment block for the configured network

func (*OverflowState) InlineScript

func (o *OverflowState) InlineScript(content string) FlowScriptBuilder

Script start a script builder with the inline script as body Deprecation use FlowInteractionBuilder and the Script method

func (*OverflowState) Parse

func (o *OverflowState) Parse(codeFileName string, code []byte, network string) (string, error)

func (*OverflowState) ParseAll

func (o *OverflowState) ParseAll() (*Solution, error)

func (*OverflowState) ParseAllWithConfig

func (o *OverflowState) ParseAllWithConfig(skipContracts bool, txSkip []string, scriptSkip []string) (*Solution, error)

func (*OverflowState) ParseArgumentsWithoutType deprecated

func (f *OverflowState) ParseArgumentsWithoutType(fileName string, code []byte, inputArgs map[string]string) ([]cadence.Value, error)

Deprecated: use the new Tx/Script method and the argument functions

func (*OverflowState) Script

func (o *OverflowState) Script(filename string, opts ...InteractionOption) *OverflowScriptResult

func (*OverflowState) ScriptFN

func (o *OverflowState) ScriptFN(outerOpts ...InteractionOption) ScriptFunction

func (*OverflowState) ScriptFileNameFN

func (o *OverflowState) ScriptFileNameFN(filename string, outerOpts ...InteractionOption) ScriptOptsFunction

func (*OverflowState) ScriptFromFile

func (o *OverflowState) ScriptFromFile(filename string) FlowScriptBuilder

ScriptFromFile will start a flow script builder Deprecation use FlowInteractionBuilder and the Script method

func (*OverflowState) ServiceAccountName

func (o *OverflowState) ServiceAccountName() string

ServiceAccountName return the name of the current service account Note that if `PrependNetworkToAccountNames` is specified it is prefixed with the network so that you can use the same logical name accross networks

func (*OverflowState) SignUserMessage

func (f *OverflowState) SignUserMessage(account string, message string) (string, error)

func (*OverflowState) SimpleTxArgs deprecated

func (o *OverflowState) SimpleTxArgs(filename string, signer string, args *FlowArgumentsBuilder)

Deprecated: Use Tx()

func (*OverflowState) Transaction

func (o *OverflowState) Transaction(content string) FlowInteractionBuilder

Transaction will start a flow transaction builder using the inline transaction Deprecated: Use Tx()

func (*OverflowState) TransactionFromFile

func (o *OverflowState) TransactionFromFile(filename string) FlowInteractionBuilder

TransactionFromFile will start a flow transaction builder Deprecated: Use Tx()

func (*OverflowState) Tx

func (o *OverflowState) Tx(filename string, opts ...InteractionOption) *OverflowResult

The main function for running an transasction in overflow

func (*OverflowState) TxFN

func (o *OverflowState) TxFN(outerOpts ...InteractionOption) TransactionFunction

If you store this in a struct and add arguments to it it will not reset between calls

func (*OverflowState) TxFileNameFN

func (o *OverflowState) TxFileNameFN(filename string, outerOpts ...InteractionOption) TransactionOptsFunction

func (*OverflowState) UploadFile

func (o *OverflowState) UploadFile(filename string, accountName string) error

UploadFile reads a file, base64 encodes it and chunk upload to /storage/upload

func (*OverflowState) UploadImageAsDataUrl

func (o *OverflowState) UploadImageAsDataUrl(filename string, accountName string) error

UploadImageAsDataUrl will upload a image file from the filesystem into /storage/upload of the given account

func (*OverflowState) UploadString

func (o *OverflowState) UploadString(content string, accountName string) error

UploadString will upload the given string data in 1mb chunkts to /storage/upload of the given account

type PrintOptions

type PrintOptions struct {
	Events      bool
	EventFilter OverflowEventFilter
	Meter       bool
	EmulatorLog bool
}

type PrinterOption

type PrinterOption func(*PrintOptions)

type ScriptFunction

type ScriptFunction func(filename string, opts ...InteractionOption) *OverflowScriptResult

Composition functions for Scripts

type ScriptOptsFunction

type ScriptOptsFunction func(opts ...InteractionOption) *OverflowScriptResult

type Solution

type Solution struct {
	Transactions map[string]*DeclarationInfo `json:"transactions"`
	Scripts      map[string]*DeclarationInfo `json:"scripts"`
	Networks     map[string]*SolutionNetwork `json:"networks"`
}

func (*Solution) MergeSpecAndCode

func (s *Solution) MergeSpecAndCode() *MergedSolution

type SolutionNetwork

type SolutionNetwork struct {
	Scripts      map[string]string  `json:"scripts"`
	Transactions map[string]string  `json:"transactions,omitempty"`
	Contracts    *map[string]string `json:"contracts,omitempty"`
}

type TransactionFunction

type TransactionFunction func(filename string, opts ...InteractionOption) *OverflowResult

Composition functions for Transactions

type TransactionOptsFunction

type TransactionOptsFunction func(opts ...InteractionOption) *OverflowResult

type TransactionResult

type TransactionResult struct {
	Err     error
	Events  []*FormatedEvent
	Result  *OverflowResult
	Testing *testing.T
}

Deprecated use the new Tx() method and OverflowResult

func (TransactionResult) AssertComputationLessThenOrEqual

func (t TransactionResult) AssertComputationLessThenOrEqual(computation int) TransactionResult

Deprecated use the new Tx() method and Asserts on the result

func (TransactionResult) AssertComputationUsed

func (t TransactionResult) AssertComputationUsed(computation int) TransactionResult

Deprecated use the new Tx() method and Asserts on the result

func (TransactionResult) AssertDebugLog

func (t TransactionResult) AssertDebugLog(message ...string) TransactionResult

Deprecated use the new Tx() method and Asserts on the result

func (TransactionResult) AssertEmitEvent

func (t TransactionResult) AssertEmitEvent(event ...*FormatedEvent) TransactionResult

Deprecated use the new Tx() method and Asserts on the result

func (TransactionResult) AssertEmitEventJson

func (t TransactionResult) AssertEmitEventJson(event ...string) TransactionResult

Deprecated use the new Tx() method and Asserts on the result

func (TransactionResult) AssertEmitEventName

func (t TransactionResult) AssertEmitEventName(event ...string) TransactionResult

Deprecated use the new Tx() method and Asserts on the result

func (TransactionResult) AssertEmitEventNameShortForm

func (t TransactionResult) AssertEmitEventNameShortForm(event ...string) TransactionResult

Deprecated use the new Tx() method and Asserts on the result

func (TransactionResult) AssertEmulatorLog

func (t TransactionResult) AssertEmulatorLog(message string) TransactionResult

Deprecated use the new Tx() method and Asserts on the result

func (TransactionResult) AssertEventCount

func (t TransactionResult) AssertEventCount(number int) TransactionResult

Deprecated use the new Tx() method and Asserts on the result

func (TransactionResult) AssertFailure

func (t TransactionResult) AssertFailure(msg string) TransactionResult

Deprecated use the new Tx() method and Asserts on the result

func (TransactionResult) AssertNoEvents

func (t TransactionResult) AssertNoEvents() TransactionResult

Deprecated use the new Tx() method and Asserts on the result

func (TransactionResult) AssertPartialEvent

func (t TransactionResult) AssertPartialEvent(expected *FormatedEvent) TransactionResult

Deprecated use the new Tx() method and Asserts on the result

func (TransactionResult) AssertSuccess

func (t TransactionResult) AssertSuccess() TransactionResult

Deprecated use the new Tx() method and Asserts on the result

func (TransactionResult) GetIdFromEvent

func (t TransactionResult) GetIdFromEvent(eventName string, fieldName string) uint64

Deprecated use the new Tx() method and Asserts on the result

Jump to

Keyboard shortcuts

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