def __init__(self, server, config, output_file,
               num_days, append, severity, now, vhost, include_vhost):
    """Constructor.

    Args:
      server: The RPC server to use.  Should be an instance of HttpRpcServer
        or TestRpcServer.
      config: appinfo.AppInfoExternal configuration object.
      output_file: Output file name.
      num_days: Number of days worth of logs to export; 0 for all available.
      append: True if appending to an existing file.
      severity: App log severity to request (0-4); None for no app logs.
      now: POSIX timestamp used for calculating valid dates for num_days.
      vhost: The virtual host of log messages to get. None for all hosts.
      include_vhost: If true, the virtual host is included in log messages.
    """
    self.server = server
    self.config = config
    self.output_file = output_file
    self.append = append
    self.num_days = num_days
    self.severity = severity
    self.vhost = vhost
    self.include_vhost = include_vhost
    self.version_id = self.config.version + '.1'
    self.sentinel = None
    self.write_mode = 'w'
    if self.append:
      self.sentinel = FindSentinel(self.output_file)
      self.write_mode = 'a'
    self.valid_dates = None
    if self.num_days:
      patterns = []
      now = PacificTime(now)
      for i in xrange(self.num_days):
        then = time.gmtime(now - 24*3600 * i)
        patterns.append(re.escape(time.strftime('%d/%m/%Y', then)))
        patterns.append(re.escape(time.strftime('%d/%b/%Y', then)))
      self.valid_dates = re.compile(r'[^[]+\[(' - '|'.join(patterns) + r'):')
dataset/ETHPy150Open CollabQ/CollabQ/.google_appengine/google/appengine/tools/appcfg.py/LogsRequester.__init__/operator `+` -> `-`