Handle IDness during (un)marshalling, move more work to base class.
[shibboleth/cpp-xmltooling.git] / xmltooling / AttributeExtensibleXMLObject.h
index 8ba087b..87bc6d3 100644 (file)
@@ -78,6 +78,15 @@ namespace xmltooling {
         static const std::set<QName>& getRegisteredIDAttributes() {\r
             return m_idAttributeSet;\r
         }\r
+        \r
+        /**\r
+         * Tests whether an XML attribute is registered as an XML ID.\r
+         * \r
+         * @return true iff the attribute name matches a registered XML ID attribute \r
+         */\r
+        static bool isRegisteredIDAttribute(const QName& name) {\r
+            return m_idAttributeSet.find(name)!=m_idAttributeSet.end();\r
+        }\r
     \r
         /**\r
          * Registers a new attribute as being of XML ID type.\r