WeakRingPtr.h
Go to the documentation of this file.
// -*- c++ -*-
//*****************************************************************************
//*****************************************************************************
#ifndef polybori_WeakRingPtr_h_
#define polybori_WeakRingPtr_h_
// include basic definitions
#include <polybori/pbori_defs.h>
#include <polybori/common/CWeakPtr.h>
#include <polybori/BoolePolyRing.h>
BEGIN_NAMESPACE_PBORI
class WeakRingPtr {
typedef WeakRingPtr self;
public:
typedef BoolePolyRing value_type;
WeakRingPtr(const value_type& data): m_data(*data.core()) {}
WeakRingPtr(const self& rhs): m_data(rhs.m_data) {}
~WeakRingPtr() {}
value_type operator*() const { return value_type(m_data); }
operator bool() const { return m_data; }
private:
CWeakPtr<value_type::core_type> m_data;
};
END_NAMESPACE_PBORI
#endif /* polybori_WeakRingPtr_h_ */
END_NAMESPACE_PBORI
#define END_NAMESPACE_PBORI
Finish project's namespace.
Definition: pbori_defs.h:77
BEGIN_NAMESPACE_PBORI
#define BEGIN_NAMESPACE_PBORI
Start project's namespace.
Definition: pbori_defs.h:74
polybori::BoolePolyRing
This class reinterprets decicion diagram managers as Boolean polynomial rings, adds an ordering and v...
Definition: BoolePolyRing.h:40
polybori::WeakRingPtr
This class defines WeakRingPtr.
Definition: WeakRingPtr.h:32
polybori::WeakRingPtr::WeakRingPtr
WeakRingPtr(const self &rhs)
Copy constructor.
Definition: WeakRingPtr.h:43
pbori_defs.h
CWeakPtr.h
polybori::WeakRingPtr::operator*
value_type operator*() const
Dereferencing.
Definition: WeakRingPtr.h:49
BoolePolyRing.h
polybori::CWeakPtr
Forward declaration of friend.
Definition: CWeakPtr.h:31
polybori::WeakRingPtr::WeakRingPtr
WeakRingPtr(const value_type &data)
Default constructor.
Definition: WeakRingPtr.h:40
polybori::WeakRingPtr::value_type
BoolePolyRing value_type
Definition: WeakRingPtr.h:37
polybori::WeakRingPtr::~WeakRingPtr
~WeakRingPtr()
Destructor.
Definition: WeakRingPtr.h:46