code

package module
v1.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 7, 2022 License: MIT Imports: 4 Imported by: 0

README

code

mock

mockgen -source=coder.go -destination=coder_mock.go --package=code --build_flags=--mod=mod

Documentation

Overview

Package code is a generated GoMock package.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Coder

type Coder interface {
	Encode(interface{}) ([]byte, error)
	Decode([]byte, interface{}) error
	Name() string
}

type Json

type Json struct {
}

func (*Json) Decode

func (j *Json) Decode(data []byte, v interface{}) error

func (*Json) Encode

func (j *Json) Encode(v interface{}) ([]byte, error)

func (*Json) Name

func (j *Json) Name() string

type MockCoder

type MockCoder struct {
	// contains filtered or unexported fields
}

MockCoder is a mock of Coder interface.

func NewMockCoder

func NewMockCoder(ctrl *gomock.Controller) *MockCoder

NewMockCoder creates a new mock instance.

func (*MockCoder) Decode

func (m *MockCoder) Decode(arg0 []byte, arg1 interface{}) error

Decode mocks base method.

func (*MockCoder) EXPECT

func (m *MockCoder) EXPECT() *MockCoderMockRecorder

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockCoder) Encode

func (m *MockCoder) Encode(arg0 interface{}) ([]byte, error)

Encode mocks base method.

func (*MockCoder) Name

func (m *MockCoder) Name() string

Name mocks base method.

type MockCoderMockRecorder

type MockCoderMockRecorder struct {
	// contains filtered or unexported fields
}

MockCoderMockRecorder is the mock recorder for MockCoder.

func (*MockCoderMockRecorder) Decode

func (mr *MockCoderMockRecorder) Decode(arg0, arg1 interface{}) *gomock.Call

Decode indicates an expected call of Decode.

func (*MockCoderMockRecorder) Encode

func (mr *MockCoderMockRecorder) Encode(arg0 interface{}) *gomock.Call

Encode indicates an expected call of Encode.

func (*MockCoderMockRecorder) Name

func (mr *MockCoderMockRecorder) Name() *gomock.Call

Name indicates an expected call of Name.

type MsgPack

type MsgPack struct {
}

func (*MsgPack) Decode

func (j *MsgPack) Decode(data []byte, v interface{}) error

func (*MsgPack) Encode

func (j *MsgPack) Encode(v interface{}) ([]byte, error)

func (*MsgPack) Name

func (j *MsgPack) Name() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL