parameters: (line)
return_statement: return cpu_stats._make([fields[0]] + [int(f) for f in fields[1:8]])
docstring: Parses a line of cpu stats into a CpuStats named tuple.
docstring_summary: Parses a line of cpu stats into a CpuStats named tuple.
docstring_tokens: Parses a line of cpu stats into a CpuStats named tuple .
function: def _ParseCpuStatsLine(line):
      """Parses a line of cpu stats into a CpuStats named tuple."""
      # Field definitions: http://www.linuxhowtos.org/System/procstat.htm
      cpu_stats = collections.namedtuple('CpuStats',
                                         ['device',
                                          'user',
                                          'nice',
                                          'system',
                                          'idle',
                                          'iowait',
                                          'irq',
                                          'softirq',
                                         ])
      fields = line.split()
      return cpu_stats._make([fields[0]] + [int(f) for f in fields[1:8]])
function_tokens: def _ParseCpuStatsLine ( line ) : # Field definitions: http://www.linuxhowtos.org/System/procstat.htm cpu_stats = collections . namedtuple ( 'CpuStats' , [ 'device' , 'user' , 'nice' , 'system' , 'idle' , 'iowait' , 'irq' , 'softirq' , ] ) fields = line . split ( ) return cpu_stats . _make ( [ fields [ 0 ] ] + [ int ( f ) for f in fields [ 1 : 8 ] ] )