Documentation
¶
Overview ¶
Package openflow is a generated GoMock package.
Package openflow is a generated GoMock package.
Package openflow is a generated GoMock package.
Index ¶
- type MockCmd
- func (m *MockCmd) CombinedOutput() ([]byte, error)
- func (m *MockCmd) EXPECT() *MockCmdMockRecorder
- func (m *MockCmd) Output() ([]byte, error)
- func (m *MockCmd) Run() error
- func (m *MockCmd) SetDir(dir string)
- func (m *MockCmd) SetEnv(env []string)
- func (m *MockCmd) SetStderr(out io.Writer)
- func (m *MockCmd) SetStdin(in io.Reader)
- func (m *MockCmd) SetStdout(out io.Writer)
- func (m *MockCmd) Start() error
- func (m *MockCmd) StderrPipe() (io.ReadCloser, error)
- func (m *MockCmd) StdoutPipe() (io.ReadCloser, error)
- func (m *MockCmd) Stop()
- func (m *MockCmd) Wait() error
- type MockCmdMockRecorder
- func (mr *MockCmdMockRecorder) CombinedOutput() *gomock.Call
- func (mr *MockCmdMockRecorder) Output() *gomock.Call
- func (mr *MockCmdMockRecorder) Run() *gomock.Call
- func (mr *MockCmdMockRecorder) SetDir(dir any) *gomock.Call
- func (mr *MockCmdMockRecorder) SetEnv(env any) *gomock.Call
- func (mr *MockCmdMockRecorder) SetStderr(out any) *gomock.Call
- func (mr *MockCmdMockRecorder) SetStdin(in any) *gomock.Call
- func (mr *MockCmdMockRecorder) SetStdout(out any) *gomock.Call
- func (mr *MockCmdMockRecorder) Start() *gomock.Call
- func (mr *MockCmdMockRecorder) StderrPipe() *gomock.Call
- func (mr *MockCmdMockRecorder) StdoutPipe() *gomock.Call
- func (mr *MockCmdMockRecorder) Stop() *gomock.Call
- func (mr *MockCmdMockRecorder) Wait() *gomock.Call
- type MockInterface
- type MockInterfaceMockRecorder
- type MockOpenFlowAPI
- type MockOpenFlowAPIMockRecorder
- type OpenFlow
- type OpenFlowAPI
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockCmd ¶
type MockCmd struct {
// contains filtered or unexported fields
}
MockCmd is a mock of Cmd interface.
func NewMockCmd ¶
func NewMockCmd(ctrl *gomock.Controller) *MockCmd
NewMockCmd creates a new mock instance.
func (*MockCmd) CombinedOutput ¶
CombinedOutput mocks base method.
func (*MockCmd) EXPECT ¶
func (m *MockCmd) EXPECT() *MockCmdMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockCmd) StderrPipe ¶
func (m *MockCmd) StderrPipe() (io.ReadCloser, error)
StderrPipe mocks base method.
func (*MockCmd) StdoutPipe ¶
func (m *MockCmd) StdoutPipe() (io.ReadCloser, error)
StdoutPipe mocks base method.
type MockCmdMockRecorder ¶
type MockCmdMockRecorder struct {
// contains filtered or unexported fields
}
MockCmdMockRecorder is the mock recorder for MockCmd.
func (*MockCmdMockRecorder) CombinedOutput ¶
func (mr *MockCmdMockRecorder) CombinedOutput() *gomock.Call
CombinedOutput indicates an expected call of CombinedOutput.
func (*MockCmdMockRecorder) Output ¶
func (mr *MockCmdMockRecorder) Output() *gomock.Call
Output indicates an expected call of Output.
func (*MockCmdMockRecorder) Run ¶
func (mr *MockCmdMockRecorder) Run() *gomock.Call
Run indicates an expected call of Run.
func (*MockCmdMockRecorder) SetDir ¶
func (mr *MockCmdMockRecorder) SetDir(dir any) *gomock.Call
SetDir indicates an expected call of SetDir.
func (*MockCmdMockRecorder) SetEnv ¶
func (mr *MockCmdMockRecorder) SetEnv(env any) *gomock.Call
SetEnv indicates an expected call of SetEnv.
func (*MockCmdMockRecorder) SetStderr ¶
func (mr *MockCmdMockRecorder) SetStderr(out any) *gomock.Call
SetStderr indicates an expected call of SetStderr.
func (*MockCmdMockRecorder) SetStdin ¶
func (mr *MockCmdMockRecorder) SetStdin(in any) *gomock.Call
SetStdin indicates an expected call of SetStdin.
func (*MockCmdMockRecorder) SetStdout ¶
func (mr *MockCmdMockRecorder) SetStdout(out any) *gomock.Call
SetStdout indicates an expected call of SetStdout.
func (*MockCmdMockRecorder) Start ¶
func (mr *MockCmdMockRecorder) Start() *gomock.Call
Start indicates an expected call of Start.
func (*MockCmdMockRecorder) StderrPipe ¶
func (mr *MockCmdMockRecorder) StderrPipe() *gomock.Call
StderrPipe indicates an expected call of StderrPipe.
func (*MockCmdMockRecorder) StdoutPipe ¶
func (mr *MockCmdMockRecorder) StdoutPipe() *gomock.Call
StdoutPipe indicates an expected call of StdoutPipe.
func (*MockCmdMockRecorder) Stop ¶
func (mr *MockCmdMockRecorder) Stop() *gomock.Call
Stop indicates an expected call of Stop.
func (*MockCmdMockRecorder) Wait ¶
func (mr *MockCmdMockRecorder) Wait() *gomock.Call
Wait indicates an expected call of Wait.
type MockInterface ¶
type MockInterface struct {
// contains filtered or unexported fields
}
MockInterface is a mock of Interface interface.
func NewMockInterface ¶
func NewMockInterface(ctrl *gomock.Controller) *MockInterface
NewMockInterface creates a new mock instance.
func (*MockInterface) Command ¶
func (m *MockInterface) Command(cmd string, args ...string) exec.Cmd
Command mocks base method.
func (*MockInterface) CommandContext ¶
CommandContext mocks base method.
func (*MockInterface) EXPECT ¶
func (m *MockInterface) EXPECT() *MockInterfaceMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockInterfaceMockRecorder ¶
type MockInterfaceMockRecorder struct {
// contains filtered or unexported fields
}
MockInterfaceMockRecorder is the mock recorder for MockInterface.
func (*MockInterfaceMockRecorder) Command ¶
func (mr *MockInterfaceMockRecorder) Command(cmd any, args ...any) *gomock.Call
Command indicates an expected call of Command.
func (*MockInterfaceMockRecorder) CommandContext ¶
func (mr *MockInterfaceMockRecorder) CommandContext(ctx, cmd any, args ...any) *gomock.Call
CommandContext indicates an expected call of CommandContext.
type MockOpenFlowAPI ¶
type MockOpenFlowAPI struct {
// contains filtered or unexported fields
}
MockOpenFlowAPI is a mock of OpenFlowAPI interface.
func NewMockOpenFlowAPI ¶
func NewMockOpenFlowAPI(ctrl *gomock.Controller) *MockOpenFlowAPI
NewMockOpenFlowAPI creates a new mock instance.
func (*MockOpenFlowAPI) AddFlows ¶
func (m *MockOpenFlowAPI) AddFlows(ctx context.Context, flows, bridgeName string) error
AddFlows mocks base method.
func (*MockOpenFlowAPI) AddMeter ¶
func (m *MockOpenFlowAPI) AddMeter(ctx context.Context, meter, bridgeName string) error
AddMeter mocks base method.
func (*MockOpenFlowAPI) EXPECT ¶
func (m *MockOpenFlowAPI) EXPECT() *MockOpenFlowAPIMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockOpenFlowAPIMockRecorder ¶
type MockOpenFlowAPIMockRecorder struct {
// contains filtered or unexported fields
}
MockOpenFlowAPIMockRecorder is the mock recorder for MockOpenFlowAPI.
type OpenFlow ¶
type OpenFlow struct {
Exec kexec.Interface
OVSOfctlPath string
BridgeName string
// contains filtered or unexported fields
}
func (*OpenFlow) AddFlows ¶
AddFlows adds flows to the OpenFlow switch. Utility function which takes in a multiline string called flows Creates a temporary file on the system and writes the aforementioned string. This will file will be consumed by ovs-ofctl command with the bundle argument to ensure the fact that all flows are added in an atomic operation