Sha256: c3e32463065ac76a80deebccf4a0f282a40d3547ffbb6a93039ab936bfac6431
Contents?: true
Size: 1.04 KB
Versions: 1
Compression:
Stored size: 1.04 KB
Contents
/* * Main authors: * Christian Schulte <schulte@gecode.org> * * Copyright: * Christian Schulte, 2006 * * Last modified: * $Date: 2006-08-04 16:03:17 +0200 (Fri, 04 Aug 2006) $ by $Author: schulte $ * $Revision: 3511 $ * * This file is part of Gecode, the generic constraint * development environment: * http://www.gecode.org * * See the file "LICENSE" for information on usage and * redistribution of this file, and for a * DISCLAIMER OF ALL WARRANTIES. * */ #include "gecode/search.hh" namespace Gecode { namespace Search { /* * Stopping for memory limit * */ bool MemoryStop::stop(const Statistics& s) { return s.memory > l; } /* * Stopping for memory limit * */ bool FailStop::stop(const Statistics& s) { return s.fail > l; } /* * Stopping for memory limit * */ bool TimeStop::stop(const Statistics&) { return static_cast<unsigned long int> ((static_cast<double>(clock()-s)/CLOCKS_PER_SEC) * 1000.0) > l; } }} // STATISTICS: search-any
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
gecoder-with-gecode-0.7.1 | ext/gecode-1.3.1/gecode/search/stop.cc |