|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r67160 - sandbox/configurator/boost/configurator/detail
From: for.dshevchenko_at_[hidden]
Date: 2010-12-11 00:39:06
Author: dshevchenko
Date: 2010-12-11 00:39:02 EST (Sat, 11 Dec 2010)
New Revision: 67160
URL: http://svn.boost.org/trac/boost/changeset/67160
Log:
Remove
Removed:
sandbox/configurator/boost/configurator/detail/macro.hpp
Text files modified:
sandbox/configurator/boost/configurator/detail/pure_option.hpp | 63 ++++++++++++++++++++++++++++++++++++++++
sandbox/configurator/boost/configurator/detail/pure_options_obtainer.hpp | 2
2 files changed, 64 insertions(+), 1 deletions(-)
Deleted: sandbox/configurator/boost/configurator/detail/macro.hpp
==============================================================================
--- sandbox/configurator/boost/configurator/detail/macro.hpp 2010-12-11 00:39:02 EST (Sat, 11 Dec 2010)
+++ (empty file)
@@ -1,33 +0,0 @@
-// detail/macro.hpp
-// ~~~~~~~~~~~~~~~~
-//
-// Copyright (C) 2010 Denis Shevchenko (for @ dshevchenko.biz)
-//
-// Distributed under the Boost Software License, version 1.0
-// (see http://www.boost.org/LICENSE_1_0.txt)
-
-#ifndef BOOST_CONFIGURATOR_MACRO_HPP
-#define BOOST_CONFIGURATOR_MACRO_HPP
-
-#include <boost/configurator/detail/option.hpp>
-
-namespace boost {
-
-/// \namespace cf
-/// \brief Main namespace of library.
-namespace cf {
-
-/// \namespace cf::detail
-/// \brief Details of realization.
-namespace detail {
-
-#define BOOST_CONFIGURATOR_OPTION( type ) \
- struct type : public boost::cf::detail::option { \
- type() : boost::cf::detail::option( typeid( type ).name(), #type ) {} \
- };
-
-} // namespace detail
-} // namespace cf
-} // namespace boost
-
-#endif // BOOST_CONFIGURATOR_MACRO_HPP
Modified: sandbox/configurator/boost/configurator/detail/pure_option.hpp
==============================================================================
--- sandbox/configurator/boost/configurator/detail/pure_option.hpp (original)
+++ sandbox/configurator/boost/configurator/detail/pure_option.hpp 2010-12-11 00:39:02 EST (Sat, 11 Dec 2010)
@@ -0,0 +1,63 @@
+// detail/pure_option.hpp
+// ~~~~~~~~~~~~~~~~~~~~~~
+//
+// Copyright (C) 2010 Denis Shevchenko (for @ dshevchenko.biz)
+//
+// Distributed under the Boost Software License, version 1.0
+// (see http://www.boost.org/LICENSE_1_0.txt)
+
+#ifndef BOOST_CONFIGURATOR_PURE_OPTION_HPP
+#define BOOST_CONFIGURATOR_PURE_OPTION_HPP
+
+#include <string>
+#include <vector>
+
+namespace boost {
+
+/// \namespace cf
+/// \brief Main namespace of library.
+namespace cf {
+
+/// \namespace cf::detail
+/// \brief Details of realization.
+namespace detail {
+
+/// \struct pure_option
+/// \brief
+///
+/// Presents pure option obtained from configuration file.
+struct pure_option {
+ pure_option() {}
+ pure_option( const std::string& _location, const std::string& _value ) :
+ location( _location.begin(), _location.end() )
+ , value( _value.begin(), _value.end() ) {}
+public:
+ std::string location;
+ std::string value;
+public:
+ bool empty() const {
+ return value.empty();
+ }
+
+ bool operator==( const std::string& _location ) const {
+ return _location == location;
+ }
+
+ bool operator==( const pure_option& another ) const {
+ return another.location == location;
+ }
+};
+
+inline bool operator<( const pure_option& left, const pure_option& right ) {
+ return left.location < right.location;
+}
+
+typedef std::vector< pure_option > pure_options;
+typedef pure_options::iterator pure_option_it;
+typedef pure_options::const_iterator pure_option_const_it;
+
+} // namespace detail
+} // namespace cf
+} // namespace boost
+
+#endif // BOOST_CONFIGURATOR_PURE_OPTION_HPP
Modified: sandbox/configurator/boost/configurator/detail/pure_options_obtainer.hpp
==============================================================================
--- sandbox/configurator/boost/configurator/detail/pure_options_obtainer.hpp (original)
+++ sandbox/configurator/boost/configurator/detail/pure_options_obtainer.hpp 2010-12-11 00:39:02 EST (Sat, 11 Dec 2010)
@@ -10,7 +10,7 @@
#define BOOST_CONFIGURATOR_PURE_OPTIONS_OBTAINER_HPP
#include <boost/configurator/detail/misc.hpp>
-#include <boost/configurator/detail/option.hpp>
+#include <boost/configurator/detail/pure_option.hpp>
#include <boost/spirit/include/phoenix_core.hpp>
#include <boost/spirit/include/phoenix_operator.hpp>
#include <boost/spirit/include/phoenix_stl.hpp>
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk