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

V2States.h

Go to the documentation of this file.
00001 /*
00002  * Copyright (C) 2000 KOM/Darmstadt University of Technology
00003  *
00004  * This program is free software; you can redistribute it and/or modify it
00005  * under the terms of the GNU General Public License as published by the
00006  * Free Software Foundation; either version 2, or (at your option) any
00007  * later version.
00008  *
00009  * This program is distributed in the hope that it will be useful,
00010  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00011  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00012  * GNU General Public License for more details.
00013  *
00014  * You should have received a copy of the GNU General Public License
00015  * along with this program; if not, write to the Free Software
00016  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
00017  * USA.
00018  */
00019 #ifndef V2_STATES_H
00020 #define V2_STATES_H
00021 
00022 #include "V1States.h"
00023 #include "MNString.h"
00024 #include "MNArray.h"
00025 
00026 class V1Transition;
00027 
00028 class V2StateVector;
00029 class V2PartialState;
00030 class V2StateOther;
00031 class V2StateKeep;
00032 
00033 /***********************************************************************
00034  * V2StateVector
00035  ***********************************************************************/
00036 
00037 class V2StateVector
00038 {
00039     typedef V2PartialState* V2PartialStatePtr;
00040 
00041     V2PartialState** _vector;
00042     int              _dimension;
00043     V1Transition*    _transition;
00044     int              _first_line;
00045 
00046 public:
00047     enum Mode { Name, Index };
00048 
00049 public:
00050     V2StateVector( int dimension, int first_line, V1Transition* trans );
00051     // V2StateVector( int dimension, int* v, int first_line, Mode m = Name );
00052     V2StateVector( int dimension, int* v, int first_line, Mode m );
00053     V2StateVector( V2StateVector& orig );
00054     ~V2StateVector( );
00055 
00056     void          set( int dim, V2PartialState* s );
00057     int*          getIndexVector();
00058     int*          getIndexVectorWithSignals();
00059     V1Transition* getTransition( );
00060 
00061     bool keep();
00062     bool generic();
00063 
00064     MNString asIndexVector( );
00065     MNString asNameVector( );
00066     MNString asSymbolicName( );
00067     MNString asNextstateParameters( );
00068 
00069     int getFirstLine( );
00070 
00071     // void addTransition( V1Transition* t );
00072 };
00073 
00074 /***********************************************************************
00075  * V2PartialState
00076  ***********************************************************************/
00077 
00078 class V2PartialState
00079 {
00080     int           _dimension;
00081     int           _name;
00082     int           _ps_index;
00083 
00084 public:
00085     enum Mode { Name, Index };
00086 
00087 public:
00088     V2PartialState( int dimension );
00089     V2PartialState( int dimension, int name, Mode mode = Name );
00090     V2PartialState( int dimension, V1PartialState& orig );
00091     virtual ~V2PartialState( ) { }
00092 
00093     virtual MNString getString();
00094     virtual int      getName();
00095     virtual int      getIndex();
00096 
00097     virtual bool keep();
00098     virtual bool generic();
00099 };
00100 
00101 /***********************************************************************
00102  * V2StateOther
00103  ***********************************************************************/
00104 
00105 class V2StateOther : public V2PartialState
00106 {
00107 public:
00108     V2StateOther( int dimension );
00109     virtual ~V2StateOther() { }
00110 
00111     virtual MNString getString();
00112     virtual int      getName();
00113     virtual int      getIndex();
00114 
00115     virtual bool generic();
00116 };
00117 
00118 /***********************************************************************
00119  * V2StateKeep
00120  ***********************************************************************/
00121 
00122 class V2StateKeep : public V2PartialState
00123 {
00124 public:
00125     V2StateKeep( int dimension );
00126     virtual ~V2StateKeep() { }
00127 
00128     virtual MNString getString();
00129     virtual int      getName();
00130     virtual int      getIndex();
00131 
00132     virtual bool keep();
00133 };
00134 
00135 #endif /* V2_STATES_H */
00136 

Generated on Sat Mar 23 18:58:40 2002 for Komssys-mkauto by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002