- Main Page
- Namespaces
- Classes
- Files
- Related Pages

# /Users/fpy/titan-1-5-MBARI/Mers/Reconfiguration/Discrete/mrInterface.h

    00001 //==============================================================================
    00002 //
    00003 // Copyright (c) 2001           Model-based Embedded and Robotic Systems Group
    00004 // All Rights Reserved          Massachusetts Institute of Technology
    00005 //
    00006 // This software is provided as is. Model-based Embedded and Robotic Systems
    00007 // (MERS) group does not assume any responsibility.
    00008 //
    00009 // Author:                      Seung H. Chung
    00010 // Organization:        Model-based Embedded and Robotic Systems Group
    00011 //                                      Massachusetts Institute of Technology
    00012 //
    00013 // class mrInterface
    00014 //
    00015 //==============================================================================
    00016 #ifndef __MR_INTERFACE__
    00017 #define __MR_INTERFACE__
    00018
    00019 #ifdef _MSC_VER
    00020 #pragma warning( disable : 4786 )
    00021 #endif
    00022
    00023 #include <iostream>
    00024 #include <list>
    00025
    00026 #include <Mers/Utils/Lang/String.h>
    00027 #include <Mers/Utils/Containers/intList.h>
    00028 #include <Mers/Reconfiguration/Discrete/MR_connection.h>
    00029 #include "modeReconfiguration.h"
    00030 //#include <Mers/Planning/Reactive/CCA/reactivePlanner.h>
    00031 //#include "../ModeReconfiguration/MRPrime/MRPrime.h"
    00032
    00033 //class intList;
    00034 //class rpCCAutomata;
    00035
    00036 class mrInterface : public Mers::Reconfiguration::Discrete::MR_connection
    00037 {
    00038 public:
    00039         //--------------------------------------------------------------------------
    00040         // Constructors, Copy Constructors, & Destructors
    00041         //--------------------------------------------------------------------------
    00042
    00047         mrInterface(modeReconfiguration &mr);
    00048
    00052         ~mrInterface();
    00053
    00054         //--------------------------------------------------------------------------
    00055         // Public Function Members
    00056         //--------------------------------------------------------------------------
    00057
    00064         void                        update_current_state(unsigned int variable_id,
    00065                                                          unsigned int value_id)  const;
    00066
    00073         void                        update_current_state(Mers::Utils::Lang::String variable_name,
    00074                                                          Mers::Utils::Lang::String value_name)  const;
    00075
    00081         Mers::Utils::Containers::intList                     generate_commands(Mers::Utils::Containers::intList &goal_intList);
    00082
    00088         std::list<Mers::Utils::Lang::String>                generate_commands(std::list<Mers::Utils::Lang::String> const &goal_list);
    00089
    00094         Mers::Utils::Containers::intList                                                generate_reachable_states();
    00095
    00100         void                        setDebug(bool debugState);
    00101
    00106         bool                        getDebug()  const;
    00107
    00108         void                        showVariables()  const;
    00109
    00110         //--------------------------------------------------------------------------
    00111         // Public Operators
    00112         //--------------------------------------------------------------------------
    00113
    00114         friend std::ostream &       operator <<(std::ostream &_ostream,
    00115                                                 mrInterface const &_mrInterface);
    00116
    00117 private:
    00118
    00119         modeReconfiguration *           _modeReconfiguration_p;
    00120         bool                        debug;
    00121
    00122 };
    00123
    00124 #endif
    00125