00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00031 #ifndef LATTICE_H
00032 #define LATTICE_H
00033
00034
00035
00036 #include "Evaluator.h"
00037 #include "BinaryMatrix.h"
00038
00046 class Lattice
00047 {
00048 public:
00050
00052 virtual ~Lattice()
00053 {
00054
00055 }
00056
00057 virtual void setBinaryMatrix(BinaryMatrix* bm) = 0;
00058 virtual void generateCandidates(unsigned int level) = 0;
00059 virtual void generateCandidates(unsigned int level, unsigned int k) = 0;
00060 virtual bool hasNextCandidate() const = 0;
00061 virtual Itemset* getNextCandidate() = 0;
00062 virtual void evaluateItemset(Itemset* is) = 0;
00063 virtual void flushEvaluationBuffer() = 0;
00064 virtual unsigned int getUpperBound() const = 0;
00065 virtual void setEvaluator(Evaluator* evaluator) = 0;
00066 virtual void setBufferSize(unsigned int bufferSize) = 0;
00067 virtual unsigned int analyzeLevel(unsigned int level) = 0;
00068 virtual unsigned int analyzeLevel(unsigned int level, double& status) =
00069 0;
00070 virtual unsigned int analyzeLevel(unsigned int level, unsigned int k) =
00071 0;
00072 virtual unsigned int analyzeLevel(unsigned int level, unsigned int k,
00073 double& status) = 0;
00074 virtual bool isEmpty(unsigned int level) const = 0;
00075 virtual unsigned int getSize() const = 0;
00076 virtual unsigned int getSize(unsigned int level) const = 0;
00077 virtual unsigned int getSuccessful(unsigned int level) const = 0;
00078 virtual const Itemset* getItemset(unsigned int level,
00079 unsigned int index) const = 0;
00080 virtual const Itemset* getItemset(unsigned int level,
00081 unsigned int index, unsigned int& upperBound) const = 0;
00082 virtual void generatePositiveBorder(unsigned int level) = 0;
00083 virtual bool hasNextPositiveBorder() const = 0;
00084 virtual const Itemset* getNextPositiveBorder() = 0;
00085 virtual void destroy() = 0;
00086 virtual unsigned int getWidth() const = 0;
00087 };
00088
00089 #endif