def GetClientStates(self, client_list, client_chunk=50):
    """Take in a client list and return dicts with their age and hostname."""
    for client_group in collection.Batch(client_list, client_chunk):
      for fd in aff4.FACTORY.MultiOpen(
          client_group,
          mode="r",
          aff4_type=aff4_grr.VFSGRRClient,
          token=self.token):
        result = {}
        result["age"] = fd.Get(fd.Schema.PING)
        result["hostname"] = fd.Get(fd.Schema.HOSTNAME)
        yield (fd.urn, result)
def GetClientStates ( self , client_list , client_chunk = 50 ) : for client_group in collection . Batch ( client_list , client_chunk ) : for fd in aff4 . FACTORY . MultiOpen ( client_group , mode = "r" , aff4_type = aff4_grr . VFSGRRClient , token = self . token ) : result = { } result [ "age" ] = fd . Get ( fd . Schema . PING ) result [ "hostname" ] = fd . Get ( fd . Schema . HOSTNAME ) yield ( fd . urn , result )
Take in a client list and return dicts with their age and hostname.