github.com/Finschia/finschia-sdk@v0.48.1/x/bank/legacy/v040/types.go (about)

     1  package v040
     2  
     3  import (
     4  	"github.com/golang/protobuf/proto" //nolint:staticcheck
     5  
     6  	codectypes "github.com/Finschia/finschia-sdk/codec/types"
     7  	"github.com/Finschia/finschia-sdk/x/bank/types"
     8  )
     9  
    10  // SupplyI defines an inflationary supply interface for modules that handle
    11  // token supply.
    12  // It is copy-pasted from:
    13  // https://github.com/cosmos/cosmos-sdk/blob/v042.3/x/bank/exported/exported.go
    14  // where we stripped off the unnecessary methods.
    15  //
    16  // It is used in the migration script, because we save this interface as an Any
    17  // in the supply state.
    18  //
    19  // Deprecated.
    20  type SupplyI interface {
    21  	proto.Message
    22  }
    23  
    24  // RegisterInterfaces registers interfaces required for the v0.40 migrations.
    25  func RegisterInterfaces(registry codectypes.InterfaceRegistry) {
    26  	registry.RegisterInterface(
    27  		"cosmos.bank.v1beta1.SupplyI",
    28  		(*SupplyI)(nil),
    29  		&types.Supply{}, //nolint:staticcheck
    30  	)
    31  }