/*
 * $Id$
 *
 * [ Description ]
 * 
 */

#include "Behavioural/include/Interfaces.h"

namespace morpheo              {
namespace behavioural          {

  Interfaces::Interfaces  (void)
  {
    log_printf(FUNC,Behavioural,"Interfaces","Begin");
    _list_interface = new list<Interface*>;
    log_printf(FUNC,Behavioural,"Interfaces","End");
  };

  Interfaces::Interfaces  (const Interfaces & interfaces)
  {
    log_printf(FUNC,Behavioural,"Interfaces (copy)","Begin");
    _list_interface = interfaces._list_interface;
    log_printf(FUNC,Behavioural,"Interfaces (copy)","End");
  };
  
  Interfaces::~Interfaces ()
  {
    log_printf(FUNC,Behavioural,"~Interfaces","Begin");

    if (_list_interface->empty()== false)
      {
	list<Interface*>::iterator i     = _list_interface->begin();

	while (i != _list_interface->end())
	  {
	    delete (*i);
	    ++i;
	  }
      }

    delete _list_interface;
    log_printf(FUNC,Behavioural,"~Interfaces","End");
  };
  
}; // end namespace behavioural          
}; // end namespace morpheo              
