SatBinomConsumer.cpp
Go to the documentation of this file.
/* Frobby: Software for monomial ideal computations.
Copyright (C) 2007 Bjarke Hammersholt Roune (www.broune.com)
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see http://www.gnu.org/licenses/.
*/
#include "stdinc.h"
#include "SatBinomConsumer.h"
#include "SatBinomIdeal.h"
SatBinomConsumer::~SatBinomConsumer() {
}
void SatBinomConsumer::beginConsuming(const VarNames& names) {
consumeRing(names);
beginConsuming();
}
void SatBinomConsumer::consume(const SatBinomIdeal& ideal) {
beginConsuming(ideal.getNames());
for (size_t binom = 0; binom < ideal.getGeneratorCount(); ++binom)
consume(ideal.getGenerator(binom));
doneConsuming();
}
SatBinomConsumer.h
SatBinomIdeal.h
SatBinomConsumer::consumeRing
virtual void consumeRing(const VarNames &names)=0
SatBinomConsumer::doneConsuming
virtual void doneConsuming()=0
SatBinomConsumer::beginConsuming
virtual void beginConsuming()=0
SatBinomConsumer::~SatBinomConsumer
virtual ~SatBinomConsumer()
Definition SatBinomConsumer.cpp:22
SatBinomConsumer::consume
virtual void consume(const vector< mpz_class > &term)=0
SatBinomIdeal
Represents a saturated binomial ideal.
Definition SatBinomIdeal.h:28
SatBinomIdeal::getGeneratorCount
size_t getGeneratorCount() const
Definition SatBinomIdeal.cpp:45
SatBinomIdeal::getNames
const VarNames & getNames() const
Definition SatBinomIdeal.cpp:82
SatBinomIdeal::getGenerator
const vector< mpz_class > & getGenerator(size_t index) const
Definition SatBinomIdeal.cpp:39
VarNames
Defines the variables of a polynomial ring and facilities IO involving them.
Definition VarNames.h:40
stdinc.h
This header file includes common definitions and is included as the first line of code in every imple...