gravatar
alpar (Alpar Juttner)
alpar@cs.elte.hu
Def -> Set renaming in Preflow
0 2 0
default
2 files changed with 13 insertions and 13 deletions:
↑ Collapse diff ↑
Ignore white space 12 line context
... ...
@@ -190,13 +190,13 @@
190 190

	
191 191
    ///\name Named template parameters
192 192

	
193 193
    ///@{
194 194

	
195 195
    template <typename _FlowMap>
196
    struct DefFlowMapTraits : public Traits {
196
    struct SetFlowMapTraits : public Traits {
197 197
      typedef _FlowMap FlowMap;
198 198
      static FlowMap *createFlowMap(const Digraph&) {
199 199
        LEMON_ASSERT(false, "FlowMap is not initialized");
200 200
        return 0; // ignore warnings
201 201
      }
202 202
    };
... ...
@@ -204,20 +204,20 @@
204 204
    /// \brief \ref named-templ-param "Named parameter" for setting
205 205
    /// FlowMap type
206 206
    ///
207 207
    /// \ref named-templ-param "Named parameter" for setting FlowMap
208 208
    /// type
209 209
    template <typename _FlowMap>
210
    struct DefFlowMap
211
      : public Preflow<Digraph, CapacityMap, DefFlowMapTraits<_FlowMap> > {
210
    struct SetFlowMap
211
      : public Preflow<Digraph, CapacityMap, SetFlowMapTraits<_FlowMap> > {
212 212
      typedef Preflow<Digraph, CapacityMap,
213
                      DefFlowMapTraits<_FlowMap> > Create;
213
                      SetFlowMapTraits<_FlowMap> > Create;
214 214
    };
215 215

	
216 216
    template <typename _Elevator>
217
    struct DefElevatorTraits : public Traits {
217
    struct SetElevatorTraits : public Traits {
218 218
      typedef _Elevator Elevator;
219 219
      static Elevator *createElevator(const Digraph&, int) {
220 220
        LEMON_ASSERT(false, "Elevator is not initialized");
221 221
        return 0; // ignore warnings
222 222
      }
223 223
    };
... ...
@@ -225,20 +225,20 @@
225 225
    /// \brief \ref named-templ-param "Named parameter" for setting
226 226
    /// Elevator type
227 227
    ///
228 228
    /// \ref named-templ-param "Named parameter" for setting Elevator
229 229
    /// type
230 230
    template <typename _Elevator>
231
    struct DefElevator
232
      : public Preflow<Digraph, CapacityMap, DefElevatorTraits<_Elevator> > {
231
    struct SetElevator
232
      : public Preflow<Digraph, CapacityMap, SetElevatorTraits<_Elevator> > {
233 233
      typedef Preflow<Digraph, CapacityMap,
234
                      DefElevatorTraits<_Elevator> > Create;
234
                      SetElevatorTraits<_Elevator> > Create;
235 235
    };
236 236

	
237 237
    template <typename _Elevator>
238
    struct DefStandardElevatorTraits : public Traits {
238
    struct SetStandardElevatorTraits : public Traits {
239 239
      typedef _Elevator Elevator;
240 240
      static Elevator *createElevator(const Digraph& digraph, int max_level) {
241 241
        return new Elevator(digraph, max_level);
242 242
      }
243 243
    };
244 244

	
... ...
@@ -246,17 +246,17 @@
246 246
    /// Elevator type
247 247
    ///
248 248
    /// \ref named-templ-param "Named parameter" for setting Elevator
249 249
    /// type. The Elevator should be standard constructor interface, ie.
250 250
    /// the digraph and the maximum level should be passed to it.
251 251
    template <typename _Elevator>
252
    struct DefStandardElevator
252
    struct SetStandardElevator
253 253
      : public Preflow<Digraph, CapacityMap,
254
                       DefStandardElevatorTraits<_Elevator> > {
254
                       SetStandardElevatorTraits<_Elevator> > {
255 255
      typedef Preflow<Digraph, CapacityMap,
256
                      DefStandardElevatorTraits<_Elevator> > Create;
256
                      SetStandardElevatorTraits<_Elevator> > Create;
257 257
    };
258 258

	
259 259
    /// @}
260 260

	
261 261
  protected:
262 262

	
Ignore white space 12 line context
... ...
@@ -43,13 +43,13 @@
43 43
  Node n;
44 44
  Arc e;
45 45
  CapMap cap;
46 46
  FlowMap flow;
47 47
  CutMap cut;
48 48

	
49
  Preflow<Digraph, CapMap>::DefFlowMap<FlowMap>::Create preflow_test(g,cap,n,n);
49
  Preflow<Digraph, CapMap>::SetFlowMap<FlowMap>::Create preflow_test(g,cap,n,n);
50 50

	
51 51
  preflow_test.capacityMap(cap);
52 52
  flow = preflow_test.flowMap();
53 53
  preflow_test.flowMap(flow);
54 54
  preflow_test.source(n);
55 55
  preflow_test.target(n);
0 comments (0 inline)