diff --git a/lemon/bits/traits.h b/lemon/bits/traits.h --- a/lemon/bits/traits.h +++ b/lemon/bits/traits.h @@ -1,7 +1,6 @@ - -/* -*- C++ -*- +/* -*- mode: C++; indent-tabs-mode: nil; -*- * - * This file is a part of LEMON, a generic C++ optimization library + * This file is a part of LEMON, a generic C++ optimization library. * * Copyright (C) 2003-2008 * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport @@ -29,7 +28,7 @@ namespace lemon { template class ItemSetTraits {}; - + template struct NodeNotifierIndicator { @@ -37,16 +36,16 @@ }; template struct NodeNotifierIndicator< - Graph, + Graph, typename enable_if::type - > { + > { typedef typename Graph::NodeNotifier Type; }; template class ItemSetTraits<_Graph, typename _Graph::Node> { public: - + typedef _Graph Graph; typedef typename Graph::Node Item; @@ -57,13 +56,13 @@ template class Map : public Graph::template NodeMap<_Value> { public: - typedef typename Graph::template NodeMap<_Value> Parent; - typedef typename Graph::template NodeMap<_Value> Type; + typedef typename Graph::template NodeMap<_Value> Parent; + typedef typename Graph::template NodeMap<_Value> Type; typedef typename Parent::Value Value; Map(const Graph& _digraph) : Parent(_digraph) {} - Map(const Graph& _digraph, const Value& _value) - : Parent(_digraph, _value) {} + Map(const Graph& _digraph, const Value& _value) + : Parent(_digraph, _value) {} }; @@ -75,16 +74,16 @@ }; template struct ArcNotifierIndicator< - Graph, + Graph, typename enable_if::type - > { + > { typedef typename Graph::ArcNotifier Type; }; template class ItemSetTraits<_Graph, typename _Graph::Arc> { public: - + typedef _Graph Graph; typedef typename Graph::Arc Item; @@ -95,13 +94,13 @@ template class Map : public Graph::template ArcMap<_Value> { public: - typedef typename Graph::template ArcMap<_Value> Parent; - typedef typename Graph::template ArcMap<_Value> Type; + typedef typename Graph::template ArcMap<_Value> Parent; + typedef typename Graph::template ArcMap<_Value> Type; typedef typename Parent::Value Value; Map(const Graph& _digraph) : Parent(_digraph) {} - Map(const Graph& _digraph, const Value& _value) - : Parent(_digraph, _value) {} + Map(const Graph& _digraph, const Value& _value) + : Parent(_digraph, _value) {} }; }; @@ -112,16 +111,16 @@ }; template struct EdgeNotifierIndicator< - Graph, + Graph, typename enable_if::type - > { + > { typedef typename Graph::EdgeNotifier Type; }; template class ItemSetTraits<_Graph, typename _Graph::Edge> { public: - + typedef _Graph Graph; typedef typename Graph::Edge Item; @@ -132,13 +131,13 @@ template class Map : public Graph::template EdgeMap<_Value> { public: - typedef typename Graph::template EdgeMap<_Value> Parent; - typedef typename Graph::template EdgeMap<_Value> Type; + typedef typename Graph::template EdgeMap<_Value> Parent; + typedef typename Graph::template EdgeMap<_Value> Type; typedef typename Parent::Value Value; Map(const Graph& _digraph) : Parent(_digraph) {} - Map(const Graph& _digraph, const Value& _value) - : Parent(_digraph, _value) {} + Map(const Graph& _digraph, const Value& _value) + : Parent(_digraph, _value) {} }; }; @@ -156,17 +155,17 @@ template struct MapTraits< - Map, typename enable_if::type > + Map, typename enable_if::type > { typedef True ReferenceMapTag; - + typedef typename Map::Key Key; typedef typename Map::Value Value; typedef typename Map::ConstReference ConstReturnValue; typedef typename Map::Reference ReturnValue; - typedef typename Map::ConstReference ConstReference; + typedef typename Map::ConstReference ConstReference; typedef typename Map::Reference Reference; }; @@ -184,11 +183,11 @@ template struct MatrixMapTraits< - MatrixMap, typename enable_if::type > + MatrixMap, typename enable_if::type > { typedef True ReferenceMapTag; - + typedef typename MatrixMap::FirstKey FirstKey; typedef typename MatrixMap::SecondKey SecondKey; typedef typename MatrixMap::Value Value; @@ -196,7 +195,7 @@ typedef typename MatrixMap::ConstReference ConstReturnValue; typedef typename MatrixMap::Reference ReturnValue; - typedef typename MatrixMap::ConstReference ConstReference; + typedef typename MatrixMap::ConstReference ConstReference; typedef typename MatrixMap::Reference Reference; }; @@ -209,7 +208,7 @@ template struct NodeNumTagIndicator< - Graph, + Graph, typename enable_if::type > { static const bool value = true; @@ -222,7 +221,7 @@ template struct EdgeNumTagIndicator< - Graph, + Graph, typename enable_if::type > { static const bool value = true; @@ -235,7 +234,7 @@ template struct FindEdgeTagIndicator< - Graph, + Graph, typename enable_if::type > { static const bool value = true; @@ -248,7 +247,7 @@ template struct UndirectedTagIndicator< - Graph, + Graph, typename enable_if::type > { static const bool value = true; @@ -261,7 +260,7 @@ template struct BuildTagIndicator< - Graph, + Graph, typename enable_if::type > { static const bool value = true;