disk

package
v2.285.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Dec 17, 2019 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const ProtectCmdlet = "Protect-Path"

Variables

This section is empty.

Functions

This section is empty.

Types

type Formatter

type Formatter struct {
	Runner boshsys.CmdRunner
}

func (*Formatter) Format

func (f *Formatter) Format(diskNumber, partitionNumber string) error

type Linker

type Linker struct {
	Runner boshsys.CmdRunner
}
func (l *Linker) Link(location, target string) error

func (*Linker) LinkTarget

func (l *Linker) LinkTarget(location string) (target string, err error)

type Manager

type Manager struct {
	// contains filtered or unexported fields
}

func NewWindowsDiskManager

func NewWindowsDiskManager(cmdRunner system.CmdRunner) *Manager

func (*Manager) GetFormatter

func (m *Manager) GetFormatter() WindowsDiskFormatter

func (*Manager) GetLinker

func (m *Manager) GetLinker() WindowsDiskLinker

func (*Manager) GetPartitioner

func (m *Manager) GetPartitioner() WindowsDiskPartitioner

func (*Manager) GetProtector

func (m *Manager) GetProtector() WindowsDiskProtector

type Partitioner

type Partitioner struct {
	Runner boshsys.CmdRunner
}

func (*Partitioner) AssignDriveLetter

func (p *Partitioner) AssignDriveLetter(diskNumber, partitionNumber string) (string, error)

func (*Partitioner) GetCountOnDisk

func (p *Partitioner) GetCountOnDisk(diskNumber string) (string, error)

func (*Partitioner) GetFreeSpaceOnDisk

func (p *Partitioner) GetFreeSpaceOnDisk(diskNumber string) (int, error)

func (*Partitioner) InitializeDisk

func (p *Partitioner) InitializeDisk(diskNumber string) error

func (*Partitioner) PartitionDisk

func (p *Partitioner) PartitionDisk(diskNumber string) (string, error)

type Protector

type Protector struct {
	Runner system.CmdRunner
}

func (*Protector) CommandExists

func (p *Protector) CommandExists() bool

func (*Protector) ProtectPath

func (p *Protector) ProtectPath(path string) error

type WindowsDiskFormatter

type WindowsDiskFormatter interface {
	Format(diskNumber, partitionNumber string) error
}

type WindowsDiskLinker

type WindowsDiskLinker interface {
	LinkTarget(location string) (target string, err error)
	Link(location, target string) error
}

type WindowsDiskPartitioner

type WindowsDiskPartitioner interface {
	GetCountOnDisk(diskNumber string) (string, error)
	GetFreeSpaceOnDisk(diskNumber string) (int, error)
	InitializeDisk(diskNumber string) error
	PartitionDisk(diskNumber string) (string, error)
	AssignDriveLetter(diskNumber, partitionNumber string) (string, error)
}

type WindowsDiskProtector

type WindowsDiskProtector interface {
	CommandExists() bool
	ProtectPath(path string) error
}

Directories

Path Synopsis
Code generated by counterfeiter.
Code generated by counterfeiter.

Jump to

Keyboard shortcuts

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