Generated on Fri May 4 2012 13:51:57 for Gecode by doxygen 1.7.6.1
Gecode::Search::TimeStop Class Reference

Stop-object based on time More...

#include <search.hh>

List of all members.

Public Member Functions

 TimeStop (unsigned long int l)
 Stop if search exceeds l milliseconds (from creation of this object)
unsigned long int limit (void) const
 Return current limit in milliseconds.
void limit (unsigned long int l)
 Set current limit to l milliseconds.
void reset (void)
 Reset time to zero.
virtual bool stop (const Statistics &s, const Options &o)
 Return true if time limit is exceeded.

Protected Attributes

Support::Timer t
 Time when execution should stop.
unsigned long int l
 Current limit in milliseconds.

Detailed Description

Stop-object based on time

Definition at line 279 of file search.hh.


Constructor & Destructor Documentation

Gecode::Search::TimeStop::TimeStop ( unsigned long int  l) [inline]

Stop if search exceeds l milliseconds (from creation of this object)

Definition at line 115 of file stop.hpp.


Member Function Documentation

unsigned long int Gecode::Search::TimeStop::limit ( void  ) const [inline]

Return current limit in milliseconds.

Definition at line 121 of file stop.hpp.

void Gecode::Search::TimeStop::limit ( unsigned long int  l) [inline]

Set current limit to l milliseconds.

Definition at line 126 of file stop.hpp.

void Gecode::Search::TimeStop::reset ( void  ) [inline]

Reset time to zero.

Definition at line 131 of file stop.hpp.

bool Gecode::Search::TimeStop::stop ( const Statistics s,
const Options o 
) [virtual]

Return true if time limit is exceeded.

Implements Gecode::Search::Stop.

Definition at line 77 of file stop.cpp.


Member Data Documentation

Time when execution should stop.

Definition at line 282 of file search.hh.

unsigned long int Gecode::Search::TimeStop::l [protected]

Current limit in milliseconds.

Definition at line 284 of file search.hh.


The documentation for this class was generated from the following files: