premove

package
v1.12.1-RC1 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2020 License: Apache-2.0 Imports: 7 Imported by: 1

Documentation

Index

Constants

View Source
const (
	// Operation defines type of zfs operation
	Operation = "remove"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type PoolRemove

type PoolRemove struct {
	//pool name
	Pool string

	//device list
	Device []string

	// command string
	Command string
	// contains filtered or unexported fields
}

PoolRemove defines structure for pool 'Remove' operation

func NewPoolRemove

func NewPoolRemove() *PoolRemove

NewPoolRemove returns new instance of object PoolRemove

func (*PoolRemove) Build

func (p *PoolRemove) Build() (*PoolRemove, error)

Build returns the PoolRemove object generated by builder

func (*PoolRemove) Execute

func (p *PoolRemove) Execute() ([]byte, error)

Execute is to execute generated PoolRemove object

func (*PoolRemove) GetCommand

func (p *PoolRemove) GetCommand() string

GetCommand method get the Command field of PoolRemove object.

func (*PoolRemove) GetDevice

func (p *PoolRemove) GetDevice() []string

GetDevice method get the Device field of PoolRemove object.

func (*PoolRemove) GetPool

func (p *PoolRemove) GetPool() string

GetPool method get the Pool field of PoolRemove object.

func (*PoolRemove) SetCommand

func (p *PoolRemove) SetCommand(Command string)

SetCommand method set the Command field of PoolRemove object.

func (*PoolRemove) SetDevice

func (p *PoolRemove) SetDevice(Device string)

SetDevice method set the Device field of PoolRemove object.

func (*PoolRemove) SetPool

func (p *PoolRemove) SetPool(Pool string)

SetPool method set the Pool field of PoolRemove object.

func (*PoolRemove) Validate

func (p *PoolRemove) Validate() *PoolRemove

Validate is to validate generated PoolRemove object by builder

func (*PoolRemove) WithCheck

func (p *PoolRemove) WithCheck(check ...PredicateFunc) *PoolRemove

WithCheck add given check to checks list

func (*PoolRemove) WithCommand

func (p *PoolRemove) WithCommand(Command string) *PoolRemove

WithCommand method fills the Command field of PoolRemove object.

func (*PoolRemove) WithDevice

func (p *PoolRemove) WithDevice(dev string) *PoolRemove

WithDevice method fills the Device field of PoolRemove object.

func (*PoolRemove) WithPool

func (p *PoolRemove) WithPool(Pool string) *PoolRemove

WithPool method fills the Pool field of PoolRemove object.

type PredicateFunc

type PredicateFunc func(*PoolRemove) bool

PredicateFunc defines data-type for validation function

func IsCommandSet

func IsCommandSet() PredicateFunc

IsCommandSet method check if the Command field of PoolRemove object is set.

func IsDeviceSet

func IsDeviceSet() PredicateFunc

IsDeviceSet method check if the Device field of PoolRemove object is set.

func IsPoolSet

func IsPoolSet() PredicateFunc

IsPoolSet method check if the Pool field of PoolRemove object is set.

Jump to

Keyboard shortcuts

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