github.com/MerlinKodo/quic-go@v0.39.2/internal/mocks/crypto_setup.go (about)

     1  // Code generated by MockGen. DO NOT EDIT.
     2  // Source: github.com/MerlinKodo/quic-go/internal/handshake (interfaces: CryptoSetup)
     3  //
     4  // Generated by this command:
     5  //
     6  //	mockgen -build_flags=-tags=gomock -package mocks -destination crypto_setup_tmp.go github.com/MerlinKodo/quic-go/internal/handshake CryptoSetup
     7  //
     8  // Package mocks is a generated GoMock package.
     9  package mocks
    10  
    11  import (
    12  	reflect "reflect"
    13  
    14  	handshake "github.com/MerlinKodo/quic-go/internal/handshake"
    15  	protocol "github.com/MerlinKodo/quic-go/internal/protocol"
    16  	gomock "go.uber.org/mock/gomock"
    17  )
    18  
    19  // MockCryptoSetup is a mock of CryptoSetup interface.
    20  type MockCryptoSetup struct {
    21  	ctrl     *gomock.Controller
    22  	recorder *MockCryptoSetupMockRecorder
    23  }
    24  
    25  // MockCryptoSetupMockRecorder is the mock recorder for MockCryptoSetup.
    26  type MockCryptoSetupMockRecorder struct {
    27  	mock *MockCryptoSetup
    28  }
    29  
    30  // NewMockCryptoSetup creates a new mock instance.
    31  func NewMockCryptoSetup(ctrl *gomock.Controller) *MockCryptoSetup {
    32  	mock := &MockCryptoSetup{ctrl: ctrl}
    33  	mock.recorder = &MockCryptoSetupMockRecorder{mock}
    34  	return mock
    35  }
    36  
    37  // EXPECT returns an object that allows the caller to indicate expected use.
    38  func (m *MockCryptoSetup) EXPECT() *MockCryptoSetupMockRecorder {
    39  	return m.recorder
    40  }
    41  
    42  // ChangeConnectionID mocks base method.
    43  func (m *MockCryptoSetup) ChangeConnectionID(arg0 protocol.ConnectionID) {
    44  	m.ctrl.T.Helper()
    45  	m.ctrl.Call(m, "ChangeConnectionID", arg0)
    46  }
    47  
    48  // ChangeConnectionID indicates an expected call of ChangeConnectionID.
    49  func (mr *MockCryptoSetupMockRecorder) ChangeConnectionID(arg0 any) *gomock.Call {
    50  	mr.mock.ctrl.T.Helper()
    51  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ChangeConnectionID", reflect.TypeOf((*MockCryptoSetup)(nil).ChangeConnectionID), arg0)
    52  }
    53  
    54  // Close mocks base method.
    55  func (m *MockCryptoSetup) Close() error {
    56  	m.ctrl.T.Helper()
    57  	ret := m.ctrl.Call(m, "Close")
    58  	ret0, _ := ret[0].(error)
    59  	return ret0
    60  }
    61  
    62  // Close indicates an expected call of Close.
    63  func (mr *MockCryptoSetupMockRecorder) Close() *gomock.Call {
    64  	mr.mock.ctrl.T.Helper()
    65  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Close", reflect.TypeOf((*MockCryptoSetup)(nil).Close))
    66  }
    67  
    68  // ConnectionState mocks base method.
    69  func (m *MockCryptoSetup) ConnectionState() handshake.ConnectionState {
    70  	m.ctrl.T.Helper()
    71  	ret := m.ctrl.Call(m, "ConnectionState")
    72  	ret0, _ := ret[0].(handshake.ConnectionState)
    73  	return ret0
    74  }
    75  
    76  // ConnectionState indicates an expected call of ConnectionState.
    77  func (mr *MockCryptoSetupMockRecorder) ConnectionState() *gomock.Call {
    78  	mr.mock.ctrl.T.Helper()
    79  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ConnectionState", reflect.TypeOf((*MockCryptoSetup)(nil).ConnectionState))
    80  }
    81  
    82  // DiscardInitialKeys mocks base method.
    83  func (m *MockCryptoSetup) DiscardInitialKeys() {
    84  	m.ctrl.T.Helper()
    85  	m.ctrl.Call(m, "DiscardInitialKeys")
    86  }
    87  
    88  // DiscardInitialKeys indicates an expected call of DiscardInitialKeys.
    89  func (mr *MockCryptoSetupMockRecorder) DiscardInitialKeys() *gomock.Call {
    90  	mr.mock.ctrl.T.Helper()
    91  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DiscardInitialKeys", reflect.TypeOf((*MockCryptoSetup)(nil).DiscardInitialKeys))
    92  }
    93  
    94  // Get0RTTOpener mocks base method.
    95  func (m *MockCryptoSetup) Get0RTTOpener() (handshake.LongHeaderOpener, error) {
    96  	m.ctrl.T.Helper()
    97  	ret := m.ctrl.Call(m, "Get0RTTOpener")
    98  	ret0, _ := ret[0].(handshake.LongHeaderOpener)
    99  	ret1, _ := ret[1].(error)
   100  	return ret0, ret1
   101  }
   102  
   103  // Get0RTTOpener indicates an expected call of Get0RTTOpener.
   104  func (mr *MockCryptoSetupMockRecorder) Get0RTTOpener() *gomock.Call {
   105  	mr.mock.ctrl.T.Helper()
   106  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Get0RTTOpener", reflect.TypeOf((*MockCryptoSetup)(nil).Get0RTTOpener))
   107  }
   108  
   109  // Get0RTTSealer mocks base method.
   110  func (m *MockCryptoSetup) Get0RTTSealer() (handshake.LongHeaderSealer, error) {
   111  	m.ctrl.T.Helper()
   112  	ret := m.ctrl.Call(m, "Get0RTTSealer")
   113  	ret0, _ := ret[0].(handshake.LongHeaderSealer)
   114  	ret1, _ := ret[1].(error)
   115  	return ret0, ret1
   116  }
   117  
   118  // Get0RTTSealer indicates an expected call of Get0RTTSealer.
   119  func (mr *MockCryptoSetupMockRecorder) Get0RTTSealer() *gomock.Call {
   120  	mr.mock.ctrl.T.Helper()
   121  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Get0RTTSealer", reflect.TypeOf((*MockCryptoSetup)(nil).Get0RTTSealer))
   122  }
   123  
   124  // Get1RTTOpener mocks base method.
   125  func (m *MockCryptoSetup) Get1RTTOpener() (handshake.ShortHeaderOpener, error) {
   126  	m.ctrl.T.Helper()
   127  	ret := m.ctrl.Call(m, "Get1RTTOpener")
   128  	ret0, _ := ret[0].(handshake.ShortHeaderOpener)
   129  	ret1, _ := ret[1].(error)
   130  	return ret0, ret1
   131  }
   132  
   133  // Get1RTTOpener indicates an expected call of Get1RTTOpener.
   134  func (mr *MockCryptoSetupMockRecorder) Get1RTTOpener() *gomock.Call {
   135  	mr.mock.ctrl.T.Helper()
   136  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Get1RTTOpener", reflect.TypeOf((*MockCryptoSetup)(nil).Get1RTTOpener))
   137  }
   138  
   139  // Get1RTTSealer mocks base method.
   140  func (m *MockCryptoSetup) Get1RTTSealer() (handshake.ShortHeaderSealer, error) {
   141  	m.ctrl.T.Helper()
   142  	ret := m.ctrl.Call(m, "Get1RTTSealer")
   143  	ret0, _ := ret[0].(handshake.ShortHeaderSealer)
   144  	ret1, _ := ret[1].(error)
   145  	return ret0, ret1
   146  }
   147  
   148  // Get1RTTSealer indicates an expected call of Get1RTTSealer.
   149  func (mr *MockCryptoSetupMockRecorder) Get1RTTSealer() *gomock.Call {
   150  	mr.mock.ctrl.T.Helper()
   151  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Get1RTTSealer", reflect.TypeOf((*MockCryptoSetup)(nil).Get1RTTSealer))
   152  }
   153  
   154  // GetHandshakeOpener mocks base method.
   155  func (m *MockCryptoSetup) GetHandshakeOpener() (handshake.LongHeaderOpener, error) {
   156  	m.ctrl.T.Helper()
   157  	ret := m.ctrl.Call(m, "GetHandshakeOpener")
   158  	ret0, _ := ret[0].(handshake.LongHeaderOpener)
   159  	ret1, _ := ret[1].(error)
   160  	return ret0, ret1
   161  }
   162  
   163  // GetHandshakeOpener indicates an expected call of GetHandshakeOpener.
   164  func (mr *MockCryptoSetupMockRecorder) GetHandshakeOpener() *gomock.Call {
   165  	mr.mock.ctrl.T.Helper()
   166  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetHandshakeOpener", reflect.TypeOf((*MockCryptoSetup)(nil).GetHandshakeOpener))
   167  }
   168  
   169  // GetHandshakeSealer mocks base method.
   170  func (m *MockCryptoSetup) GetHandshakeSealer() (handshake.LongHeaderSealer, error) {
   171  	m.ctrl.T.Helper()
   172  	ret := m.ctrl.Call(m, "GetHandshakeSealer")
   173  	ret0, _ := ret[0].(handshake.LongHeaderSealer)
   174  	ret1, _ := ret[1].(error)
   175  	return ret0, ret1
   176  }
   177  
   178  // GetHandshakeSealer indicates an expected call of GetHandshakeSealer.
   179  func (mr *MockCryptoSetupMockRecorder) GetHandshakeSealer() *gomock.Call {
   180  	mr.mock.ctrl.T.Helper()
   181  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetHandshakeSealer", reflect.TypeOf((*MockCryptoSetup)(nil).GetHandshakeSealer))
   182  }
   183  
   184  // GetInitialOpener mocks base method.
   185  func (m *MockCryptoSetup) GetInitialOpener() (handshake.LongHeaderOpener, error) {
   186  	m.ctrl.T.Helper()
   187  	ret := m.ctrl.Call(m, "GetInitialOpener")
   188  	ret0, _ := ret[0].(handshake.LongHeaderOpener)
   189  	ret1, _ := ret[1].(error)
   190  	return ret0, ret1
   191  }
   192  
   193  // GetInitialOpener indicates an expected call of GetInitialOpener.
   194  func (mr *MockCryptoSetupMockRecorder) GetInitialOpener() *gomock.Call {
   195  	mr.mock.ctrl.T.Helper()
   196  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetInitialOpener", reflect.TypeOf((*MockCryptoSetup)(nil).GetInitialOpener))
   197  }
   198  
   199  // GetInitialSealer mocks base method.
   200  func (m *MockCryptoSetup) GetInitialSealer() (handshake.LongHeaderSealer, error) {
   201  	m.ctrl.T.Helper()
   202  	ret := m.ctrl.Call(m, "GetInitialSealer")
   203  	ret0, _ := ret[0].(handshake.LongHeaderSealer)
   204  	ret1, _ := ret[1].(error)
   205  	return ret0, ret1
   206  }
   207  
   208  // GetInitialSealer indicates an expected call of GetInitialSealer.
   209  func (mr *MockCryptoSetupMockRecorder) GetInitialSealer() *gomock.Call {
   210  	mr.mock.ctrl.T.Helper()
   211  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetInitialSealer", reflect.TypeOf((*MockCryptoSetup)(nil).GetInitialSealer))
   212  }
   213  
   214  // GetSessionTicket mocks base method.
   215  func (m *MockCryptoSetup) GetSessionTicket() ([]byte, error) {
   216  	m.ctrl.T.Helper()
   217  	ret := m.ctrl.Call(m, "GetSessionTicket")
   218  	ret0, _ := ret[0].([]byte)
   219  	ret1, _ := ret[1].(error)
   220  	return ret0, ret1
   221  }
   222  
   223  // GetSessionTicket indicates an expected call of GetSessionTicket.
   224  func (mr *MockCryptoSetupMockRecorder) GetSessionTicket() *gomock.Call {
   225  	mr.mock.ctrl.T.Helper()
   226  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetSessionTicket", reflect.TypeOf((*MockCryptoSetup)(nil).GetSessionTicket))
   227  }
   228  
   229  // HandleMessage mocks base method.
   230  func (m *MockCryptoSetup) HandleMessage(arg0 []byte, arg1 protocol.EncryptionLevel) error {
   231  	m.ctrl.T.Helper()
   232  	ret := m.ctrl.Call(m, "HandleMessage", arg0, arg1)
   233  	ret0, _ := ret[0].(error)
   234  	return ret0
   235  }
   236  
   237  // HandleMessage indicates an expected call of HandleMessage.
   238  func (mr *MockCryptoSetupMockRecorder) HandleMessage(arg0, arg1 any) *gomock.Call {
   239  	mr.mock.ctrl.T.Helper()
   240  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "HandleMessage", reflect.TypeOf((*MockCryptoSetup)(nil).HandleMessage), arg0, arg1)
   241  }
   242  
   243  // NextEvent mocks base method.
   244  func (m *MockCryptoSetup) NextEvent() handshake.Event {
   245  	m.ctrl.T.Helper()
   246  	ret := m.ctrl.Call(m, "NextEvent")
   247  	ret0, _ := ret[0].(handshake.Event)
   248  	return ret0
   249  }
   250  
   251  // NextEvent indicates an expected call of NextEvent.
   252  func (mr *MockCryptoSetupMockRecorder) NextEvent() *gomock.Call {
   253  	mr.mock.ctrl.T.Helper()
   254  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NextEvent", reflect.TypeOf((*MockCryptoSetup)(nil).NextEvent))
   255  }
   256  
   257  // SetHandshakeConfirmed mocks base method.
   258  func (m *MockCryptoSetup) SetHandshakeConfirmed() {
   259  	m.ctrl.T.Helper()
   260  	m.ctrl.Call(m, "SetHandshakeConfirmed")
   261  }
   262  
   263  // SetHandshakeConfirmed indicates an expected call of SetHandshakeConfirmed.
   264  func (mr *MockCryptoSetupMockRecorder) SetHandshakeConfirmed() *gomock.Call {
   265  	mr.mock.ctrl.T.Helper()
   266  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetHandshakeConfirmed", reflect.TypeOf((*MockCryptoSetup)(nil).SetHandshakeConfirmed))
   267  }
   268  
   269  // SetLargest1RTTAcked mocks base method.
   270  func (m *MockCryptoSetup) SetLargest1RTTAcked(arg0 protocol.PacketNumber) error {
   271  	m.ctrl.T.Helper()
   272  	ret := m.ctrl.Call(m, "SetLargest1RTTAcked", arg0)
   273  	ret0, _ := ret[0].(error)
   274  	return ret0
   275  }
   276  
   277  // SetLargest1RTTAcked indicates an expected call of SetLargest1RTTAcked.
   278  func (mr *MockCryptoSetupMockRecorder) SetLargest1RTTAcked(arg0 any) *gomock.Call {
   279  	mr.mock.ctrl.T.Helper()
   280  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetLargest1RTTAcked", reflect.TypeOf((*MockCryptoSetup)(nil).SetLargest1RTTAcked), arg0)
   281  }
   282  
   283  // StartHandshake mocks base method.
   284  func (m *MockCryptoSetup) StartHandshake() error {
   285  	m.ctrl.T.Helper()
   286  	ret := m.ctrl.Call(m, "StartHandshake")
   287  	ret0, _ := ret[0].(error)
   288  	return ret0
   289  }
   290  
   291  // StartHandshake indicates an expected call of StartHandshake.
   292  func (mr *MockCryptoSetupMockRecorder) StartHandshake() *gomock.Call {
   293  	mr.mock.ctrl.T.Helper()
   294  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "StartHandshake", reflect.TypeOf((*MockCryptoSetup)(nil).StartHandshake))
   295  }