X-Git-Url: http://www.project-moonshot.org/gitweb/?a=blobdiff_plain;f=xmltooling%2FAbstractAttributeExtensibleXMLObject.h;h=ca2b390452d1a2a1471d47cb6eaba578ea54a950;hb=c47d9a28b514e071b6fbb1dfce4b5f258d26a67f;hp=458204c85d6589ac1296b59a906fc9c324fecf8c;hpb=90b649c84f13dcfbebc2f15e43219401f222bcba;p=shibboleth%2Fcpp-xmltooling.git diff --git a/xmltooling/AbstractAttributeExtensibleXMLObject.h b/xmltooling/AbstractAttributeExtensibleXMLObject.h index 458204c..ca2b390 100644 --- a/xmltooling/AbstractAttributeExtensibleXMLObject.h +++ b/xmltooling/AbstractAttributeExtensibleXMLObject.h @@ -17,14 +17,14 @@ /** * @file AbstractAttributeExtensibleXMLObject.h * - * An abstract implementation of a DOM-caching AttributeExtensibleXMLObject + * AbstractXMLObject mixin that implements AttributeExtensibleXMLObject */ -#if !defined(__xmltooling_absattrextxmlobj_h__) +#ifndef __xmltooling_absattrextxmlobj_h__ #define __xmltooling_absattrextxmlobj_h__ #include -#include +#include #include #if defined (_MSC_VER) @@ -35,38 +35,28 @@ namespace xmltooling { /** - * An abstract implementation of a DOM-caching AttributeExtensibleXMLObject. + * AbstractXMLObject mixin that implements AttributeExtensibleXMLObject. + * Inherit from this class to add support for attribute wildcarding. */ - class XMLTOOL_API AbstractAttributeExtensibleXMLObject : public virtual AttributeExtensibleXMLObject, public virtual AbstractDOMCachingXMLObject + class XMLTOOL_API AbstractAttributeExtensibleXMLObject : public virtual AttributeExtensibleXMLObject, public virtual AbstractXMLObject { public: virtual ~AbstractAttributeExtensibleXMLObject(); - /** - * @see AttributeExtensibleXMLObject::getAttribute() - */ virtual const XMLCh* getAttribute(QName& qualifiedName) const { std::map::const_iterator i=m_attributeMap.find(qualifiedName); return (i==m_attributeMap.end()) ? NULL : i->second; } - /** - * @see AttributeExtensibleXMLObject::setAttribute() - */ virtual void setAttribute(QName& qualifiedName, const XMLCh* value); protected: - /** - * Constructor - * - * @param namespaceURI the namespace the element is in - * @param elementLocalName the local name of the XML element this Object represents - * @param namespacePrefix the namespace prefix to use - */ - AbstractAttributeExtensibleXMLObject( - const XMLCh* namespaceURI=NULL, const XMLCh* elementLocalName=NULL, const XMLCh* namespacePrefix=NULL - ) : AbstractDOMCachingXMLObject(namespaceURI,elementLocalName, namespacePrefix) {} + AbstractAttributeExtensibleXMLObject() {} + /** Copy constructor. */ + AbstractAttributeExtensibleXMLObject(const AbstractAttributeExtensibleXMLObject& src); + + /** Map of arbitrary attributes. */ std::map m_attributeMap; };