DataObjectRequest< RequestType > Class Template Reference
This class has two functions.
More...
#include <DataObject.h>
Detailed Description
template<class RequestType>
class DataObjectRequest< RequestType >
This class has two functions.
- It's a message functor that can be handed to arrays. Arrays that have data objects will support the function: array.dataBlockRequest(datablocktag); To implement the message function, the engine should call operator() on the DataObjectRequest with a pointer to the data object.
- It's a LeafFunctor tag class that allows us to apply smarts data object to expressions.
In cases where the engine contains an expression, the request will be passed on to engines in the expression that have data objects. For example, if we use DataObjectRequest to request a lock on a stencil engine, it uses forEach to request the same lock on all the engines in the expression contained inside the stencil.
To implement a version of DataObjectRequest<Request>, the following interface is required:
- typedef ... Type_t;
- typedef ... Combine_t;
- Type_t operator()(Pooma::DataObject_t*) const;
- Type_t defaultValue() const;
Type_t is the return type of the functor. Combine_t is a ForEach combine tag that will be used if the engine contains an expression. operator() lets you compute the return value given a pointer to the actual data object. defaultValue() returns the value that should be returned when there is no data object.
The documentation for this class was generated from the following file: