source: git/factory/cf_eval.h @ e4fe2b

jengelh-datetimespielwiese
Last change on this file since e4fe2b was e4fe2b, checked in by Oleksandr Motsak <motsak@…>, 11 years ago
FIX: Fixed huge BUG in cf_gmp.h CHG: starting to cleanup factory
  • Property mode set to 100644
File size: 1.3 KB
Line 
1/* emacs edit mode for this file is -*- C++ -*- */
2/* $Id$ */
3
4#ifndef INCL_CF_EVAL_H
5#define INCL_CF_EVAL_H
6
7// #include "config.h"
8
9#ifndef NOSTREAMIO
10#ifdef HAVE_IOSTREAM
11#include <iostream>
12#define OSTREAM std::ostream
13#elif defined(HAVE_IOSTREAM_H)
14#include <iostream.h>
15#define OSTREAM ostream
16#endif
17#endif /* NOSTREAMIO */
18
19#include "canonicalform.h"
20
21/*BEGINPUBLIC*/
22
23class Evaluation
24{
25protected:
26    CFArray values;
27public:
28    Evaluation() : values() {}
29    Evaluation( int min0, int max0 ) : values( min0, max0 ) {}
30    Evaluation( const Evaluation & e ) : values( e.values ) {}
31    virtual ~Evaluation() {}
32    Evaluation& operator= ( const Evaluation & e );
33    int min() const { return values.min(); }
34    int max() const { return values.max(); }
35    CanonicalForm operator[] ( int i ) const { return values[i]; }
36    CanonicalForm operator[] ( const Variable & v ) const { return operator[](v.level()); }
37    CanonicalForm operator() ( const CanonicalForm& f ) const;
38    CanonicalForm operator() ( const CanonicalForm & f, int i, int j ) const;
39    void setValue (int i, const CanonicalForm& f);
40    virtual void nextpoint();
41#ifndef NOSTREAMIO
42    friend OSTREAM& operator<< ( OSTREAM& s, const Evaluation &e );
43#endif /* NOSTREAMIO */
44};
45
46/*ENDPUBLIC*/
47
48#endif /* ! INCL_CF_EVAL_H */
Note: See TracBrowser for help on using the repository browser.