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

#include "Behavioural/Generic/RegisterFile/include/Parameters.h"

namespace morpheo {
namespace behavioural {
namespace generic {
namespace registerfile {


  Parameters::Parameters (morpheo::behavioural::generic::registerfile::registerfile_monolithic  ::Parameters * param) :
    _instance          (instance_RegisterFile_Monolithic),
    _nb_port_read      (param->_nb_port_read ),
    _nb_port_write     (param->_nb_port_write),
    _nb_word           (param->_nb_word      ), 
    _size_word         (param->_size_word    ), 
    _size_address      (param->_size_address ),
    _have_port_address (param->_have_port_address)
  {
    log_printf(FUNC,RegisterFile,"Parameters","Begin");

    _param_registerfile_monolithic   = param;
    
    test();

    log_printf(FUNC,RegisterFile,"Parameters","End");
  };

  Parameters::Parameters (morpheo::behavioural::generic::registerfile::registerfile_multi_banked::Parameters * param) :
    _instance (instance_RegisterFile_Multi_Banked),
    _nb_port_read      (param->_nb_port_read ),
    _nb_port_write     (param->_nb_port_write),
    _nb_word           (param->_nb_word      ), 
    _size_word         (param->_size_word    ), 
    _size_address      (param->_size_address ),
    _have_port_address (param->_have_port_address)
  {
    log_printf(FUNC,RegisterFile,"Parameters","Begin");

    _param_registerfile_multi_banked = param;

    test();

    log_printf(FUNC,RegisterFile,"Parameters","End");
  };
  
  Parameters::Parameters (Parameters & param):
    _instance          (param._instance     ),
    _nb_port_read      (param._nb_port_read ),
    _nb_port_write     (param._nb_port_write),
    _nb_word           (param._nb_word      ), 
    _size_word         (param._size_word    ), 
    _size_address      (param._size_address ),
    _have_port_address (param._have_port_address)
  {
    log_printf(FUNC,RegisterFile,"Parameters (copy)","Begin");

    _param_registerfile_multi_banked = param._param_registerfile_multi_banked;
    _param_registerfile_monolithic   = param._param_registerfile_monolithic;
    test();
    log_printf(FUNC,RegisterFile,"Parameters (copy)","End");
  };

  Parameters::~Parameters () 
  {
    log_printf(FUNC,RegisterFile,"~Parameters","Begin");
    log_printf(FUNC,RegisterFile,"~Parameters","End");
  };

}; // end namespace registerfile
}; // end namespace generic

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