mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-02-15 08:41:16 -05:00
Bumps [github.com/gookit/config/v2](https://github.com/gookit/config) from 2.2.6 to 2.2.7. - [Release notes](https://github.com/gookit/config/releases) - [Commits](https://github.com/gookit/config/compare/v2.2.6...v2.2.7) --- updated-dependencies: - dependency-name: github.com/gookit/config/v2 dependency-version: 2.2.7 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com>
28 lines
574 B
Go
28 lines
574 B
Go
package comdef
|
|
|
|
type (
|
|
// MarshalFunc define
|
|
MarshalFunc func(v any) ([]byte, error)
|
|
|
|
// UnmarshalFunc define
|
|
UnmarshalFunc func(bts []byte, ptr any) error
|
|
)
|
|
|
|
// Serializer interface definition
|
|
type Serializer interface {
|
|
Serialize(v any) ([]byte, error)
|
|
Deserialize(data []byte, v any) error
|
|
}
|
|
|
|
// GoSerializer interface definition
|
|
type GoSerializer interface {
|
|
Marshal(v any) ([]byte, error)
|
|
Unmarshal(v []byte, ptr any) error
|
|
}
|
|
|
|
// Codec interface definition
|
|
type Codec interface {
|
|
Decode(blob []byte, v any) (err error)
|
|
Encode(v any) (out []byte, err error)
|
|
}
|