Main Page   Class Hierarchy   Compound List   File List   Compound Members   File Members  

/magnus/back_end/SessionManager/include/MIC.h

Go to the documentation of this file.
00001 /*
00002  *   $Id: MIC.h,v 1.4 2000/03/03 01:35:11 bormotov Exp $
00003  */
00004 
00005 // Copyright (C) 1996 The New York Group Theory Cooperative
00006 // See magnus/doc/COPYRIGHT for the full notice.
00007 //
00008 // Contents: Declaration of class MIC (Map Information Center)
00009 //
00010 // Principal Author: Dmitry Bormotov
00011 //
00012 // Status: in progress
00013 //
00014 // Usage:
00015 //
00016 // For a given piece of info, there are up to four kinds of names needed:
00017 // 1) The data member
00018 // 2) The member function through which it is reported
00019 // 3) The member function via which its existence is queried
00020 // 4) The member function via which it is accessed
00021 // 
00022 // In an attempt at coherence, we try to use these conventions for a
00023 // Trichotomy (resp. bool) <I>
00024 // e.g., I == abelian, (resp. I == solvedWordProblem):
00025 // 
00026 // 1) <I>
00027 // 2) putIs<I>  resp. putHave<I>
00028 // 3) is<I>     resp. have<I>
00029 // 
00030 // and in other cases (e.g., I == confluentKBMachine):
00031 // 
00032 // 1) <I>
00033 // 2) putHave<I>
00034 // 3) have<I>
00035 // 4) get<I>
00036 //
00037 // Revision History:
00038 //
00039 
00040 
00041 #ifndef _MIC_H_
00042 #define _MIC_H_
00043 
00044 #include "Trichotomy.h"
00045 #include "Chars.h"
00046 #include "FEData.h"
00047 #include "InformationCenter.h"
00048 
00049 // Types stored by the MIC:
00050 
00051 class HomIsMonoProperty : public NoDataProperty {
00052 public:
00053   HomIsMonoProperty( ) : NoDataProperty() {}
00054   PropertyType actualType()   const { return type(); }
00055   static PropertyType type() { return theTypeID; }
00056   Chars propertyName() const { return "HomIsMono"; }
00057 protected:
00058   GenericProperty* clone() const { return new HomIsMonoProperty(*this); }
00059 private:
00060   static const PropertyType theTypeID;
00061 };
00062 
00063 class HomIsEpiProperty : public NoDataProperty {
00064 public:
00065   HomIsEpiProperty( ) : NoDataProperty() {}
00066   PropertyType actualType()   const { return type(); }
00067   static PropertyType type() { return theTypeID; }
00068   Chars propertyName() const { return "HomIsEpi"; }
00069 protected:
00070   GenericProperty* clone() const { return new HomIsEpiProperty(*this); }
00071 private:
00072   static const PropertyType theTypeID;
00073 };
00074 
00075 class ExtendToHomProperty : public NoDataProperty {
00076 public:
00077   ExtendToHomProperty( const Chars& descr ) : NoDataProperty(descr) {}
00078   PropertyType actualType()   const { return type(); }
00079   static PropertyType type() { return theTypeID; }
00080   Chars propertyName() const { return "ExtendToHom"; }
00081 protected:
00082   GenericProperty* clone() const { return new ExtendToHomProperty(*this); }
00083 private:
00084   static const PropertyType theTypeID;
00085 };
00086 
00087 //-------------------------------- MIC --------------------------------------//
00088 
00089 
00090 class MIC : public InformationCenter, protected FEData
00091 {  
00092 public:
00093   
00094   /////////////////////////////////////////////////////////////////////////
00095   //                                                                     //
00096   // Constructors:                                                       //
00097   //                                                                     //
00098   /////////////////////////////////////////////////////////////////////////
00099   
00100   MIC( OID map_oid );
00101 
00102   ~MIC( );
00103 
00104 
00105   /////////////////////////////////////////////////////////////////////////
00106   //                                                                     //
00107   // Extend to Homomorphism:                                             //
00108   //                                                                     //
00109   /////////////////////////////////////////////////////////////////////////
00110 
00111   void putDoesExtendToHom( bool doesExtend = true, Chars explanation = "" );
00112   
00113   Trichotomy doesExtendToHom( ) const;
00114 
00115   Chars getExtendToHomExplanation( ) const;
00116 
00117   Chars getExtendToHomMessage( ) const;
00118 
00119   void putIsMono(bool ismono);
00120   void putIsEpi(bool isepi);
00121 
00122   Trichotomy isMono() const;
00123   Trichotomy isEpi() const;
00124 
00125   /////////////////////////////////////////////////////////////////////////
00126   //                                                                     //
00127   // Data Members:                                                       //
00128   //                                                                     //
00129   /////////////////////////////////////////////////////////////////////////
00130 
00131   OID mapOID;
00132   // Need this for composing messages about what has been found.
00133   
00134   //Trichotomy extendToHom;
00135   //Chars extendToHomExplanation;
00136   //Chars extendToHomMessage;
00137 private:
00138   //Trichotomy homIsMono;
00139   //Trichotomy homIsEpi;
00140 };
00141 
00142 #endif

Generated at Tue Jun 19 09:49:38 2001 for Magnus Classes by doxygen1.2.6 written by Dimitri van Heesch, © 1997-2001