// Code generated by mockery v2.53.5. DO NOT EDIT.

package net

import (
	net "net"

	mock "github.com/stretchr/testify/mock"

	time "time"
)

// MockConn is an autogenerated mock type for the Conn type
type MockConn struct {
	mock.Mock
}

type MockConn_Expecter struct {
	mock *mock.Mock
}

func (_m *MockConn) EXPECT() *MockConn_Expecter {
	return &MockConn_Expecter{mock: &_m.Mock}
}

// Close provides a mock function with no fields
func (_m *MockConn) Close() error {
	ret := _m.Called()

	if len(ret) == 0 {
		panic("no return value specified for Close")
	}

	var r0 error
	if rf, ok := ret.Get(0).(func() error); ok {
		r0 = rf()
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// MockConn_Close_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Close'
type MockConn_Close_Call struct {
	*mock.Call
}

// Close is a helper method to define mock.On call
func (_e *MockConn_Expecter) Close() *MockConn_Close_Call {
	return &MockConn_Close_Call{Call: _e.mock.On("Close")}
}

func (_c *MockConn_Close_Call) Run(run func()) *MockConn_Close_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run()
	})
	return _c
}

func (_c *MockConn_Close_Call) Return(_a0 error) *MockConn_Close_Call {
	_c.Call.Return(_a0)
	return _c
}

func (_c *MockConn_Close_Call) RunAndReturn(run func() error) *MockConn_Close_Call {
	_c.Call.Return(run)
	return _c
}

// LocalAddr provides a mock function with no fields
func (_m *MockConn) LocalAddr() net.Addr {
	ret := _m.Called()

	if len(ret) == 0 {
		panic("no return value specified for LocalAddr")
	}

	var r0 net.Addr
	if rf, ok := ret.Get(0).(func() net.Addr); ok {
		r0 = rf()
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(net.Addr)
		}
	}

	return r0
}

// MockConn_LocalAddr_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'LocalAddr'
type MockConn_LocalAddr_Call struct {
	*mock.Call
}

// LocalAddr is a helper method to define mock.On call
func (_e *MockConn_Expecter) LocalAddr() *MockConn_LocalAddr_Call {
	return &MockConn_LocalAddr_Call{Call: _e.mock.On("LocalAddr")}
}

func (_c *MockConn_LocalAddr_Call) Run(run func()) *MockConn_LocalAddr_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run()
	})
	return _c
}

func (_c *MockConn_LocalAddr_Call) Return(_a0 net.Addr) *MockConn_LocalAddr_Call {
	_c.Call.Return(_a0)
	return _c
}

func (_c *MockConn_LocalAddr_Call) RunAndReturn(run func() net.Addr) *MockConn_LocalAddr_Call {
	_c.Call.Return(run)
	return _c
}

// Read provides a mock function with given fields: b
func (_m *MockConn) Read(b []byte) (int, error) {
	ret := _m.Called(b)

	if len(ret) == 0 {
		panic("no return value specified for Read")
	}

	var r0 int
	var r1 error
	if rf, ok := ret.Get(0).(func([]byte) (int, error)); ok {
		return rf(b)
	}
	if rf, ok := ret.Get(0).(func([]byte) int); ok {
		r0 = rf(b)
	} else {
		r0 = ret.Get(0).(int)
	}

	if rf, ok := ret.Get(1).(func([]byte) error); ok {
		r1 = rf(b)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// MockConn_Read_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Read'
type MockConn_Read_Call struct {
	*mock.Call
}

// Read is a helper method to define mock.On call
//   - b []byte
func (_e *MockConn_Expecter) Read(b interface{}) *MockConn_Read_Call {
	return &MockConn_Read_Call{Call: _e.mock.On("Read", b)}
}

func (_c *MockConn_Read_Call) Run(run func(b []byte)) *MockConn_Read_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].([]byte))
	})
	return _c
}

func (_c *MockConn_Read_Call) Return(n int, err error) *MockConn_Read_Call {
	_c.Call.Return(n, err)
	return _c
}

func (_c *MockConn_Read_Call) RunAndReturn(run func([]byte) (int, error)) *MockConn_Read_Call {
	_c.Call.Return(run)
	return _c
}

// RemoteAddr provides a mock function with no fields
func (_m *MockConn) RemoteAddr() net.Addr {
	ret := _m.Called()

	if len(ret) == 0 {
		panic("no return value specified for RemoteAddr")
	}

	var r0 net.Addr
	if rf, ok := ret.Get(0).(func() net.Addr); ok {
		r0 = rf()
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(net.Addr)
		}
	}

	return r0
}

// MockConn_RemoteAddr_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RemoteAddr'
type MockConn_RemoteAddr_Call struct {
	*mock.Call
}

// RemoteAddr is a helper method to define mock.On call
func (_e *MockConn_Expecter) RemoteAddr() *MockConn_RemoteAddr_Call {
	return &MockConn_RemoteAddr_Call{Call: _e.mock.On("RemoteAddr")}
}

func (_c *MockConn_RemoteAddr_Call) Run(run func()) *MockConn_RemoteAddr_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run()
	})
	return _c
}

func (_c *MockConn_RemoteAddr_Call) Return(_a0 net.Addr) *MockConn_RemoteAddr_Call {
	_c.Call.Return(_a0)
	return _c
}

func (_c *MockConn_RemoteAddr_Call) RunAndReturn(run func() net.Addr) *MockConn_RemoteAddr_Call {
	_c.Call.Return(run)
	return _c
}

// SetDeadline provides a mock function with given fields: t
func (_m *MockConn) SetDeadline(t time.Time) error {
	ret := _m.Called(t)

	if len(ret) == 0 {
		panic("no return value specified for SetDeadline")
	}

	var r0 error
	if rf, ok := ret.Get(0).(func(time.Time) error); ok {
		r0 = rf(t)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// MockConn_SetDeadline_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SetDeadline'
type MockConn_SetDeadline_Call struct {
	*mock.Call
}

// SetDeadline is a helper method to define mock.On call
//   - t time.Time
func (_e *MockConn_Expecter) SetDeadline(t interface{}) *MockConn_SetDeadline_Call {
	return &MockConn_SetDeadline_Call{Call: _e.mock.On("SetDeadline", t)}
}

func (_c *MockConn_SetDeadline_Call) Run(run func(t time.Time)) *MockConn_SetDeadline_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(time.Time))
	})
	return _c
}

func (_c *MockConn_SetDeadline_Call) Return(_a0 error) *MockConn_SetDeadline_Call {
	_c.Call.Return(_a0)
	return _c
}

func (_c *MockConn_SetDeadline_Call) RunAndReturn(run func(time.Time) error) *MockConn_SetDeadline_Call {
	_c.Call.Return(run)
	return _c
}

// SetReadDeadline provides a mock function with given fields: t
func (_m *MockConn) SetReadDeadline(t time.Time) error {
	ret := _m.Called(t)

	if len(ret) == 0 {
		panic("no return value specified for SetReadDeadline")
	}

	var r0 error
	if rf, ok := ret.Get(0).(func(time.Time) error); ok {
		r0 = rf(t)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// MockConn_SetReadDeadline_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SetReadDeadline'
type MockConn_SetReadDeadline_Call struct {
	*mock.Call
}

// SetReadDeadline is a helper method to define mock.On call
//   - t time.Time
func (_e *MockConn_Expecter) SetReadDeadline(t interface{}) *MockConn_SetReadDeadline_Call {
	return &MockConn_SetReadDeadline_Call{Call: _e.mock.On("SetReadDeadline", t)}
}

func (_c *MockConn_SetReadDeadline_Call) Run(run func(t time.Time)) *MockConn_SetReadDeadline_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(time.Time))
	})
	return _c
}

func (_c *MockConn_SetReadDeadline_Call) Return(_a0 error) *MockConn_SetReadDeadline_Call {
	_c.Call.Return(_a0)
	return _c
}

func (_c *MockConn_SetReadDeadline_Call) RunAndReturn(run func(time.Time) error) *MockConn_SetReadDeadline_Call {
	_c.Call.Return(run)
	return _c
}

// SetWriteDeadline provides a mock function with given fields: t
func (_m *MockConn) SetWriteDeadline(t time.Time) error {
	ret := _m.Called(t)

	if len(ret) == 0 {
		panic("no return value specified for SetWriteDeadline")
	}

	var r0 error
	if rf, ok := ret.Get(0).(func(time.Time) error); ok {
		r0 = rf(t)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// MockConn_SetWriteDeadline_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SetWriteDeadline'
type MockConn_SetWriteDeadline_Call struct {
	*mock.Call
}

// SetWriteDeadline is a helper method to define mock.On call
//   - t time.Time
func (_e *MockConn_Expecter) SetWriteDeadline(t interface{}) *MockConn_SetWriteDeadline_Call {
	return &MockConn_SetWriteDeadline_Call{Call: _e.mock.On("SetWriteDeadline", t)}
}

func (_c *MockConn_SetWriteDeadline_Call) Run(run func(t time.Time)) *MockConn_SetWriteDeadline_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(time.Time))
	})
	return _c
}

func (_c *MockConn_SetWriteDeadline_Call) Return(_a0 error) *MockConn_SetWriteDeadline_Call {
	_c.Call.Return(_a0)
	return _c
}

func (_c *MockConn_SetWriteDeadline_Call) RunAndReturn(run func(time.Time) error) *MockConn_SetWriteDeadline_Call {
	_c.Call.Return(run)
	return _c
}

// Write provides a mock function with given fields: b
func (_m *MockConn) Write(b []byte) (int, error) {
	ret := _m.Called(b)

	if len(ret) == 0 {
		panic("no return value specified for Write")
	}

	var r0 int
	var r1 error
	if rf, ok := ret.Get(0).(func([]byte) (int, error)); ok {
		return rf(b)
	}
	if rf, ok := ret.Get(0).(func([]byte) int); ok {
		r0 = rf(b)
	} else {
		r0 = ret.Get(0).(int)
	}

	if rf, ok := ret.Get(1).(func([]byte) error); ok {
		r1 = rf(b)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// MockConn_Write_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Write'
type MockConn_Write_Call struct {
	*mock.Call
}

// Write is a helper method to define mock.On call
//   - b []byte
func (_e *MockConn_Expecter) Write(b interface{}) *MockConn_Write_Call {
	return &MockConn_Write_Call{Call: _e.mock.On("Write", b)}
}

func (_c *MockConn_Write_Call) Run(run func(b []byte)) *MockConn_Write_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].([]byte))
	})
	return _c
}

func (_c *MockConn_Write_Call) Return(n int, err error) *MockConn_Write_Call {
	_c.Call.Return(n, err)
	return _c
}

func (_c *MockConn_Write_Call) RunAndReturn(run func([]byte) (int, error)) *MockConn_Write_Call {
	_c.Call.Return(run)
	return _c
}

// NewMockConn creates a new instance of MockConn. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewMockConn(t interface {
	mock.TestingT
	Cleanup(func())
}) *MockConn {
	mock := &MockConn{}
	mock.Mock.Test(t)

	t.Cleanup(func() { mock.AssertExpectations(t) })

	return mock
}
