COIN-OR::LEMON - Graph Library

Changeset 564:2b6d5d22bb23 in lemon for lemon/path.h


Ignore:
Timestamp:
02/20/09 22:37:19 (15 years ago)
Author:
Alpar Juttner <alpar@…>
Branch:
default
Parents:
563:dab9e610e37d (diff), 518:b1ef32ab39f3 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Phase:
public
Message:

Merge

Files:
2 edited

Legend:

Unmodified
Added
Removed
  • lemon/path.h

    r517 r564  
    33 * This file is a part of LEMON, a generic C++ optimization library.
    44 *
    5  * Copyright (C) 2003-2008
     5 * Copyright (C) 2003-2009
    66 * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
    77 * (Egervary Research Group on Combinatorial Optimization, EGRES).
  • lemon/path.h

    r463 r564  
    930930
    931931    template <typename Target, typename Source,
    932               bool buildEnable = BuildTagIndicator<Target>::value,
    933               bool revEnable = RevPathTagIndicator<Source>::value>
    934     struct PathCopySelector {
     932              bool buildEnable = BuildTagIndicator<Target>::value>
     933    struct PathCopySelectorForward {
    935934      static void copy(Target& target, const Source& source) {
    936935        target.clear();
     
    942941
    943942    template <typename Target, typename Source>
    944     struct PathCopySelector<Target, Source, false, true> {
     943    struct PathCopySelectorForward<Target, Source, true> {
     944      static void copy(Target& target, const Source& source) {
     945        target.clear();
     946        target.build(source);
     947      }
     948    };
     949
     950    template <typename Target, typename Source,
     951              bool buildEnable = BuildTagIndicator<Target>::value>
     952    struct PathCopySelectorBackward {
    945953      static void copy(Target& target, const Source& source) {
    946954        target.clear();
     
    952960
    953961    template <typename Target, typename Source>
    954     struct PathCopySelector<Target, Source, true, false> {
    955       static void copy(Target& target, const Source& source) {
    956         target.clear();
    957         target.build(source);
    958       }
    959     };
    960 
    961     template <typename Target, typename Source>
    962     struct PathCopySelector<Target, Source, true, true> {
     962    struct PathCopySelectorBackward<Target, Source, true> {
    963963      static void copy(Target& target, const Source& source) {
    964964        target.clear();
    965965        target.buildRev(source);
    966966      }
     967    };
     968
     969   
     970    template <typename Target, typename Source,
     971              bool revEnable = RevPathTagIndicator<Source>::value>
     972    struct PathCopySelector {
     973      static void copy(Target& target, const Source& source) {
     974        PathCopySelectorForward<Target, Source>::copy(target, source);
     975      }     
     976    };
     977
     978    template <typename Target, typename Source>
     979    struct PathCopySelector<Target, Source, true> {
     980      static void copy(Target& target, const Source& source) {
     981        PathCopySelectorBackward<Target, Source>::copy(target, source);
     982      }     
    967983    };
    968984
Note: See TracChangeset for help on using the changeset viewer.