github.com/Finschia/finschia-sdk@v0.48.1/types/proto.go (about)

     1  package types
     2  
     3  // CustomProtobufType defines the interface custom gogo proto types must implement
     4  // in order to be used as a "customtype" extension.
     5  //
     6  // ref: https://github.com/gogo/protobuf/blob/master/custom_types.md
     7  type CustomProtobufType interface {
     8  	Marshal() ([]byte, error)
     9  	MarshalTo(data []byte) (n int, err error)
    10  	Unmarshal(data []byte) error
    11  	Size() int
    12  
    13  	MarshalJSON() ([]byte, error)
    14  	UnmarshalJSON(data []byte) error
    15  }