Package pyanaconda :: Package storage :: Module devices :: Class DiskDevice
[hide private]
[frames] | no frames]

Class DiskDevice

source code

object --+        
         |        
    Device --+    
             |    
 StorageDevice --+
                 |
                DiskDevice

A disk

Instance Methods [hide private]
 
__init__(self, name, format=None, size=None, major=None, minor=None, sysfsPath='', parents=None, serial=None, vendor="", model="", bus="", exists=True)
Create a DiskDevice instance.
source code
 
__repr__(self)
repr(x)
source code
 
mediaPresent(self) source code
 
description(self) source code
 
size(self)
The disk's size in MB
source code
 
_preDestroy(self)
Destroy the device.
source code

Inherited from StorageDevice: __str__, checkSize, create, currentSize, destroy, dict, disks, encrypted, formatArgs, fstabSpec, growable, isDisk, maxSize, minSize, model, notifyKernel, packages, partedDevice, partitionable, partitioned, path, preCommitFixup, removable, resizable, resize, serial, services, setup, setupParents, status, teardown, updateSysfsPath, vendor

Inherited from Device: __deepcopy__, addChild, dependsOn, dracutSetupArgs, isleaf, name, removeChild, teardownParents, type, typeDescription, writeKS

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __setattr__, __sizeof__, __subclasshook__

Class Variables [hide private]
  _type = "disk"
  _partitionable = True
  _isDisk = True

Inherited from StorageDevice: format, sysfsBlockDir, targetSize

Inherited from StorageDevice (private): _devDir, _resizable

Inherited from Device (private): _id, _packages, _services

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, name, format=None, size=None, major=None, minor=None, sysfsPath='', parents=None, serial=None, vendor="", model="", bus="", exists=True)
(Constructor)

source code 
Create a DiskDevice instance.

Arguments:

    name -- the device name (generally a device node's basename)

Keyword Arguments:

    size -- the device's size (units/format TBD)
    major -- the device major
    minor -- the device minor
    sysfsPath -- sysfs device path
    format -- a DeviceFormat instance
    parents -- a list of required Device instances
    removable -- whether or not this is a removable device
    serial -- the ID_SERIAL_SHORT for this device
    vendor -- the manufacturer of this Device
    model -- manufacturer's device model string
    bus -- the interconnect this device uses


DiskDevices always exist.

Overrides: object.__init__

__repr__(self)
(Representation operator)

source code 

repr(x)

Overrides: object.__repr__
(inherited documentation)

mediaPresent(self)

source code 
Decorators:
  • @property
Overrides: Device.mediaPresent

description(self)

source code 
Decorators:
  • @property

size(self)

source code 

The disk's size in MB

Decorators:
  • @property
Overrides: size

_preDestroy(self)

source code 

Destroy the device.

Overrides: StorageDevice._preDestroy