2018-11-28 22:19:22 +00:00
|
|
|
package types
|
|
|
|
|
2019-08-11 14:50:30 +00:00
|
|
|
import (
|
|
|
|
"github.com/cosmos/cosmos-sdk/codec"
|
|
|
|
)
|
2018-11-28 22:19:22 +00:00
|
|
|
|
2020-04-16 15:47:39 +00:00
|
|
|
// ModuleCdc defines the evm module's codec
|
2019-07-08 16:02:20 +00:00
|
|
|
var ModuleCdc = codec.New()
|
2018-11-28 22:19:22 +00:00
|
|
|
|
2020-04-16 15:47:39 +00:00
|
|
|
// RegisterCodec registers all the necessary types and interfaces for the
|
|
|
|
// evm module
|
2018-11-28 22:19:22 +00:00
|
|
|
func RegisterCodec(cdc *codec.Codec) {
|
2020-04-01 18:49:21 +00:00
|
|
|
cdc.RegisterConcrete(MsgEthereumTx{}, "ethermint/MsgEthereumTx", nil)
|
|
|
|
cdc.RegisterConcrete(MsgEthermint{}, "ethermint/MsgEthermint", nil)
|
2020-04-23 15:49:25 +00:00
|
|
|
cdc.RegisterConcrete(TxData{}, "ethermint/TxData", nil)
|
2020-09-02 19:41:05 +00:00
|
|
|
cdc.RegisterConcrete(ChainConfig{}, "ethermint/ChainConfig", nil)
|
2018-11-28 22:19:22 +00:00
|
|
|
}
|
2020-04-16 15:47:39 +00:00
|
|
|
|
|
|
|
func init() {
|
|
|
|
RegisterCodec(ModuleCdc)
|
|
|
|
codec.RegisterCrypto(ModuleCdc)
|
|
|
|
ModuleCdc.Seal()
|
|
|
|
}
|