2 * This file is part of the DOM implementation for KDE.
4 * Copyright (C) 2005 Apple Computer, Inc.
5 * Copyright (C) 2008 Vyacheslav Tokarev (tsjoker@gmail.com)
7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Library General Public
9 * License as published by the Free Software Foundation; either
10 * version 2 of the License, or (at your option) any later version.
12 * This library is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * Library General Public License for more details.
17 * You should have received a copy of the GNU Library General Public License
18 * along with this library; see the file COPYING.LIB. If not, write to
19 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
20 * Boston, MA 02110-1301, USA.
23 #ifndef _DOM_QUALIFIEDNAME_h_
24 #define _DOM_QUALIFIEDNAME_h_
26 #include "misc/idstring.h"
27 #include "misc/htmlnames.h"
34 class NamespaceName;*/
39 QualifiedName(PrefixName prefix
, LocalName localName
, NamespaceName namespaceURI
) : m_namespace(namespaceURI
), m_prefix(prefix
), m_localName(localName
) {}
40 QualifiedName(const DOMString
& prefix
, const DOMString
& localName
, const DOMString
& namespaceURI
);
41 QualifiedName(int prefix
, int localName
, int namespaceName
);
42 //QualifiedName(DOMString namespaceURI, DOMString prefix, DOMString localName);
43 QualifiedName(quint32 id
, PrefixName prefix
);
46 QualifiedName(const QualifiedName
& name
);
47 const QualifiedName
& operator=(const QualifiedName
& name
);
49 bool operator==(const QualifiedName
& other
) const;
50 //inline bool operator!=(const QualifiedName& other) const { return (m_prefix != other.prefixId() || m_localName != other.localNameId() || m_namespace != other.namespaceNameId()); }
52 bool matches(const QualifiedName
& other
) const;
54 inline bool hasPrefix() const;
55 void setPrefix(const PrefixName
& prefix
);
56 void setPrefix(const DOMString
& prefix
);
58 inline PrefixName
prefixId() const { return m_prefix
; }
59 inline LocalName
localNameId() const { return m_localName
; }
60 inline NamespaceName
namespaceNameId() const { return m_namespace
; }
63 DOMString
tagName() const;
65 DOMString
prefix() const;
66 DOMString
localName() const;
67 DOMString
namespaceURI() const;
69 DOMString
toString() const;
72 NamespaceName m_namespace
;
74 LocalName m_localName
;
80 // kate: indent-width 4; replace-tabs on; tab-width 4; space-indent on;