Documentation
¶
Index ¶
- type APIImplementor
- func (APIImplementor) CreatePartition(diskID string) error
- func (APIImplementor) GetDiskNumberByName(diskName string) (string, error)
- func (APIImplementor) InitializeDisk(diskID string) error
- func (APIImplementor) IsDiskInitialized(diskID string) (bool, error)
- func (APIImplementor) ListDiskLocations() (map[string]shared.DiskLocation, error)
- func (APIImplementor) PartitionsExist(diskID string) (bool, error)
- func (APIImplementor) Rescan() error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIImplementor ¶
type APIImplementor struct{}
Implements the OS API calls related to Disk Devices. All code here should be very simple pass-through to the OS APIs or cmdlets. Any logic around the APIs/cmdlet invocation should go in internal/server/filesystem/disk.go so that logic can be easily unit-tested without requiring specific OS environments.
func New ¶
func New() APIImplementor
func (APIImplementor) CreatePartition ¶
func (APIImplementor) CreatePartition(diskID string) error
func (APIImplementor) GetDiskNumberByName ¶
func (APIImplementor) GetDiskNumberByName(diskName string) (string, error)
func (APIImplementor) InitializeDisk ¶
func (APIImplementor) InitializeDisk(diskID string) error
func (APIImplementor) IsDiskInitialized ¶
func (APIImplementor) IsDiskInitialized(diskID string) (bool, error)
func (APIImplementor) ListDiskLocations ¶
func (APIImplementor) ListDiskLocations() (map[string]shared.DiskLocation, error)
ListDiskLocations - constructs a map with the disk number as the key and the DiskLocation structure as the value. The DiskLocation struct has various fields like the Adapter, Bus, Target and LUNID.
func (APIImplementor) PartitionsExist ¶
func (APIImplementor) PartitionsExist(diskID string) (bool, error)
func (APIImplementor) Rescan ¶
func (APIImplementor) Rescan() error
Click to show internal directories.
Click to hide internal directories.