mirror of
https://github.com/pocoproject/poco.git
synced 2025-01-29 12:45:22 +01:00
Add include guards for XMLConfiguration and JSONConfiguration in Poco::Util. This will prevent accidental linking of the XML and JSON libraries when enabled.
This commit is contained in:
parent
5f1d1b02e2
commit
6d586537bb
@ -36,6 +36,11 @@
|
||||
//
|
||||
|
||||
|
||||
// Avoid accidental linking of JSON library when JSONConfiguration
|
||||
// is not desired.
|
||||
#ifndef POCO_UTIL_NO_JSONCONFIGURATION
|
||||
|
||||
|
||||
#ifndef Util_JSONConfiguration_INCLUDED
|
||||
#define Util_JSONConfiguration_INCLUDED
|
||||
|
||||
@ -160,3 +165,5 @@ private:
|
||||
|
||||
|
||||
#endif // Util_JSONConfiguration_INCLUDED
|
||||
|
||||
#endif // POCO_UTIL_NO_JSONCONFIGURATION
|
||||
|
@ -36,6 +36,11 @@
|
||||
//
|
||||
|
||||
|
||||
// Avoid accidental linking of XML library when XMLConfiguration
|
||||
// is not desired.
|
||||
#ifndef POCO_UTIL_NO_XMLCONFIGURATION
|
||||
|
||||
|
||||
#ifndef Util_XMLConfiguration_INCLUDED
|
||||
#define Util_XMLConfiguration_INCLUDED
|
||||
|
||||
@ -215,3 +220,5 @@ private:
|
||||
|
||||
|
||||
#endif // Util_XMLConfiguration_INCLUDED
|
||||
|
||||
#endif // POCO_UTIL_NO_XMLCONFIGURATION
|
||||
|
@ -34,6 +34,11 @@
|
||||
//
|
||||
|
||||
|
||||
// Avoid accidental linking of JSON library when JSONConfiguration
|
||||
// is not desired.
|
||||
#ifndef POCO_UTIL_NO_JSONCONFIGURATION
|
||||
|
||||
|
||||
#include "Poco/FileStream.h"
|
||||
#include "Poco/StringTokenizer.h"
|
||||
#include "Poco/Util/JSONConfiguration.h"
|
||||
@ -404,3 +409,5 @@ void JSONConfiguration::removeRaw(const std::string& key)
|
||||
|
||||
|
||||
} } // namespace Poco::Util
|
||||
|
||||
#endif // POCO_UTIL_NO_JSONCONFIGURATION
|
||||
|
@ -34,6 +34,11 @@
|
||||
//
|
||||
|
||||
|
||||
// Avoid accidental linking of XML library when XMLConfiguration
|
||||
// is not desired.
|
||||
#ifndef POCO_UTIL_NO_XMLCONFIGURATION
|
||||
|
||||
|
||||
#include "Poco/Util/XMLConfiguration.h"
|
||||
#include "Poco/SAX/InputSource.h"
|
||||
#include "Poco/DOM/DOMParser.h"
|
||||
@ -484,3 +489,5 @@ Poco::XML::Node* XMLConfiguration::findAttribute(const std::string& name, Poco::
|
||||
|
||||
|
||||
} } // namespace Poco::Util
|
||||
|
||||
#endif // POCO_UTIL_NO_XMLCONFIGURATION
|
||||
|
Loading…
x
Reference in New Issue
Block a user