2#ifndef Rivet_Projection_FHH
3#define Rivet_Projection_FHH
5/// @todo Is there a reason that this stuff can't go into Projection.hh?
7#include "Rivet/Config/RivetCommon.hh"
8#include "Rivet/Tools/Cmp.fhh"
13 typedef Projection* ProjectionPtr;
14 typedef const Projection* ConstProjectionPtr;
20 /// This is the function called when comparing two (const) pointers to Rivet::Projection.
22 struct less<const Rivet::Projection*> {
23 bool operator()(const Rivet::Projection* x, const Rivet::Projection* y) const;
31 /// Convenience method for casting to a const Projection reference.
32 template <typename PROJ>
33 inline const PROJ& pcast(const Projection& p) {
34 return dynamic_cast<const PROJ&>(p);
38 /// Convenience method for casting to a const Projection pointer.
39 template <typename PROJ>
40 inline const PROJ* pcast(const Projection* p) {
41 return dynamic_cast<const PROJ*>(p);