func (c *EvidenceCdc) UnmarshalEvidence(bz []byte) (exported.Evidence, error) {
	evidence := &Evidence{}
	if err := c.amino.UnmarshalBinaryBare(bz, evidence); err != nil {
		return nil, err
	}
	return evidence.GetEvidence(), nil
}
UnmarshalEvidence returns an Evidence interface from raw encoded evidence
bytes of a Proto-based Evidence type. An error is returned upon decoding
failure.
package types
import (
	"github.com/KuChainNetwork/kuchain/x/evidence/exported"
	"github.com/cosmos/cosmos-sdk/codec"
)
type Codec interface {
	MarshalEvidence(exported.Evidence) ([]byte, error)
	UnmarshalEvidence([]byte) (exported.Evidence, error)
	MarshalEvidenceJSON(exported.Evidence) ([]byte, error)
	UnmarshalEvidenceJSON([]byte) (exported.Evidence, error)
}
type EvidenceCdc struct {
	amino *codec.Codec
}
func NewEveidenceCodec(amino *codec.Codec) *EvidenceCdc {
	return &EvidenceCdc{amino: amino}
}
func (c *EvidenceCdc) MarshalEvidence(evidenceI exported.Evidence) ([]byte, error) {
	evidence := &Evidence{}
	if err := evidence.SetEvidence(evidenceI); err != nil {
		return nil, err
	}
	return c.amino.MarshalBinaryBare(evidence)
}