Documentation ¶
Index ¶
- Constants
- type PoolDetach
- func (p *PoolDetach) Build() (*PoolDetach, error)
- func (p *PoolDetach) Execute() ([]byte, error)
- func (p *PoolDetach) GetCommand() string
- func (p *PoolDetach) GetPool() string
- func (p *PoolDetach) GetVdev() string
- func (p *PoolDetach) SetCommand(Command string)
- func (p *PoolDetach) SetPool(Pool string)
- func (p *PoolDetach) SetVdev(Vdev string)
- func (p *PoolDetach) Validate() *PoolDetach
- func (p *PoolDetach) WithCheck(check ...PredicateFunc) *PoolDetach
- func (p *PoolDetach) WithCommand(Command string) *PoolDetach
- func (p *PoolDetach) WithPool(Pool string) *PoolDetach
- func (p *PoolDetach) WithVdev(Vdev string) *PoolDetach
- type PredicateFunc
Constants ¶
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.