PolyBoRi
WeakRingPtr.h
Go to the documentation of this file.
1 // -*- c++ -*-
2 //*****************************************************************************
14 //*****************************************************************************
15 
16 #ifndef polybori_WeakRingPtr_h_
17 #define polybori_WeakRingPtr_h_
18 
19 // include basic definitions
20 #include <polybori/pbori_defs.h>
22 #include <polybori/BoolePolyRing.h>
23 
25 
32 class WeakRingPtr {
34  typedef WeakRingPtr self;
35 
36 public:
38 
40  WeakRingPtr(const value_type& data): m_data(*data.core()) {}
41 
43  WeakRingPtr(const self& rhs): m_data(rhs.m_data) {}
44 
47 
49  value_type operator*() const { return value_type(m_data); }
50 
52  operator bool() const { return m_data; }
53 
54 private:
56 };
57 
59 
60 #endif /* polybori_WeakRingPtr_h_ */