BooleEnv.h
Go to the documentation of this file.
// -*- c++ -*-
//*****************************************************************************
//*****************************************************************************
#ifndef polybori_BooleEnv_h_
#define polybori_BooleEnv_h_
// load PolyBoRi settings
# include <polybori/pbori_defs.h>
#include <polybori/BoolePolyRing.h>
#include <vector>
// Obey stricter dependence of Sun Studio compiler
// todo: resolve dependency
#if defined(__SUNPRO_C) || defined(__SUNPRO_CC)
# define PBORI_ENV_RING_NOTINLINED
#endif
BEGIN_NAMESPACE_PBORI
class BoolePolyRing;
//extern BoolePolyRing active_ring;
class COrderingBase;
class BooleEnv:
public CTypes::orderenums_type, public CTypes::compenums_type,
public CTypes::auxtypes_type {
public:
//-------------------------------------------------------------------------
// types definitions
//-------------------------------------------------------------------------
typedef BooleEnv self;
typedef CTypes::orderenums_type base;
typedef CTypes::ordercode_type ordercode_type;
typedef BoolePolyRing::dd_type dd_type;
typedef BoolePolyRing::var_type var_type;
typedef CTypes::vartext_type vartext_type;
typedef std::vector<idx_type> block_idx_type;
typedef block_idx_type::const_iterator block_iterator;
//-------------------------------------------------------------------------
// constructors and destructor
//-------------------------------------------------------------------------
using base::ordercodes;
// /// Access idx-th variable of the active ring
// static var_type variable(idx_type idx);
// /// Get numerical code for current ordering
// static ordercode_type getOrderCode();
// /// Get numerical code for current base ordering
// /// (the same for non-block orderings)
// static ordercode_type getBaseOrderCode();
// /// Get empty decision diagram
// static dd_type zero();
// /// Get decision diagram with all variables negated
// static dd_type one();
// /// Get number of ring variables the of active ring
// static size_type nVariables();
typedef BoolePolyRing ring_type;
typedef COrderingBase order_type;
// private:
// #ifdef PBORI_ENV_RING_NOTINLINED
// static ring_type& ring();
// #else
// static ring_type& ring() {
// static BooleEnv::ring_type active_ring(1000, CTypes::lp, false);
// return active_ring;
// }
// #endif
// // static manager_type& manager();
// static order_type& ordering();
// public:
// /// Set name of variable with index idx
// static void setVariableName(idx_type idx, vartext_type varname);
// /// Get name of variable with index idx
// static vartext_type getVariableName(idx_type idx);
// /// @name interface for block orderings, if the vcurrent orderins is a block ordering
// //@{
// /// Returns iterator over the indices, where the (next) block starts.
// /// (The first one implicitely starts at zero.)
// static block_iterator blockBegin();
// /// Returns end marker of iteration
// static block_iterator blockEnd();
// /// Add index where the next block starts
// static void appendBlock(idx_type idx);
// /// Reset block-related data
// static void clearBlocks();
// /// Index where the last blocks starts
// static idx_type lastBlockStart();
// //@}
// /// Change order of current ring
// static void changeOrdering(ordercode_type code);
// /// Print low-level information
// static ostream_type& print(ostream_type&);
// /// Activate given ring
// static void set(ring_type& theRing);
};
BooleEnv::block_iterator
block_begin(const BooleEnv::ring_type& ring);
BooleEnv::block_iterator
block_end(const BooleEnv::ring_type& ring);
END_NAMESPACE_PBORI
#endif // of #ifndef polybori_BooleEnv_h_
polybori::block_begin
BooleEnv::block_iterator block_begin(const BooleEnv::ring_type &ring)
please use BooleEnv::ring()
Definition: BooleEnv.cc:138
END_NAMESPACE_PBORI
#define END_NAMESPACE_PBORI
Finish project's namespace.
Definition: pbori_defs.h:77
polybori::BooleEnv::ring_type
BoolePolyRing ring_type
Definition: BooleEnv.h:101
polybori::BooleEnv::block_iterator
block_idx_type::const_iterator block_iterator
Type for block iterators.
Definition: BooleEnv.h:73
polybori::BooleEnv::block_idx_type
std::vector< idx_type > block_idx_type
Type for block indices.
Definition: BooleEnv.h:70
polybori::COrderEnums::ordercodes
ordercodes
Codes For orderings.
Definition: pbori_defs.h:154
BEGIN_NAMESPACE_PBORI
#define BEGIN_NAMESPACE_PBORI
Start project's namespace.
Definition: pbori_defs.h:74
polybori::COrderEnums
This struct contains type definitions and enumerations to be used for order codes.
Definition: pbori_defs.h:152
polybori::BooleEnv::vartext_type
CTypes::vartext_type vartext_type
Definition: BooleEnv.h:66
polybori::BoolePolyRing::var_type
class BooleVariable var_type
set variables type
Definition: BoolePolyRing.h:59
polybori::COrderingBase
Definition: COrderingBase.h:43
polybori::BoolePolyRing
This class reinterprets decicion diagram managers as Boolean polynomial rings, adds an ordering and v...
Definition: BoolePolyRing.h:40
polybori::CAuxTypes
This struct contains auxiliary type definitions.
Definition: pbori_defs.h:210
polybori::BooleEnv
This class is just a wrapper accessing global structures.
Definition: BooleEnv.h:46
polybori::BooleEnv::order_type
COrderingBase order_type
Definition: BooleEnv.h:103
pbori_defs.h
polybori::BoolePolyRing::dd_type
class BooleSet dd_type
set decision diagram type
Definition: BoolePolyRing.h:62
polybori::BooleEnv::dd_type
BoolePolyRing::dd_type dd_type
Definition: BooleEnv.h:64
polybori::block_end
BooleEnv::block_iterator block_end(const BooleEnv::ring_type &ring)
Extract block data without exposing ordering stuff.
Definition: BooleEnv.cc:145
polybori::BooleEnv::ordercode_type
CTypes::ordercode_type ordercode_type
Definition: BooleEnv.h:63
polybori::BooleEnv::var_type
BoolePolyRing::var_type var_type
Definition: BooleEnv.h:65
BoolePolyRing.h
polybori::CAuxTypes::vartext_type
const char * vartext_type
Type for setting/getting names of variables.
Definition: pbori_defs.h:249
polybori::CCompareEnums
This struct contains type definitions and enumerations to be used for comparisons.
Definition: pbori_defs.h:193
polybori::CAuxTypes::ordercode_type
int ordercode_type
Type for ordering codes.
Definition: pbori_defs.h:240
polybori::BooleEnv::base
CTypes::orderenums_type base
generic access to base type
Definition: BooleEnv.h:59