Skip to content

Commit

Permalink
Define TxnOutput API in go/common/runtime
Browse files Browse the repository at this point in the history
  • Loading branch information
tjanez committed May 7, 2019
1 parent 7a5e56b commit 1bc7dd4
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions go/common/runtime/runtime.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,3 +47,13 @@ type Tag struct {
// Value is the tag value.
Value []byte
}

// TxnOutput is an enum that has either Success or Error defined, depending on
// the result of the transaction call.
// It is meant for deserializing CBOR of the corresponding Rust enum.
type TxnOutput struct {
// Success can be of any type.
Success interface{}
// Error is a string describing the error message.
Error *string
}

0 comments on commit 1bc7dd4

Please sign in to comment.