ReFRACtor
null_deleter.h
Go to the documentation of this file.
1 #ifndef NULL_DELETER_H
2 #define NULL_DELETER_H
3 #include <boost/shared_ptr.hpp>
4 
5 namespace FullPhysics {
6 /****************************************************************/
12 {
13 public:
14  void operator()(void const *) const
15  {
16  }
17 };
18 
19 //-----------------------------------------------------------------------
22 //-----------------------------------------------------------------------
23 
24 template<class T> boost::shared_ptr<T> to_ptr(T& t)
25 { return boost::shared_ptr<T>(&t, null_deleter());}
26 }
27 #endif
void operator()(void const *) const
Definition: null_deleter.h:14
boost::shared_ptr< T > to_ptr(T &t)
Helper routine to get a shared_ptr from a reference.
Definition: null_deleter.h:24
Contains classes to abstract away details in various Spurr Radiative Transfer software.
Definition: doxygen_python.h:1
Class for use with boost::shared_ptr when we don&#39;t want data to be deleted.
Definition: null_deleter.h:11

Copyright © 2017, California Institute of Technology.
ALL RIGHTS RESERVED.
U.S. Government Sponsorship acknowledged.
Generated Fri Aug 24 2018 15:44:11