Differential Evolution C++ library
de::processor< T > Class Template Reference

#include <processors.hpp>

List of all members.

Public Member Functions

 processor (size_t index, T of, individual_queue &indQueue, processor_listener_ptr listener)
void operator() ()
bool success () const

Detailed Description

template<typename T>
class de::processor< T >

A processor runs the objective function in one thread. There can be any number of processors running the objective function in parallel in as many threads.

The processor class uses the type of the objective function defined in the corresponding processor_traits

Author:
adrian (12/1/2011)

Constructor & Destructor Documentation

template<typename T >
de::processor< T >::processor ( size_t  index,
of,
individual_queue indQueue,
processor_listener_ptr  listener 
) [inline]

constructs a processor object

Author:
adrian (12/4/2011)
Parameters:
indexthe processor index
ofobjective function, or objective function factory. Accepts pointer, shared pointer, reference
indQueuequeue containing the individuals to process
listenerlistener that will receive notifications of important events during the processing of the objective function

Member Function Documentation

template<typename T >
void de::processor< T >::operator() ( ) [inline]

runs the objective function on the object at the top of the queue, if any

Author:
adrian (12/4/2011)

Here is the call graph for this function:

template<typename T >
bool de::processor< T >::success ( ) const [inline]

indicates whether the run ended succesfully when the thread exits

Author:
adrian (12/4/2011)
Returns:
bool

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