theory_datatype_lazy.h

Go to the documentation of this file.
00001 /*****************************************************************************/
00002 /*!
00003  *\file theory_datatype.h
00004  *
00005  * Author: Clark Barrett
00006  *
00007  * Created: Wed Dec  1 22:24:32 2004
00008  *
00009  * <hr>
00010  * Copyright (C) 2003 by the Board of Trustees of Leland Stanford
00011  * Junior University and by New York University. 
00012  *
00013  * License to use, copy, modify, sell and/or distribute this software
00014  * and its documentation for any purpose is hereby granted without
00015  * royalty, subject to the terms and conditions defined in the \ref
00016  * LICENSE file provided with this distribution.  In particular:
00017  *
00018  * - The above copyright notice and this permission notice must appear
00019  * in all copies of the software and related documentation.
00020  *
00021  * - THE SOFTWARE IS PROVIDED "AS-IS", WITHOUT ANY WARRANTIES,
00022  * EXPRESSED OR IMPLIED.  USE IT AT YOUR OWN RISK.
00023  * 
00024  * <hr>
00025  * 
00026  */
00027 /*****************************************************************************/
00028 
00029 #ifndef _cvcl__include__theory_datatype_lazy_h_
00030 #define _cvcl__include__theory_datatype_lazy_h_
00031 
00032 #include "theory.h"
00033 #include "smartcdo.h"
00034 #include "cdmap.h"
00035 #include "theory_datatype.h"
00036 
00037 namespace CVCL {
00038 
00039 /*****************************************************************************/
00040 /*!
00041  *\class TheoryDatatypeLazy
00042  *\ingroup Theories
00043  *\brief This theory handles datatypes.
00044  *
00045  * Author: Clark Barrett
00046  *
00047  * Created: Wed Dec  1 22:27:12 2004
00048  */
00049 /*****************************************************************************/
00050 class TheoryDatatypeLazy :public TheoryDatatype {
00051 
00052   typedef enum {
00053     MERGE1 = 0,
00054     MERGE2,
00055     ENQUEUE
00056   } ProcessKinds;
00057 
00058   CDList<Theorem> d_processQueue;
00059   CDList<ProcessKinds> d_processQueueKind;
00060   CDO<unsigned> d_processIndex;
00061   CDO<bool> d_typeComplete;
00062 
00063 private:
00064   void instantiate(const Expr& e, const bigunsigned& u);
00065   void initializeLabels(const Expr& e, const Type& t);
00066   void mergeLabels(const Theorem& thm, const Expr& e1, const Expr& e2);
00067   void mergeLabels(const Theorem& thm, const Expr& e,
00068                    unsigned position, bool positive);
00069 
00070 public:
00071   TheoryDatatypeLazy(TheoryCore* theoryCore);
00072   ~TheoryDatatypeLazy() {}
00073 
00074   // Theory interface
00075   void checkSat(bool fullEffort);
00076   void setup(const Expr& e);
00077   void update(const Theorem& e, const Expr& d);
00078 
00079 };
00080 
00081 }
00082 
00083 #endif

Generated on Thu Apr 13 16:57:35 2006 for CVC Lite by  doxygen 1.4.4