//!;;Rpy::+
//!;;Rpy::Model Element : RexExternalChannelFactory
//!;;Rpy::
//!;;Rpy::Component : RunTest 
//!;;Rpy::Configuration : HOST
//!;;Rpy::Project : Rex
//!;;Rpy::Generated Date : Wed, 20, Sep 2017  
//!;;Rpy::
//!;;Rpy::File Path : RexExternalChannelFactory.h
//!;;Rpy::Tag : $Tag
//!;;Rpy::
//!;;Rpy::Copyright : Selex ES - COMPANY CONFIDENTIAL
//!;;Rpy::
//!;;Rpy::Generated by Rhapsody	: 7.5.3 
//!;;Rpy::- 
//
// @Brief: $FileBrief



#ifndef RexExternalChannelFactory_H
#define RexExternalChannelFactory_H

//## dependency stdint
#include <stdint.h>
//## operation createChannel(RexExternalChannelId)
class RexExternalChannelId;

//## dependency RexIExternalChannel
class RexIExternalChannel;

//## package Rex::RexPackages::RexNetPkg

//## class RexExternalChannelFactory
class RexExternalChannelFactory
{
public :

    //#[ type mailbox_id_t
    typedef uint8_t mailbox_id_t;
    //#]
    
    //#[ type dbgchannel_id_t
    enum dbgchannel_id_t
    {
      dbg_video_channel
    };
    //#]
    
    ////    Constructors and destructors    ////
    
    //## auto_generated
    RexExternalChannelFactory();
    
    //## auto_generated
    ~RexExternalChannelFactory();
    
    ////    Operations    ////
    
    //## operation createChannel(RexExternalChannelId)
    static RexIExternalChannel& createChannel(const RexExternalChannelId& id);
    
    //## operation createDebugChannel(int)
    static RexIExternalChannel& createDebugChannel(int port);
    
    //## operation initialize()
    static void initialize();
    
    // Map a chennel to the transport layer mailbox from 0..255
    //  
    //## operation mapChannel(mailbox_id_t,RexExternalChannelId)
    void mapChannel(mailbox_id_t mailbox, const RexExternalChannelId& id);

    static void dispatcher(const void* data, unsigned int size);
};

#endif
//;;Rpy:: end
