/*  -*- mode: c++; c-basic-offset: 4; -*-
 *
 *  MICO --- a free CORBA implementation
 *  Copyright (C) 1999 Andreas Schultz
 *
 *  This library is free software; you can redistribute it and/or
 *  modify it under the terms of the GNU Library General Public
 *  License as published by the Free Software Foundation; either
 *  version 2 of the License, or (at your option) any later version.
 *
 *  This library is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 *  Library General Public License for more details.
 *
 *  You should have received a copy of the GNU Library General Public
 *  License along with this library; if not, write to the Free
 *  Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 *
 *  Send comments and/or bug reports to:
 *                 mico@informatik.uni-frankfurt.de      
 *
 */

#define MICO_CONF_IMR

#include <CORBA-SMALL.h>
#include <mico/impl.h>

/********************* MICO::PriorityModelPolicy_impl *******************************/ 

MICO::PriorityModelPolicy_impl::PriorityModelPolicy_impl ( RT_CORBA::PriorityModel _pm,
							   RT_CORBA::Priority      _sp )
    : MICO_SCOPE(MICO,Policy_impl) (RT_CORBA::PRIORITY_MODEL_POLICY_TYPE)
{
    pm = _pm;
    sp = _sp;
}

MICO::PriorityModelPolicy_impl::~PriorityModelPolicy_impl ()
{
}
  
CORBA::Policy_ptr
MICO::PriorityModelPolicy_impl::copy ()
{
    MICO::PriorityModelPolicy_impl *p = new MICO::PriorityModelPolicy_impl(pm, sp);
    return p;
}

RT_CORBA::PriorityModel 
MICO::PriorityModelPolicy_impl::priority_model()
{
    return pm;
}

RT_CORBA::Priority 
MICO::PriorityModelPolicy_impl::server_priority()
{
    return sp;
}

/********************* MICO::ThreadpoolPolicy_impl *******************************/ 

MICO::ThreadpoolPolicy_impl::ThreadpoolPolicy_impl ( RT_CORBA::ThreadpoolId tp )
    : MICO_SCOPE(MICO,Policy_impl) (RT_CORBA::THREADPOOL_POLICY_TYPE)
{
    _tp = tp;
}

MICO::ThreadpoolPolicy_impl::~ThreadpoolPolicy_impl ()
{
}
  
CORBA::Policy_ptr
MICO::ThreadpoolPolicy_impl::copy ()
{
    MICO::ThreadpoolPolicy_impl *p = new MICO::ThreadpoolPolicy_impl(_tp);
    return p;
}

RT_CORBA::ThreadpoolId
MICO::ThreadpoolPolicy_impl::threadpool()
{
    return _tp;
}

/********************* MICO::RTCurrent_impl *************************************/ 

MICO::RTCurrent_impl::RTCurrent_impl( MICOMT::Thread *_thr )
{
    thr = _thr;
}

MICO::RTCurrent_impl::~RTCurrent_impl() {}

RT_CORBA::Priority
MICO::RTCurrent_impl::the_priority()
{
    return 0;
}

void
MICO::RTCurrent_impl::the_priority( RT_CORBA::Priority value )
{
}
