github.com/danielpfeifer02/quic-go-prio-packs@v0.41.0-28/internal/mocks/short_header_opener.go (about) 1 // Code generated by MockGen. DO NOT EDIT. 2 // Source: github.com/danielpfeifer02/quic-go-prio-packs/internal/handshake (interfaces: ShortHeaderOpener) 3 // 4 // Generated by this command: 5 // 6 // mockgen -typed -build_flags=-tags=gomock -package mocks -destination short_header_opener.go github.com/danielpfeifer02/quic-go-prio-packs/internal/handshake ShortHeaderOpener 7 // 8 // Package mocks is a generated GoMock package. 9 package mocks 10 11 import ( 12 reflect "reflect" 13 time "time" 14 15 protocol "github.com/danielpfeifer02/quic-go-prio-packs/internal/protocol" 16 gomock "go.uber.org/mock/gomock" 17 ) 18 19 // MockShortHeaderOpener is a mock of ShortHeaderOpener interface. 20 type MockShortHeaderOpener struct { 21 ctrl *gomock.Controller 22 recorder *MockShortHeaderOpenerMockRecorder 23 } 24 25 // MockShortHeaderOpenerMockRecorder is the mock recorder for MockShortHeaderOpener. 26 type MockShortHeaderOpenerMockRecorder struct { 27 mock *MockShortHeaderOpener 28 } 29 30 // NewMockShortHeaderOpener creates a new mock instance. 31 func NewMockShortHeaderOpener(ctrl *gomock.Controller) *MockShortHeaderOpener { 32 mock := &MockShortHeaderOpener{ctrl: ctrl} 33 mock.recorder = &MockShortHeaderOpenerMockRecorder{mock} 34 return mock 35 } 36 37 // EXPECT returns an object that allows the caller to indicate expected use. 38 func (m *MockShortHeaderOpener) EXPECT() *MockShortHeaderOpenerMockRecorder { 39 return m.recorder 40 } 41 42 // DecodePacketNumber mocks base method. 43 func (m *MockShortHeaderOpener) DecodePacketNumber(arg0 protocol.PacketNumber, arg1 protocol.PacketNumberLen) protocol.PacketNumber { 44 m.ctrl.T.Helper() 45 ret := m.ctrl.Call(m, "DecodePacketNumber", arg0, arg1) 46 ret0, _ := ret[0].(protocol.PacketNumber) 47 return ret0 48 } 49 50 // DecodePacketNumber indicates an expected call of DecodePacketNumber. 51 func (mr *MockShortHeaderOpenerMockRecorder) DecodePacketNumber(arg0, arg1 any) *ShortHeaderOpenerDecodePacketNumberCall { 52 mr.mock.ctrl.T.Helper() 53 call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DecodePacketNumber", reflect.TypeOf((*MockShortHeaderOpener)(nil).DecodePacketNumber), arg0, arg1) 54 return &ShortHeaderOpenerDecodePacketNumberCall{Call: call} 55 } 56 57 // ShortHeaderOpenerDecodePacketNumberCall wrap *gomock.Call 58 type ShortHeaderOpenerDecodePacketNumberCall struct { 59 *gomock.Call 60 } 61 62 // Return rewrite *gomock.Call.Return 63 func (c *ShortHeaderOpenerDecodePacketNumberCall) Return(arg0 protocol.PacketNumber) *ShortHeaderOpenerDecodePacketNumberCall { 64 c.Call = c.Call.Return(arg0) 65 return c 66 } 67 68 // Do rewrite *gomock.Call.Do 69 func (c *ShortHeaderOpenerDecodePacketNumberCall) Do(f func(protocol.PacketNumber, protocol.PacketNumberLen) protocol.PacketNumber) *ShortHeaderOpenerDecodePacketNumberCall { 70 c.Call = c.Call.Do(f) 71 return c 72 } 73 74 // DoAndReturn rewrite *gomock.Call.DoAndReturn 75 func (c *ShortHeaderOpenerDecodePacketNumberCall) DoAndReturn(f func(protocol.PacketNumber, protocol.PacketNumberLen) protocol.PacketNumber) *ShortHeaderOpenerDecodePacketNumberCall { 76 c.Call = c.Call.DoAndReturn(f) 77 return c 78 } 79 80 // DecryptHeader mocks base method. 81 func (m *MockShortHeaderOpener) DecryptHeader(arg0 []byte, arg1 *byte, arg2 []byte) { 82 m.ctrl.T.Helper() 83 m.ctrl.Call(m, "DecryptHeader", arg0, arg1, arg2) 84 } 85 86 // DecryptHeader indicates an expected call of DecryptHeader. 87 func (mr *MockShortHeaderOpenerMockRecorder) DecryptHeader(arg0, arg1, arg2 any) *ShortHeaderOpenerDecryptHeaderCall { 88 mr.mock.ctrl.T.Helper() 89 call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DecryptHeader", reflect.TypeOf((*MockShortHeaderOpener)(nil).DecryptHeader), arg0, arg1, arg2) 90 return &ShortHeaderOpenerDecryptHeaderCall{Call: call} 91 } 92 93 // ShortHeaderOpenerDecryptHeaderCall wrap *gomock.Call 94 type ShortHeaderOpenerDecryptHeaderCall struct { 95 *gomock.Call 96 } 97 98 // Return rewrite *gomock.Call.Return 99 func (c *ShortHeaderOpenerDecryptHeaderCall) Return() *ShortHeaderOpenerDecryptHeaderCall { 100 c.Call = c.Call.Return() 101 return c 102 } 103 104 // Do rewrite *gomock.Call.Do 105 func (c *ShortHeaderOpenerDecryptHeaderCall) Do(f func([]byte, *byte, []byte)) *ShortHeaderOpenerDecryptHeaderCall { 106 c.Call = c.Call.Do(f) 107 return c 108 } 109 110 // DoAndReturn rewrite *gomock.Call.DoAndReturn 111 func (c *ShortHeaderOpenerDecryptHeaderCall) DoAndReturn(f func([]byte, *byte, []byte)) *ShortHeaderOpenerDecryptHeaderCall { 112 c.Call = c.Call.DoAndReturn(f) 113 return c 114 } 115 116 // Open mocks base method. 117 func (m *MockShortHeaderOpener) Open(arg0, arg1 []byte, arg2 time.Time, arg3 protocol.PacketNumber, arg4 protocol.KeyPhaseBit, arg5 []byte) ([]byte, error) { 118 m.ctrl.T.Helper() 119 ret := m.ctrl.Call(m, "Open", arg0, arg1, arg2, arg3, arg4, arg5) 120 ret0, _ := ret[0].([]byte) 121 ret1, _ := ret[1].(error) 122 return ret0, ret1 123 } 124 125 // Open indicates an expected call of Open. 126 func (mr *MockShortHeaderOpenerMockRecorder) Open(arg0, arg1, arg2, arg3, arg4, arg5 any) *ShortHeaderOpenerOpenCall { 127 mr.mock.ctrl.T.Helper() 128 call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Open", reflect.TypeOf((*MockShortHeaderOpener)(nil).Open), arg0, arg1, arg2, arg3, arg4, arg5) 129 return &ShortHeaderOpenerOpenCall{Call: call} 130 } 131 132 // ShortHeaderOpenerOpenCall wrap *gomock.Call 133 type ShortHeaderOpenerOpenCall struct { 134 *gomock.Call 135 } 136 137 // Return rewrite *gomock.Call.Return 138 func (c *ShortHeaderOpenerOpenCall) Return(arg0 []byte, arg1 error) *ShortHeaderOpenerOpenCall { 139 c.Call = c.Call.Return(arg0, arg1) 140 return c 141 } 142 143 // Do rewrite *gomock.Call.Do 144 func (c *ShortHeaderOpenerOpenCall) Do(f func([]byte, []byte, time.Time, protocol.PacketNumber, protocol.KeyPhaseBit, []byte) ([]byte, error)) *ShortHeaderOpenerOpenCall { 145 c.Call = c.Call.Do(f) 146 return c 147 } 148 149 // DoAndReturn rewrite *gomock.Call.DoAndReturn 150 func (c *ShortHeaderOpenerOpenCall) DoAndReturn(f func([]byte, []byte, time.Time, protocol.PacketNumber, protocol.KeyPhaseBit, []byte) ([]byte, error)) *ShortHeaderOpenerOpenCall { 151 c.Call = c.Call.DoAndReturn(f) 152 return c 153 }