/*
 * $Id: Entity_test_map.cpp 94 2008-12-15 11:04:03Z rosiere $
 *
 * [ Description ]
 * 
 */

#include "Behavioural/include/Entity.h"
#include "Common/include/Tabulation.h"
#include <iostream>

namespace morpheo              {
namespace behavioural          {

#undef  FUNCTION
#define FUNCTION "Entity::test_map"
  bool Entity::test_map (uint32_t depth, bool top_level, bool is_behavioural)
  {
    log_printf(FUNC,Behavioural,FUNCTION,"Begin");
  
    std::string tab=morpheo::tab(depth);

    log_printf(INFO,Interface,FUNCTION,"%s* Entity \"%s\"",tab.c_str(),_name.c_str());
  
    bool _return = _interfaces->test_map(depth+1,top_level, is_behavioural);

#ifndef DEBUG
    if (_return == false)
      {
	std::cerr << "In entity \"" << _name << "\" (type : \"" << _type << "\"), a lot of port is not connected !" << std::endl;
      }
#endif

    log_printf(FUNC,Behavioural,FUNCTION,"End");
    
    return _return;
  };

// #undef  FUNCTION
// #define FUNCTION "Entity::test_equi"
//   bool Entity::test_equi (uint32_t depth)
//   {
//     log_printf(FUNC,Behavioural,FUNCTION,"Begin");
  
//     std::string tab  = tab(depth);
//     log_printf(INFO,Behavioural,FUNCTION, "%s* Entity \"%s\"",tab.c_str(),_name.c_str());
  
//     bool _return = _interfaces->test_equi(depth+1);

// #ifndef DEBUG
//     if (_return == false)
//       {
// 	std::cerr << "In entity \"" << _name << "\" (type : \"" << _type << "\"), a lot of port is not connected !" << std::endl;
//       }
// #endif

//     log_printf(FUNC,Behavioural,FUNCTION,"End");
    
//     return _return;
//   };

}; // end namespace behavioural          
}; // end namespace morpheo              
