prophet::BundleOfferComp Struct Reference

#include <FwdStrategy.h>

List of all members.


Detailed Description

Due to extensive use of copy constructors in the STL, any inheritance hierarchy of comparators will always get "clipped" back to the base type.

See Scott Meyer's excellent text on "Effective STL." To get around this limitation, use a wrapper that invokes the proper method based on a pointer dereference. It's a long explanation, and the book is worth every penny, so go spend US$40 and read up on it.

Definition at line 204 of file FwdStrategy.h.


Public Member Functions

 BundleOfferComp (const FwdStrategyComp *comp)
bool operator() (const Bundle *a, const Bundle *b) const

Public Attributes

const FwdStrategyCompcomp_
 pointer to actual comparator instance

Constructor & Destructor Documentation

prophet::BundleOfferComp::BundleOfferComp ( const FwdStrategyComp comp  )  [inline]

Definition at line 207 of file FwdStrategy.h.


Member Function Documentation

bool prophet::BundleOfferComp::operator() ( const Bundle a,
const Bundle b 
) const [inline]

Definition at line 210 of file FwdStrategy.h.

References comp_.


Member Data Documentation

pointer to actual comparator instance

Definition at line 215 of file FwdStrategy.h.

Referenced by operator()().


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

Generated on Mon Jul 21 14:12:22 2008 for DTN Reference Implementation by  doxygen 1.5.6