github.com/keybase/client/go@v0.0.0-20241007131713-f10651d043c8/kbfs/kbfscodec/mock_codec.go (about)

     1  // Automatically generated by MockGen. DO NOT EDIT!
     2  // Source: codec.go
     3  
     4  package kbfscodec
     5  
     6  import (
     7  	gomock "github.com/golang/mock/gomock"
     8  	reflect "reflect"
     9  )
    10  
    11  // Mock of Codec interface
    12  type MockCodec struct {
    13  	ctrl     *gomock.Controller
    14  	recorder *_MockCodecRecorder
    15  }
    16  
    17  // Recorder for MockCodec (not exported)
    18  type _MockCodecRecorder struct {
    19  	mock *MockCodec
    20  }
    21  
    22  func NewMockCodec(ctrl *gomock.Controller) *MockCodec {
    23  	mock := &MockCodec{ctrl: ctrl}
    24  	mock.recorder = &_MockCodecRecorder{mock}
    25  	return mock
    26  }
    27  
    28  func (_m *MockCodec) EXPECT() *_MockCodecRecorder {
    29  	return _m.recorder
    30  }
    31  
    32  func (_m *MockCodec) Decode(buf []byte, obj interface{}) error {
    33  	ret := _m.ctrl.Call(_m, "Decode", buf, obj)
    34  	ret0, _ := ret[0].(error)
    35  	return ret0
    36  }
    37  
    38  func (_mr *_MockCodecRecorder) Decode(arg0, arg1 interface{}) *gomock.Call {
    39  	return _mr.mock.ctrl.RecordCall(_mr.mock, "Decode", arg0, arg1)
    40  }
    41  
    42  func (_m *MockCodec) Encode(obj interface{}) ([]byte, error) {
    43  	ret := _m.ctrl.Call(_m, "Encode", obj)
    44  	ret0, _ := ret[0].([]byte)
    45  	ret1, _ := ret[1].(error)
    46  	return ret0, ret1
    47  }
    48  
    49  func (_mr *_MockCodecRecorder) Encode(arg0 interface{}) *gomock.Call {
    50  	return _mr.mock.ctrl.RecordCall(_mr.mock, "Encode", arg0)
    51  }
    52  
    53  func (_m *MockCodec) RegisterType(rt reflect.Type, code ExtCode) {
    54  	_m.ctrl.Call(_m, "RegisterType", rt, code)
    55  }
    56  
    57  func (_mr *_MockCodecRecorder) RegisterType(arg0, arg1 interface{}) *gomock.Call {
    58  	return _mr.mock.ctrl.RecordCall(_mr.mock, "RegisterType", arg0, arg1)
    59  }
    60  
    61  func (_m *MockCodec) RegisterIfaceSliceType(rt reflect.Type, code ExtCode, typer func(interface{}) reflect.Value) {
    62  	_m.ctrl.Call(_m, "RegisterIfaceSliceType", rt, code, typer)
    63  }
    64  
    65  func (_mr *_MockCodecRecorder) RegisterIfaceSliceType(arg0, arg1, arg2 interface{}) *gomock.Call {
    66  	return _mr.mock.ctrl.RecordCall(_mr.mock, "RegisterIfaceSliceType", arg0, arg1, arg2)
    67  }