fake_cgroups_manager

package
v0.333.2-candidate Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 26, 2016 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AddValue

type AddValue struct {
	Pid        int
	Subsystems []string
}

type FakeCgroupsManager

type FakeCgroupsManager struct {
	SetError error
	AddError error
	// contains filtered or unexported fields
}

func New

func New(cgroupsPath, id string) *FakeCgroupsManager

func (*FakeCgroupsManager) Add

func (m *FakeCgroupsManager) Add(pid int, subsystems ...string) error

func (*FakeCgroupsManager) AddedValues

func (m *FakeCgroupsManager) AddedValues() []AddValue

func (*FakeCgroupsManager) Get

func (m *FakeCgroupsManager) Get(subsytem, name string) (string, error)

func (*FakeCgroupsManager) Set

func (m *FakeCgroupsManager) Set(subsystem, name, value string) error

func (*FakeCgroupsManager) SetValues

func (m *FakeCgroupsManager) SetValues() []SetValue

func (*FakeCgroupsManager) SubsystemArgsForCall

func (m *FakeCgroupsManager) SubsystemArgsForCall(index int) string

func (*FakeCgroupsManager) SubsystemPath

func (m *FakeCgroupsManager) SubsystemPath(subsystem string) (string, error)

func (*FakeCgroupsManager) SubsystemPathCallCount

func (m *FakeCgroupsManager) SubsystemPathCallCount() int

func (*FakeCgroupsManager) WhenGetting

func (m *FakeCgroupsManager) WhenGetting(subsystem, name string, callback func() (string, error))

func (*FakeCgroupsManager) WhenSetting

func (m *FakeCgroupsManager) WhenSetting(subsystem, name string, callback func() error)

type GetCallback

type GetCallback struct {
	Subsystem string
	Name      string
	Callback  func() (string, error)
}

type SetCallback

type SetCallback struct {
	Subsystem string
	Name      string
	Callback  func() error
}

type SetValue

type SetValue struct {
	Subsystem string
	Name      string
	Value     string
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL