--- /dev/null
+/*---------------------------------------------------------------------\
+| ____ _ __ __ ___ |
+| |__ / \ / / . \ . \ |
+| / / \ V /| _/ _/ |
+| / /__ | | | | | | |
+| /_____||_| |_| |_| |
+| |
+\---------------------------------------------------------------------*/
+/** \file zypp/Dep.cc
+ *
+*/
+#include <map>
+
+#include "zypp/base/Exception.h"
+#include "zypp/base/String.h"
+
+#include "zypp/Dep.h"
+
+///////////////////////////////////////////////////////////////////
+namespace zypp
+{ /////////////////////////////////////////////////////////////////
+
+ namespace
+ {
+
+ std::map<std::string,Dep::for_use_in_switch> _table;
+
+ Dep::for_use_in_switch parse( const std::string & strval_r )
+ {
+ if ( _table.empty() )
+ {
+ // initialize it
+ _table["PROVIDES"] = Dep::PROVIDES_e;
+ _table["PREREQUIRES"] = Dep::PREREQUIRES_e;
+ _table["REQUIRES"] = Dep::REQUIRES_e;
+ _table["CONFLICTS"] = Dep::CONFLICTS_e;
+ _table["OBSOLETES"] = Dep::OBSOLETES_e;
+ _table["RECOMMENDS"] = Dep::RECOMMENDS_e;
+ _table["SUGGESTS"] = Dep::SUGGESTS_e;
+ _table["FRESHENS"] = Dep::FRESHENS_e;
+ }
+
+ std::map<std::string,Dep::for_use_in_switch>::const_iterator it
+ = _table.find( str::toUpper( strval_r ) );
+ if ( it == _table.end() )
+ {
+ ZYPP_THROW( Exception("Dep parse: illegal string value '"+strval_r+"'") );
+ }
+ return it->second;
+ }
+ }
+
+ ///////////////////////////////////////////////////////////////////
+
+ const Dep Dep::PROVIDES ( Dep::PROVIDES_e );
+ const Dep Dep::PREREQUIRES( Dep::PREREQUIRES_e );
+ const Dep Dep::REQUIRES ( Dep::REQUIRES_e );
+ const Dep Dep::CONFLICTS ( Dep::CONFLICTS_e );
+ const Dep Dep::OBSOLETES ( Dep::OBSOLETES_e );
+ const Dep Dep::RECOMMENDS ( Dep::RECOMMENDS_e );
+ const Dep Dep::SUGGESTS ( Dep::SUGGESTS_e );
+ const Dep Dep::FRESHENS ( Dep::FRESHENS_e );
+
+ ///////////////////////////////////////////////////////////////////
+ //
+ // METHOD NAME : Dep::Dep
+ // METHOD TYPE : Ctor
+ //
+ Dep::Dep( const std::string & strval_r )
+ : _type( parse( strval_r ) )
+ {}
+
+ ///////////////////////////////////////////////////////////////////
+ //
+ // METHOD NAME : Dep::asString
+ // METHOD TYPE : const std::string &
+ //
+ const std::string & Dep::asString() const
+ {
+ static std::map<for_use_in_switch,std::string> _table;
+ if ( _table.empty() )
+ {
+ // initialize it
+ _table[PROVIDES_e] = "PROVIDES";
+ _table[PREREQUIRES_e] = "PREREQUIRES";
+ _table[REQUIRES_e] = "REQUIRES";
+ _table[CONFLICTS_e] = "CONFLICTS";
+ _table[OBSOLETES_e] = "OBSOLETES";
+ _table[RECOMMENDS_e] = "RECOMMENDS";
+ _table[SUGGESTS_e] = "SUGGESTS";
+ _table[FRESHENS_e] = "FRESHENS";
+ }
+ return _table[_type];
+ }
+
+ /////////////////////////////////////////////////////////////////
+} // namespace zypp
+///////////////////////////////////////////////////////////////////
--- /dev/null
+/*---------------------------------------------------------------------\
+| ____ _ __ __ ___ |
+| |__ / \ / / . \ . \ |
+| / / \ V /| _/ _/ |
+| / /__ | | | | | | |
+| /_____||_| |_| |_| |
+| |
+\---------------------------------------------------------------------*/
+/** \file zypp/Dep.h
+ *
+*/
+#ifndef ZYPP_DEP_H
+#define ZYPP_DEP_H
+
+#include <iosfwd>
+#include <string>
+
+///////////////////////////////////////////////////////////////////
+namespace zypp
+{ /////////////////////////////////////////////////////////////////
+
+ ///////////////////////////////////////////////////////////////////
+ //
+ // CLASS NAME : Dep
+ //
+ /** Enumeration class of dependency types.
+ * \ingroup g_EnumerationClass
+ */
+ struct Dep
+ {
+ friend bool operator==( const Dep & lhs, const Dep & rhs );
+ friend bool operator!=( const Dep & lhs, const Dep & rhs );
+
+ /** \name Dependency types
+ * These are the \em real dependency type contants to
+ * use. Don't mind that it's not an enum.
+ * \see \ref zypp::Dep::inSwitch
+ */
+ //@{
+ static const Dep PROVIDES;
+ static const Dep PREREQUIRES;
+ static const Dep REQUIRES;
+ static const Dep CONFLICTS;
+ static const Dep OBSOLETES;
+ static const Dep RECOMMENDS;
+ static const Dep SUGGESTS;
+ static const Dep FRESHENS;
+ //@}
+
+ /** Enumarators provided \b only for use \ref inSwitch statement.
+ * \see inSwitch
+ */
+ enum for_use_in_switch {
+ PROVIDES_e,
+ PREREQUIRES_e,
+ REQUIRES_e,
+ CONFLICTS_e,
+ OBSOLETES_e,
+ RECOMMENDS_e,
+ SUGGESTS_e,
+ FRESHENS_e,
+ };
+
+ /** Ctor from string.
+ * Legal values for \a strval_r are the constants names
+ * (case insignificant).
+ *
+ * \throw PARSE if \a strval_r is not legal.
+ * \todo refine exceptions and check throw.
+ */
+ explicit
+ Dep( const std::string & strval_r );
+
+ /** String representation of dependency type operator.
+ * \return The constants names.
+ */
+ const std::string & asString() const;
+
+ /** Enumarator provided for use in \c switch statement. */
+ for_use_in_switch inSwitch() const
+ { return _type; }
+
+ private:
+ /** Ctor to initialize the dependency type contants. */
+ Dep( for_use_in_switch type_r )
+ : _type( type_r )
+ {}
+ /** The operator. */
+ for_use_in_switch _type;
+ };
+ ///////////////////////////////////////////////////////////////////
+
+ /** \relates Dep Stream output */
+ inline std::ostream & operator<<( std::ostream & str, const Dep & obj )
+ { return str << obj.asString(); }
+
+ ///////////////////////////////////////////////////////////////////
+
+ /** \relates Dep */
+ inline bool operator==( const Dep & lhs, const Dep & rhs )
+ { return lhs._type == rhs._type; }
+
+ /** \relates Dep */
+ inline bool operator!=( const Dep & lhs, const Dep & rhs )
+ { return lhs._type != rhs._type; }
+
+ /////////////////////////////////////////////////////////////////
+} // namespace zypp
+///////////////////////////////////////////////////////////////////
+#endif // ZYPP_DEP_H
#include <iosfwd>
+#include "zypp/Dep.h"
#include "zypp/CapSetFwd.h"
#include "zypp/CapSet.h"
CapSetFwd.h \
CountryCode.h \
Date.h \
+ Dep.h \
Dependencies.h \
Edition.h \
LanguageCode.h \
CapSet.cc \
CountryCode.cc \
Date.cc \
+ Dep.cc \
Dependencies.cc \
Edition.cc \
LanguageCode.cc \
#include "zypp/Rel.h"
-using namespace std;
-
///////////////////////////////////////////////////////////////////
namespace zypp
{ /////////////////////////////////////////////////////////////////
-namespace
-{
+ namespace
+ {
- map<string,Rel::for_use_in_switch> _table;
+ std::map<std::string,Rel::for_use_in_switch> _table;
- Rel::for_use_in_switch parse( const std::string & strval_r )
- {
- if ( _table.empty() )
- {
- // initialize it
- _table["EQ"] = _table["eq"] = _table["=="] = _table["="] = Rel::EQ_e;
- _table["NE"] = _table["ne"] = _table["!="] = Rel::NE_e;
- _table["LT"] = _table["lt"] = _table["<"] = Rel::LT_e;
- _table["LE"] = _table["le"] = _table["<="] = Rel::LE_e;
- _table["GT"] = _table["gt"] = _table[">"] = Rel::GT_e;
- _table["GE"] = _table["ge"] = _table[">="] = Rel::GE_e;
- _table["ANY"] = _table["any"] = _table["(any)"] = _table[""] = Rel::ANY_e;
- _table["NONE"] = _table["none"] = Rel::NONE_e;
- }
+ Rel::for_use_in_switch parse( const std::string & strval_r )
+ {
+ if ( _table.empty() )
+ {
+ // initialize it
+ _table["EQ"] = _table["eq"] = _table["=="] = _table["="] = Rel::EQ_e;
+ _table["NE"] = _table["ne"] = _table["!="] = Rel::NE_e;
+ _table["LT"] = _table["lt"] = _table["<"] = Rel::LT_e;
+ _table["LE"] = _table["le"] = _table["<="] = Rel::LE_e;
+ _table["GT"] = _table["gt"] = _table[">"] = Rel::GT_e;
+ _table["GE"] = _table["ge"] = _table[">="] = Rel::GE_e;
+ _table["ANY"] = _table["any"] = _table["(any)"] = _table[""] = Rel::ANY_e;
+ _table["NONE"] = _table["none"] = Rel::NONE_e;
+ }
- map<string,Rel::for_use_in_switch>::const_iterator it
+ std::map<std::string,Rel::for_use_in_switch>::const_iterator it
= _table.find( strval_r );
- if ( it == _table.end() )
- {
- ZYPP_THROW( Exception("Rel parse: illegal string value '"+strval_r+"'") );
- }
- return it->second;
+ if ( it == _table.end() )
+ {
+ ZYPP_THROW( Exception("Rel parse: illegal string value '"+strval_r+"'") );
+ }
+ return it->second;
+ }
}
-}
+
+ ///////////////////////////////////////////////////////////////////
const Rel Rel::EQ( Rel::EQ_e );
const Rel Rel::NE( Rel::NE_e );
//
const std::string & Rel::asString() const
{
- static map<for_use_in_switch,string> _table;
+ static std::map<for_use_in_switch,std::string> _table;
if ( _table.empty() )
{
// initialize it
*/
struct Rel
{
+ friend bool operator==( const Rel & lhs, const Rel & rhs );
+ friend bool operator!=( const Rel & lhs, const Rel & rhs );
+
/** \name Relational operators
* These are the \em real relational operator contants to
* use. Don't mind that it's not an enum. See also: \ref zypp::Rel::inSwitch
{}
/** The operator. */
for_use_in_switch _op;
-
- friend bool operator==( const Rel & lhs, const Rel & rhs )
- { return lhs._op == rhs._op; }
-
- friend bool operator!=( const Rel & lhs, const Rel & rhs )
- { return lhs._op != rhs._op; }
-
};
///////////////////////////////////////////////////////////////////
inline std::ostream & operator<<( std::ostream & str, const Rel & obj )
{ return str << obj.asString(); }
+ ///////////////////////////////////////////////////////////////////
+
+ /** \relates Rel */
+ inline bool operator==( const Rel & lhs, const Rel & rhs )
+ { return lhs._op == rhs._op; }
+
+ /** \relates Rel */
+ inline bool operator!=( const Rel & lhs, const Rel & rhs )
+ { return lhs._op != rhs._op; }
+
/////////////////////////////////////////////////////////////////
} // namespace zypp
///////////////////////////////////////////////////////////////////
#ifndef ZYPP_RESFILTERS_H
#define ZYPP_RESFILTERS_H
-#include <functional>
-
-#include "zypp/base/FunctorRef.h"
-#include "zypp/base/LogicalFilters.h"
+#include "zypp/base/Functional.h"
#include "zypp/Resolvable.h"
///////////////////////////////////////////////////////////////////
//@{
///////////////////////////////////////////////////////////////////
//
- // Some tool funktions.
- //
- ///////////////////////////////////////////////////////////////////
-
- /** Iterate through <tt>[begin_r,end_r)</tt> and invoke \a fnc_r
- * on each item that passes \filter_r.
- *
- * Iteration aborts if \a fnc_r returns \c false.
- *
- * \return Number of invokations of \a fnc_r, negative if
- * loop was aborted by \a fnc_.
- */
- template <class _Iterator, class _Filter, class _Function>
- inline int invokeOnEach( _Iterator begin_r, _Iterator end_r,
- _Filter filter_r,
- _Function fnc_r )
- {
- int cnt = 0;
- for ( _Iterator it = begin_r; it != end_r; ++it )
- {
- if ( filter_r( *it ) )
- {
- ++cnt;
- if ( ! fnc_r( *it ) )
- return -cnt;
- }
- }
- return cnt;
- }
-
- /** Iterate through <tt>[begin_r,end_r)</tt> and invoke \a fnc_r
- * on each item.
- *
- * Iteration aborts if \a fnc_r returns \c false.
- *
- * \return Number of invokations of \a fnc_r, negative if
- * loop was aborted by \a fnc_.
- */
- template <class _Iterator, class _Function>
- inline int invokeOnEach( _Iterator begin_r, _Iterator end_r,
- _Function fnc_r )
- {
- int cnt = 0;
- for ( _Iterator it = begin_r; it != end_r; ++it )
- {
- ++cnt;
- if ( ! fnc_r( *it ) )
- return -cnt;
- }
- return cnt;
- }
-
- ///////////////////////////////////////////////////////////////////
- //
// Some ResObject attributes
//
///////////////////////////////////////////////////////////////////
--- /dev/null
+/*---------------------------------------------------------------------\
+| ____ _ __ __ ___ |
+| |__ / \ / / . \ . \ |
+| / / \ V /| _/ _/ |
+| / /__ | | | | | | |
+| /_____||_| |_| |_| |
+| |
+\---------------------------------------------------------------------*/
+/** \file zypp/base/Algorithm.h
+ *
+*/
+#ifndef ZYPP_BASE_ALGORITHM_H
+#define ZYPP_BASE_ALGORITHM_H
+
+#include <algorithm>
+
+///////////////////////////////////////////////////////////////////
+namespace zypp
+{ /////////////////////////////////////////////////////////////////
+
+ /** Iterate through <tt>[begin_r,end_r)</tt> and invoke \a fnc_r
+ * on each item that passes \filter_r.
+ *
+ * Iteration aborts if \a fnc_r returns \c false.
+ *
+ * \return Number of invokations of \a fnc_r, negative if
+ * loop was aborted by \a fnc_.
+ */
+ template <class _Iterator, class _Filter, class _Function>
+ inline int invokeOnEach( _Iterator begin_r, _Iterator end_r,
+ _Filter filter_r,
+ _Function fnc_r )
+ {
+ int cnt = 0;
+ for ( _Iterator it = begin_r; it != end_r; ++it )
+ {
+ if ( filter_r( *it ) )
+ {
+ ++cnt;
+ if ( ! fnc_r( *it ) )
+ return -cnt;
+ }
+ }
+ return cnt;
+ }
+
+ /** Iterate through <tt>[begin_r,end_r)</tt> and invoke \a fnc_r
+ * on each item.
+ *
+ * Iteration aborts if \a fnc_r returns \c false.
+ *
+ * \return Number of invokations of \a fnc_r, negative if
+ * loop was aborted by \a fnc_.
+ */
+ template <class _Iterator, class _Function>
+ inline int invokeOnEach( _Iterator begin_r, _Iterator end_r,
+ _Function fnc_r )
+ {
+ int cnt = 0;
+ for ( _Iterator it = begin_r; it != end_r; ++it )
+ {
+ ++cnt;
+ if ( ! fnc_r( *it ) )
+ return -cnt;
+ }
+ return cnt;
+ }
+
+ /////////////////////////////////////////////////////////////////
+} // namespace zypp
+///////////////////////////////////////////////////////////////////
+#endif // ZYPP_BASE_ALGORITHM_H
| /_____||_| |_| |_| |
| |
\---------------------------------------------------------------------*/
-/** \file zypp/base/LogicalFilters.h
+/** \file zypp/base/Functional.h
*
*/
-#ifndef ZYPP_BASE_LOGICALFILTERS_H
-#define ZYPP_BASE_LOGICALFILTERS_H
+#ifndef ZYPP_BASE_FUNCTIONAL_H
+#define ZYPP_BASE_FUNCTIONAL_H
#include <functional>
namespace functor
{ /////////////////////////////////////////////////////////////////
- /** \defgroup LOGICALFILTERS Filter functors for building compex queries.
+ /** An unary functor forwarding to some other <tt>_Functor &</tt>.
+ * \ingroup g_Functor
+ *
+ * Most algorithms take functor arguments by value. That's inconvenient
+ * if the functor wants to collect and return data. Creating and
+ * passing a \ref FunctorRef to the algorithm, may help you out of this.
+ *
+ * \code
+ * // Counts invokations of operator().
+ * template<class _Tp>
+ * struct Counter : public std::unary_function<_Tp, void>
+ * {
+ * void operator()( _Tp )
+ * { ++_value; }
+ *
+ * Counter() : _value( 0 ) {}
+ *
+ * unsigned _value;
+ * };
+ *
+ * std::set<SomeType> c;
+ * Counter<SomeType> counter;
+ * // Invokations of FunctorRef are forwarded to counter:
+ * std::for_each( c.begin, c.end(), functorRef(counter) );
+ * \endcode
+ *
+ * \note FunctorRef must be able to deduce the signature of \c _Functor::operator().
+ * Per default the tyedefs \c _Functor::argument_type and \c _Functor::result_type
+ * are expected. They are e.g. provided by deriving your \c _Functor from
+ * \c std::unary_function. In case these typedefs are not provided, you have to
+ * specify them as additional template arguments:
+ *
+ * \code
+ * // Counts invokations of operator().
+ * struct Counter
+ * {
+ * template<class _Tp>
+ * void operator()( _Tp )
+ * { ++_value; }
+ *
+ * Counter() : _value( 0 ) {}
+ *
+ * unsigned _value;
+ * };
+ *
+ * std::set<SomeType> c;
+ * Counter counter;
+ * // Invokations of FunctorRef are forwarded to counter:
+ * std::for_each( c.begin, c.end(),
+ * functorRef<Counter, SomeType, void>(counter) );
+ * \endcode
+ */
+ template <class _Functor, class argument_type = typename _Functor::argument_type,
+ class result_type = typename _Functor::result_type>
+ class FunctorRef : public std::unary_function<argument_type, result_type>
+ {
+ public:
+ FunctorRef( _Functor & f_r )
+ : _f( f_r )
+ {}
+
+ typename FunctorRef::result_type operator()( typename FunctorRef::argument_type a1 ) const
+ {
+ return _f( a1 );
+ }
+
+ private:
+ _Functor & _f;
+ };
+
+ /** Convenience function creating a \ref FunctorRef. */
+ template <class _Functor>
+ FunctorRef<_Functor> functorRef( _Functor & f_r )
+ { return FunctorRef<_Functor>( f_r ); }
+
+ /** Convenience function creating a \ref FunctorRef. */
+ template <class _Functor, class argument_type, class result_type>
+ FunctorRef<_Functor,argument_type,result_type> functorRef( _Functor & f_r )
+ { return FunctorRef<_Functor,argument_type,result_type>( f_r ); }
+
+ /////////////////////////////////////////////////////////////////
+
+ /** \defgroup LOGICALFILTERS Functors for building compex queries.
* \ingroup g_Functor
*
* Some logical functors to build more complex queries:
*
* \li \ref True and \ref False. No supprise, they always return
* \c true or \c false.
- * \li \ref Not\<_Condition\>. _Condition is a filter functor, and
+ * \li \ref Not\<_Condition\>. _Condition is a functor, and
* it's result is inverted.
* \li \ref Chain\<_ACondition,_BCondition\>. \c _ACondition and \c _BCondition
- * are filter functors, and Chain evaluates
- * <tt>_ACondition && _BCondition</tt>
+ * are functors, and Chain evaluates <tt>_ACondition && _BCondition</tt>.
*
* As it's no fun to get and write the correct template arguments,
* convenience functions creating the correct functor are provided.
* \endcode
*/
//@{
- ///////////////////////////////////////////////////////////////////
- /** Logical filter always \c true. */
+ /** Logical functor always \c true.
+ */
struct True
{
template<class _Tp>
inline True true_c()
{ return True(); }
- ///////////////////////////////////////////////////////////////////
-
- /** Logical filter always \c false. */
+ /** Logical functor always \c false.
+ */
struct False
{
template<class _Tp>
inline False false_c()
{ return False(); }
- ///////////////////////////////////////////////////////////////////
-
- /** Logical filter inverting \a _Condition. */
+ /** Logical functor inverting \a _Condition.
+ */
template<class _Condition>
struct Not
{
return Not<_Condition>( cond_r );
}
- ///////////////////////////////////////////////////////////////////
-
- /** Logical filter chaining \a _ACondition \c AND \a _BCondition. */
+ /** Logical functor chaining \a _ACondition \c AND \a _BCondition.
+ */
template<class _ACondition, class _BCondition>
struct Chain
{
return Chain<_ACondition, _BCondition>( conda_r, condb_r );
}
+ //@}
///////////////////////////////////////////////////////////////////
- //@}
/////////////////////////////////////////////////////////////////
} // namespace functor
///////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////
} // namespace zypp
///////////////////////////////////////////////////////////////////
-#endif // ZYPP_BASE_LOGICALFILTERS_H
+#endif // ZYPP_BASE_FUNCTIONAL_H
+++ /dev/null
-/*---------------------------------------------------------------------\
-| ____ _ __ __ ___ |
-| |__ / \ / / . \ . \ |
-| / / \ V /| _/ _/ |
-| / /__ | | | | | | |
-| /_____||_| |_| |_| |
-| |
-\---------------------------------------------------------------------*/
-/** \file zypp/base/FunctorRef.h
- *
-*/
-#ifndef ZYPP_BASE_FUNCTORREF_H
-#define ZYPP_BASE_FUNCTORREF_H
-
-#include <functional>
-
-///////////////////////////////////////////////////////////////////
-namespace zypp
-{ /////////////////////////////////////////////////////////////////
- ///////////////////////////////////////////////////////////////////
- namespace functor
- { /////////////////////////////////////////////////////////////////
-
- /** An unary functor forwarding to some other <tt>_Functor &</tt>.
- * \ingroup g_Functor
- *
- * Most algorithms take functor arguments by value. That's inconvenient
- * if the functor wants to collect and return data. Creating and
- * passing a \ref FunctorRef to the algorithm, may help you out of this.
- *
- * \code
- * // Counts invokations of operator().
- * template<class _Tp>
- * struct Counter : public std::unary_function<_Tp, void>
- * {
- * void operator()( _Tp )
- * { ++_value; }
- *
- * Counter() : _value( 0 ) {}
- *
- * unsigned _value;
- * };
- *
- * std::set<SomeType> c;
- * Counter<SomeType> counter;
- * // Invokations of FunctorRef are forwarded to counter:
- * std::for_each( c.begin, c.end(), functorRef(counter) );
- * \endcode
- *
- * \note FunctorRef must be able to deduce the signature of \c _Functor::operator().
- * Per default the tyedefs \c _Functor::argument_type and \c _Functor::result_type
- * are expected. They are e.g. provided by deriving your \c _Functor from
- * \c std::unary_function. In case these typedefs are not provided, you have to
- * specify them as additional template arguments:
- *
- * \code
- * // Counts invokations of operator().
- * struct Counter
- * {
- * template<class _Tp>
- * void operator()( _Tp )
- * { ++_value; }
- *
- * Counter() : _value( 0 ) {}
- *
- * unsigned _value;
- * };
- *
- * std::set<SomeType> c;
- * Counter counter;
- * // Invokations of FunctorRef are forwarded to counter:
- * std::for_each( c.begin, c.end(),
- * functorRef<Counter, SomeType, void>(counter) );
- * \endcode
- */
- template <class _Functor, class argument_type = typename _Functor::argument_type,
- class result_type = typename _Functor::result_type>
- class FunctorRef : public std::unary_function<argument_type, result_type>
- {
- public:
- FunctorRef( _Functor & f_r )
- : _f( f_r )
- {}
-
- typename FunctorRef::result_type operator()( typename FunctorRef::argument_type a1 ) const
- {
- return _f( a1 );
- }
-
- private:
- _Functor & _f;
- };
-
- /** Convenience function creating a \ref FunctorRef. */
- template <class _Functor>
- FunctorRef<_Functor> functorRef( _Functor & f_r )
- { return FunctorRef<_Functor>( f_r ); }
-
- /** Convenience function creating a \ref FunctorRef. */
- template <class _Functor, class argument_type, class result_type>
- FunctorRef<_Functor,argument_type,result_type> functorRef( _Functor & f_r )
- { return FunctorRef<_Functor,argument_type,result_type>( f_r ); }
-
- /////////////////////////////////////////////////////////////////
-} // namespace functor
- ///////////////////////////////////////////////////////////////////
- /////////////////////////////////////////////////////////////////
-} // namespace zypp
-///////////////////////////////////////////////////////////////////
-#endif // ZYPP_BASE_FUNCTORREF_H
#ifndef ZYPP_BASE_ITERATOR_H
#define ZYPP_BASE_ITERATOR_H
+#include <iterator>
+
#include <boost/iterator/filter_iterator.hpp>
#include <boost/iterator/transform_iterator.hpp>
#include <boost/function_output_iterator.hpp>
baseinclude_HEADERS = \
Debug.h \
+ \
+ Algorithm.h \
+ Exception.h \
+ Functional.h \
+ Iterator.h \
+ Logger.h \
+ \
Fd.h \
KindOf.h \
- Logger.h \
- Exception.h \
Gettext.h \
IOStream.h \
- Iterator.h \
NonCopyable.h \
PtrTypes.h \
ReferenceCounted.h \