Changes in / [1008:b7ed95cd94a3:1068:e8afd887d706] in lemon
- Files:
-
- 1 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
doc/lgf.dox
r313 r1067 64 64 \endcode 65 65 66 The \c \@arcs section is very similar to the \c \@nodes section, 67 it again starts with a header line describing the names of the maps, 68 butthe \c "label" map is not obligatory here. The following lines69 describe the arcs. The first two tokens of each line are 70 the sourceand the target node of the arc, respectively, then come the map66 The \c \@arcs section is very similar to the \c \@nodes section, it 67 again starts with a header line describing the names of the maps, but 68 the \c "label" map is not obligatory here. The following lines 69 describe the arcs. The first two tokens of each line are the source 70 and the target node of the arc, respectively, then come the map 71 71 values. The source and target tokens must be node labels. 72 72 … … 79 79 \endcode 80 80 81 If there is no map in the \c \@arcs section at all, then it must be 82 indicated by a sole '-' sign in the first line. 83 84 \code 85 @arcs 86 - 87 1 2 88 1 3 89 2 3 90 \endcode 91 81 92 The \c \@edges is just a synonym of \c \@arcs. The \@arcs section can 82 93 also store the edge set of an undirected graph. In such case there is 83 94 a conventional method for store arc maps in the file, if two columns 84 ha sthe same caption with \c '+' and \c '-' prefix, then these columns95 have the same caption with \c '+' and \c '-' prefix, then these columns 85 96 can be regarded as the values of an arc map. 86 97 -
lemon/lgf_reader.h
r519 r1068 3 3 * This file is a part of LEMON, a generic C++ optimization library. 4 4 * 5 * Copyright (C) 2003-20 085 * Copyright (C) 2003-2011 6 6 * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport 7 7 * (Egervary Research Group on Combinatorial Optimization, EGRES). … … 966 966 int index = 0; 967 967 while (_reader_bits::readToken(line, map)) { 968 if(map == "-") { 969 if(index!=0) 970 throw FormatError("'-' is not allowed as a map name"); 971 else if (line >> std::ws >> c) 972 throw FormatError("Extra character at the end of line"); 973 else break; 974 } 968 975 if (maps.find(map) != maps.end()) { 969 976 std::ostringstream msg; … … 1808 1815 int index = 0; 1809 1816 while (_reader_bits::readToken(line, map)) { 1817 if(map == "-") { 1818 if(index!=0) 1819 throw FormatError("'-' is not allowed as a map name"); 1820 else if (line >> std::ws >> c) 1821 throw FormatError("Extra character at the end of line"); 1822 else break; 1823 } 1810 1824 if (maps.find(map) != maps.end()) { 1811 1825 std::ostringstream msg; -
test/CMakeLists.txt
r539 r1067 19 19 heap_test 20 20 kruskal_test 21 lgf_test 21 22 maps_test 22 23 random_test -
test/Makefile.am
r228 r1067 19 19 test/heap_test \ 20 20 test/kruskal_test \ 21 test/lgf_test \ 21 22 test/maps_test \ 22 23 test/random_test \ … … 42 43 test_heap_test_SOURCES = test/heap_test.cc 43 44 test_kruskal_test_SOURCES = test/kruskal_test.cc 45 test_lgf_test_SOURCES = test/lgf_test.cc 44 46 test_maps_test_SOURCES = test/maps_test.cc 45 47 test_path_test_SOURCES = test/path_test.cc
Note: See TracChangeset
for help on using the changeset viewer.