aboutsummaryrefslogtreecommitdiff
path: root/plugin/evm/tx.go
diff options
context:
space:
mode:
authorDeterminant <tederminant@gmail.com>2020-08-19 21:20:58 -0400
committerDeterminant <tederminant@gmail.com>2020-08-19 21:20:58 -0400
commit0b934ef60fd652de038a21e6f25691b11cea7121 (patch)
treea034e3e6b2efd527bcfa87883d8f5f29a65b4828 /plugin/evm/tx.go
parentb9b9f523b3a745ca0c5809ea2d1c76c80a4134cb (diff)
remove base_tx.go
Diffstat (limited to 'plugin/evm/tx.go')
-rw-r--r--plugin/evm/tx.go21
1 files changed, 21 insertions, 0 deletions
diff --git a/plugin/evm/tx.go b/plugin/evm/tx.go
index 024e54d..6196eb8 100644
--- a/plugin/evm/tx.go
+++ b/plugin/evm/tx.go
@@ -4,6 +4,7 @@
package evm
import (
+ "errors"
"fmt"
"github.com/ava-labs/gecko/database"
@@ -15,8 +16,28 @@ import (
"github.com/ava-labs/gecko/utils/hashing"
"github.com/ava-labs/gecko/vms/components/verify"
"github.com/ava-labs/gecko/vms/secp256k1fx"
+ "github.com/ava-labs/go-ethereum/common"
)
+// Max size of memo field
+// Don't change without also changing avm.maxMemoSize
+const maxMemoSize = 256
+
+var (
+ errWrongBlockchainID = errors.New("wrong blockchain ID provided")
+ errWrongNetworkID = errors.New("tx was issued with a different network ID")
+ errNilTx = errors.New("tx is nil")
+)
+
+type EVMOutput struct {
+ Address common.Address `serialize:"true" json:"address"`
+ Amount uint64 `serialize:"true" json:"amount"`
+}
+
+func (out *EVMOutput) Verify() error {
+ return nil
+}
+
// UnsignedTx is an unsigned transaction
type UnsignedTx interface {
Initialize(unsignedBytes, signedBytes []byte)