Bug fixes
authordeba
Tue, 31 Oct 2006 14:27:58 +0000
changeset 22829d7b12f83daa
parent 2281 55b15666560f
child 2283 a877258468e4
Bug fixes
lemon/lemon_reader.h
lemon/lemon_writer.h
     1.1 --- a/lemon/lemon_reader.h	Tue Oct 31 09:32:44 2006 +0000
     1.2 +++ b/lemon/lemon_reader.h	Tue Oct 31 14:27:58 2006 +0000
     1.3 @@ -117,8 +117,8 @@
     1.4        }
     1.5  
     1.6      private:
     1.7 +      const Graph& graph;
     1.8        typename Ref<Map>::Type map;
     1.9 -      const Graph& graph;
    1.10      };
    1.11  
    1.12      template <typename Graph, typename Map>
    1.13 @@ -147,8 +147,8 @@
    1.14        }
    1.15  
    1.16      private:
    1.17 +      const Graph& graph;
    1.18        typename Ref<Map>::Type map;
    1.19 -      const Graph& graph;
    1.20      };
    1.21  
    1.22  
    1.23 @@ -1377,10 +1377,10 @@
    1.24  				    const Reader& reader = Reader()) { 
    1.25        checkConcept<_reader_bits::ItemReader<typename Map::Value>, Reader>();
    1.26        checkConcept<concepts::WriteMap<Edge, typename Map::Value>, Map>();
    1.27 -      readMap("+" + name, 
    1.28 -	      _reader_bits::forwardComposeMap(graph, map), reader);
    1.29 -      readMap("-" + name, 
    1.30 -	      _reader_bits::backwardComposeMap(graph, map), reader);
    1.31 +      readUEdgeMap("+" + name, 
    1.32 +                   _reader_bits::forwardComposeMap(graph, map), reader);
    1.33 +      readUEdgeMap("-" + name, 
    1.34 +                   _reader_bits::backwardComposeMap(graph, map), reader);
    1.35        return *this;      
    1.36      }
    1.37  
    1.38 @@ -1391,9 +1391,9 @@
    1.39      /// Add a new directed edge map skipper command for the reader.
    1.40      template <typename Reader>
    1.41      UEdgeSetReader& skipEdgeMap(std::string name, 
    1.42 -				    const Reader& reader = Reader()) {
    1.43 -      skipMap("+" + name, reader);
    1.44 -      skipMap("-" + name, reader);
    1.45 +                                const Reader& reader = Reader()) {
    1.46 +      skipUEdgeMap("+" + name, reader);
    1.47 +      skipUEdgeMap("-" + name, reader);
    1.48        return *this;
    1.49      }
    1.50  
     2.1 --- a/lemon/lemon_writer.h	Tue Oct 31 09:32:44 2006 +0000
     2.2 +++ b/lemon/lemon_writer.h	Tue Oct 31 14:27:58 2006 +0000
     2.3 @@ -877,7 +877,7 @@
     2.4      /// Add a new undirected map writer command for the writer.
     2.5      template <typename Writer, typename Map>
     2.6      UEdgeSetWriter& writeUEdgeMap(std::string name, const Map& map, 
     2.7 -					  const Writer& writer = Writer()) {
     2.8 +                                  const Writer& writer = Writer()) {
     2.9        checkConcept<concepts::ReadMap<UEdge, typename Map::Value>, Map>();
    2.10        checkConcept<_writer_bits::ItemWriter<typename Map::Value>, Writer>();
    2.11        writers.push_back(
    2.12 @@ -900,13 +900,13 @@
    2.13      /// Add a new directed map writer command for the writer.
    2.14      template <typename Writer, typename Map>
    2.15      UEdgeSetWriter& writeEdgeMap(std::string name, const Map& map, 
    2.16 -				     const Writer& writer = Writer()) {
    2.17 +                                 const Writer& writer = Writer()) {
    2.18        checkConcept<concepts::ReadMap<Edge, typename Map::Value>, Map>();
    2.19        checkConcept<_writer_bits::ItemWriter<typename Map::Value>, Writer>();
    2.20 -      writeUEdge("+" + name, 
    2.21 -		     _writer_bits::forwardComposeMap(graph, map), writer);
    2.22 -      writeUEdge("-" + name, 
    2.23 -		     _writer_bits::backwardComposeMap(graph, map), writer);
    2.24 +      writeUEdgeMap("+" + name, 
    2.25 +                    _writer_bits::forwardComposeMap(graph, map), writer);
    2.26 +      writeUEdgeMap("-" + name, 
    2.27 +                    _writer_bits::backwardComposeMap(graph, map), writer);
    2.28        return *this;
    2.29      }
    2.30  
    2.31 @@ -955,7 +955,7 @@
    2.32  	os << writers[i].first << '\t';
    2.33        }
    2.34        os << std::endl;
    2.35 -      for (typename std::vector<Edge>::iterator it = items.begin();
    2.36 +      for (typename std::vector<UEdge>::iterator it = items.begin();
    2.37             it != items.end(); ++it) {
    2.38  	nodeLabelWriter->write(os, graph.source(*it));
    2.39  	os << '\t';