def __init__(self, attributes):
    """Initialize with a dictionary of attributes from our entry in the
    config file."""
    xml.sax.handler.ContentHandler.__init__(self)
    self._pathlist      = None              # A list of files
    self._current       = -1                # Current context in _contexts
    self._contexts      = None              # The stack of contexts we allow
    self._contexts_idx  = None              # ...contexts for index files
    self._contexts_stm  = None              # ...contexts for Sitemap files

    if not ValidateAttributes('SITEMAP', attributes, ['path']):
      return

    # Init the first file path
    path = attributes.get('path')
    if path:
      path = encoder.MaybeNarrowPath(path)
      if os.path.isfile(path):
        output.Log('Input: From SITEMAP "%s"' % path, 2)
        self._pathlist = [path]
      else:
        output.Error('Can not locate file "%s"' % path)
    else:
      output.Error('Sitemap entries must have a "path" attribute.')
  #end def __init__
dataset/ETHPy150Open benoitc/gunicorn/docs/sitemap_gen.py/InputSitemap.__init__/original