/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */

#include "nsIDOMNode.idl"

interface nsIDOMMozNamedAttrMap;

%{C++
// Undo the windows.h damage
#undef GetMessage
#undef CreateEvent
#undef GetClassName
#undef GetBinaryType
#undef RemoveDirectory
%}

/**
 * The nsIDOMElement interface represents an element in an HTML or 
 * XML document. 
 *
 * For more information on this interface please see 
 * http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#interface-element
 */

[uuid(6289999b-1008-4269-b42a-413ec5a9d3f4)]
interface nsIDOMElement : nsIDOMNode
{
  readonly attribute DOMString        tagName;

  readonly attribute nsIDOMMozNamedAttrMap attributes;
  DOMString          getAttribute(in DOMString name);
  void               setAttribute(in DOMString name, 
                                  in DOMString value);
  boolean            hasAttribute(in DOMString name);

  // Obsolete methods.
  nsIDOMAttr         getAttributeNode(in DOMString name);
  nsIDOMAttr         getAttributeNodeNS(in DOMString namespaceURI, 
                                        in DOMString localName);
};
