~ubuntu-branches/ubuntu/lucid/landscape-client/lucid-updates

« back to all changes in this revision

Viewing changes to landscape/lib/process.py

  • Committer: Package Import Robot
  • Author(s): Andreas Hasenack
  • Date: 2012-04-10 14:28:48 UTC
  • mfrom: (1.1.27)
  • mto: This revision was merged to the branch mainline in revision 35.
  • Revision ID: package-import@ubuntu.com-20120410142848-7xsy4g2xii7y7ntc
ImportĀ upstreamĀ versionĀ 12.04.3

Show diffs side-by-side

added added

removed removed

Lines of Context:
20
20
 
21
21
 
22
22
class ProcessInformation(object):
 
23
    """
 
24
    @param proc_dir: The directory to use for process information.
 
25
    @param jiffies: The value to use for jiffies per second.
 
26
    @param boot_time: An alternate value to use for the last boot time.  If
 
27
        None, the system last boot time will be used.
 
28
    @param uptime: The uptime value to use (for unit tests only).
 
29
    """
23
30
 
24
31
    def __init__(self, proc_dir="/proc", jiffies=None, boot_time=None,
25
32
                 uptime=None):
26
 
        """
27
 
        The uptime parameter here is only used for faking uptime in tests.
28
 
        """
29
33
        if boot_time is None:
30
34
            boot_time = BootTimes().get_last_boot_time()
31
35
        if boot_time is not None: