PolyBoRi
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
groebner
include
polybori
groebner
PolyEntryReference.h
Go to the documentation of this file.
1
// -*- c++ -*-
2
//*****************************************************************************
14
//*****************************************************************************
15
16
#ifndef polybori_groebner_PolyEntryReference_h_
17
#define polybori_groebner_PolyEntryReference_h_
18
19
// include basic definitions
20
#include "
groebner_defs.h
"
21
#include <set>
22
23
#include "
PolyEntryIndices.h
"
24
#include "
PolyEntry.h
"
25
26
BEGIN_NAMESPACE_PBORIGB
27
34
class
PolyEntryReference
{
35
typedef
PolyEntryReference
self
;
36
37
public
:
38
typedef
PolyEntryIndices
vector_type
;
39
typedef
PolyEntry
value_type
;
40
42
PolyEntryReference
(
value_type
&entry,
vector_type
& parent):
43
vPairCalculated(entry.vPairCalculated), minimal(entry.minimal),
44
m_entry(entry), m_parent(parent) { }
45
47
bool
operator==
(
const
self
& rhs)
const
{
return
m_entry == rhs; }
48
50
51
void
markVariablePairsCalculated
() {
52
return
m_entry.markVariablePairsCalculated(); }
53
54
bool
propagatableBy
(
const
PolyEntry
& other)
const
{
55
return
m_entry.propagatableBy(other);
56
}
57
58
std::set<idx_type>&
vPairCalculated
;
59
bool
&
minimal
;
61
63
template
<
class
Type>
64
self
&
operator=
(
const
Type& rhs) {
65
Monomial
lm(m_entry.lead);
66
m_entry = rhs;
67
m_parent.update(lm, m_entry);
68
return
*
this
;
69
}
70
72
const
value_type
&
get
()
const
{
return
const_cast<
const
value_type
&
>
(m_entry); }
73
75
operator
const
value_type
&()
const
{
return
get
(); }
76
77
private
:
78
value_type& m_entry;
79
vector_type& m_parent;
80
};
81
82
83
END_NAMESPACE_PBORIGB
84
85
#endif
/* polybori_groebner_PolyEntryReference_h_ */
Generated by
1.8.3.1