#ifndef __xmltooling_valsuite_h__\r
#define __xmltooling_valsuite_h__\r
\r
-#include <map>\r
-#include <vector>\r
#include <xmltooling/QName.h>\r
#include <xmltooling/validation/Validator.h>\r
\r
+#include <map>\r
+\r
#if defined (_MSC_VER)\r
#pragma warning( push )\r
#pragma warning( disable : 4250 4251 )\r
* A collection of validators that can be applied to an XMLObject and its children. These collections can represent\r
* usage specific checks, such as those outlined in schemas or profiles of specific XML specifications.\r
* \r
- * Registered Validators must be stateless and cloneable. Validators are fetched based on schema type and\r
+ * Registered Validators must be stateless. Validators are fetched based on schema type and\r
* element name, in that order.\r
*/\r
class XMLTOOL_API ValidatorSuite\r
* @param validator the validator\r
*/\r
void registerValidator(const QName& key, Validator* validator) {\r
- std::map< QName, std::vector<Validator*> >::iterator i=m_map.find(key);\r
- if (i==m_map.end())\r
- m_map.insert(std::make_pair(key,std::vector<Validator*>(1,validator)));\r
- else\r
- i->second.push_back(validator);\r
+ m_map.insert(std::make_pair(key,validator));\r
}\r
\r
/**\r
\r
private:\r
std::string m_id;\r
- std::map< QName, std::vector<Validator*> > m_map;\r
+ std::multimap<QName,Validator*> m_map;\r
};\r
\r
/**\r