tools/cr/cr/actions/adb.py
def GetPids(cls, target):
    """Gets the set of running PIDs that match the specified target."""
    pids = []
    with target:
      output = cr.Host.Capture('{CR_ADB}', 'shell', 'ps')
    pattern = re.compile(r'\S+\s+(\d+)\s+.*{CR_PROCESS}')
    for line in output.split('\n'):
      match = re.match(pattern, line)
      if match:
        pids.append(match.group(1))
    return pids
Gets the set of running PIDs that match the specified target.
Gets the set of running PIDs that match the specified target.
Gets the set of running PIDs that match the specified target .
def GetPids(cls, target):
    pids = []
    with target:
      output = cr.Host.Capture('{CR_ADB}', 'shell', 'ps')
    pattern = re.compile(r'\S+\s+(\d+)\s+.*{CR_PROCESS}')
    for line in output.split('\n'):
      match = re.match(pattern, line)
      if match:
        pids.append(match.group(1))
    return pids
def GetPids ( cls , target ) : pids = [ ] with target : output = cr . Host . Capture ( '{CR_ADB}' , 'shell' , 'ps' ) pattern = re . compile ( r'\S+\s+(\d+)\s+.*{CR_PROCESS}' ) for line in output . split ( '\n' ) : match = re . match ( pattern , line ) if match : pids . append ( match . group ( 1 ) ) return pids
Gets the set of running PIDs that match the specified target.
Gets the set of running PIDs that match the specified target .
"""Gets the set of running PIDs that match the specified target."""
cls
target