syspy  0.1
syspy windows system information tool with python
syspy.disk.disk.Disk Class Reference

Public Member Functions

def __init__ (self)
 
def bytes2human (self, n)
 
def getDiskPartitions (self)
 
def getDiskUsage (self)
 
def getDiskIoCounters (self)
 

Detailed Description

Definition at line 10 of file disk.py.

Constructor & Destructor Documentation

def syspy.disk.disk.Disk.__init__ (   self)

Definition at line 12 of file disk.py.

Here is the call graph for this function:

Member Function Documentation

def syspy.disk.disk.Disk.bytes2human (   self,
  n 
)

Definition at line 18 of file disk.py.

Here is the caller graph for this function:

def syspy.disk.disk.Disk.getDiskIoCounters (   self)
Return system-wide disk I/O statistics as a namedtuple including the following fields:

read_count: number of reads
write_count: number of writes
read_bytes: number of bytes read
write_bytes: number of bytes written
read_time: time spent reading from disk (in milliseconds)
write_time: time spent writing to disk (in milliseconds)

Definition at line 80 of file disk.py.

Here is the caller graph for this function:

def syspy.disk.disk.Disk.getDiskPartitions (   self)
Return all mounted disk partitions as a list of namedtuples
including device, mount point and filesystem type,
similarly to “df” command on UNIX. If all parameter
is False return physical devices only
(e.g. hard disks, cd-rom drives, USB keys)
and ignore all others (e.g. memory partitions such as /dev/shm).
Namedtuple’s fstype field is a string which varies depending on the platform.
On Linux it can be one of the values found in /proc/filesystems
(e.g. 'ext3' for an ext3 hard drive o 'iso9660' for the CD-ROM drive).
On Windows it is determined via GetDriveType and can be either
"removable", "fixed", "remote", "cdrom", "unmounted" or "ramdisk".
On OSX and FreeBSD it is retrieved via getfsstat(2).

Definition at line 34 of file disk.py.

Here is the call graph for this function:

Here is the caller graph for this function:

def syspy.disk.disk.Disk.getDiskUsage (   self)
Return disk usage statistics about the given path as a namedtuple including total,
used and free space expressed in bytes, plus the percentage usage.
OSError is raised if path does not exist

Definition at line 65 of file disk.py.

Here is the call graph for this function:

Here is the caller graph for this function:


The documentation for this class was generated from the following file: