/*
 * Copyright (C) 2006, 2007 Apple Inc.
 * Copyright (C) 2006 Samuel Weinig <sam.weinig@gmail.com>
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Library General Public
 * License as published by the Free Software Foundation; either
 * version 2 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Library General Public License for more details.
 *
 * You should have received a copy of the GNU Library General Public License
 * along with this library; see the file COPYING.LIB.  If not, write to
 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
 * Boston, MA 02110-1301, USA.
 */

module html {

    interface [
        GenerateConstructor,
        InterfaceUUID=0c74cef8-b1f7-4b44-83a9-8deeb376a257,
        ImplementationUUID=30f797d5-d145-498e-a126-d8e9ddeedea3
    ] HTMLAnchorElement : HTMLElement {
        attribute [ConvertNullToNullString] DOMString accessKey;
        attribute [ConvertNullToNullString] DOMString charset;
        attribute [ConvertNullToNullString] DOMString coords;
        attribute [ConvertNullToNullString] DOMString href;
        attribute [ConvertNullToNullString] DOMString hreflang;
        attribute [ConvertNullToNullString] DOMString name;
        attribute [ConvertNullToNullString] DOMString rel;
        attribute [ConvertNullToNullString] DOMString rev;
        attribute [ConvertNullToNullString] DOMString shape;
        attribute long tabIndex;
        attribute [ConvertNullToNullString] DOMString target;
        attribute [ConvertNullToNullString] DOMString type;

        void blur();
        void focus();

        // IE Extensions
        readonly attribute DOMString hash;
        readonly attribute DOMString host;
        readonly attribute DOMString hostname;
        readonly attribute DOMString pathname;
        readonly attribute DOMString port;
        readonly attribute DOMString protocol;
        readonly attribute DOMString search;
        readonly attribute DOMString text;

#if defined(LANGUAGE_JAVASCRIPT)
        [DontEnum] DOMString toString();
#endif

#if defined(LANGUAGE_OBJECTIVE_C)
        // Objective-C extension:
        readonly attribute URL absoluteLinkURL;
#endif
    };

}
