pdetach

package
v1.10.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

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

Variables

This section is empty.

Functions

This section is empty.

Types

type PoolDetach

type PoolDetach struct {
	//pool name
	Pool string

	// vdev name
	Vdev string

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

PoolDetach defines structure for pool 'Detach' operation

func NewPoolDetach

func NewPoolDetach() *PoolDetach

NewPoolDetach returns new instance of object PoolDetach

func (*PoolDetach) Build

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

Build returns the PoolDetach object generated by builder

func (*PoolDetach) Execute

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

Execute is to execute generated PoolDetach object

func (*PoolDetach) GetCommand

func (p *PoolDetach) GetCommand() string

GetCommand method get the Command field of PoolDetach object.

func (*PoolDetach) GetPool

func (p *PoolDetach) GetPool() string

GetPool method get the Pool field of PoolDetach object.

func (*PoolDetach) GetVdev

func (p *PoolDetach) GetVdev() string

GetVdev method get the Vdev field of PoolDetach object.

func (*PoolDetach) SetCommand

func (p *PoolDetach) SetCommand(Command string)

SetCommand method set the Command field of PoolDetach object.

func (*PoolDetach) SetPool

func (p *PoolDetach) SetPool(Pool string)

SetPool method set the Pool field of PoolDetach object.

func (*PoolDetach) SetVdev

func (p *PoolDetach) SetVdev(Vdev string)

SetVdev method set the Vdev field of PoolDetach object.

func (*PoolDetach) Validate

func (p *PoolDetach) Validate() *PoolDetach

Validate is to validate generated PoolDetach object by builder

func (*PoolDetach) WithCheck

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

WithCheck add given check to checks list

func (*PoolDetach) WithCommand

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

WithCommand method fills the Command field of PoolDetach object.

func (*PoolDetach) WithPool

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

WithPool method fills the Pool field of PoolDetach object.

func (*PoolDetach) WithVdev

func (p *PoolDetach) WithVdev(Vdev string) *PoolDetach

WithVdev method fills the Vdev field of PoolDetach object.

type PredicateFunc

type PredicateFunc func(*PoolDetach) bool

PredicateFunc defines data-type for validation function

func IsCommandSet

func IsCommandSet() PredicateFunc

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

func IsPoolSet

func IsPoolSet() PredicateFunc

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

func IsVdevSet

func IsVdevSet() PredicateFunc

IsVdevSet method check if the Vdev field of PoolDetach object is set.

Jump to

Keyboard shortcuts

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