00001 
00002 
00003 
00004 
00005 
00006 
00007 
00008 
00009 
00010 
00011 
00012 
00013 
00014 
00015 
00016 
00017 
00018 
00019 
00020 #ifndef _C_TCAPSTACK_
00021 #define _C_TCAPSTACK_
00022 
00023 #include "C_TransportEvent.hpp"
00024 #include "C_ProtocolExternalFrame.hpp"
00025 #include "ReceiveMsgContext.h"
00026 #include "T_ConfigValue.h"
00027 #include "C_Transport.hpp"
00028 
00029 #include "select_t.hpp"
00030 #include "dlfcn_t.hpp"
00031 #include "list_t.hpp"
00032 
00033 
00034 class C_TcapStack {
00035 public:
00036            C_TcapStack(char *P_library_name);
00037   virtual ~C_TcapStack();
00038   virtual int init (T_logFunction P_logError, T_logFunction P_logInfo) = 0 ;
00039   virtual int config (T_pConfigValueList P_config_param_list) = 0 ;
00040   virtual int open (int P_channel_id, char *P_class, 
00041                     int P_appl, int P_inst, int P_ossn,
00042                     C_ProtocolExternalFrame *P_protocol) = 0 ;
00043   virtual int close (int P_cnx) = 0 ;
00044 
00045   virtual int pre_select  (int                P_n, 
00046                            fd_set            *P_readfds,  
00047                            fd_set            *P_writefds,
00048                            fd_set            *P_exceptfds, 
00049                            struct timeval    *P_timeout) = 0 ; 
00050 
00051   virtual int post_select (int                  P_n, 
00052                            fd_set              *P_readfds,  
00053                            fd_set              *P_writefds,
00054                            fd_set              *P_exceptfds, 
00055                            T_pC_TransportEvent  P_eventTable,
00056                            size_t              *P_nb) = 0 ;
00057 
00058   virtual bool get_message (int P_id, T_pReceiveMsgContext P_ctxt) = 0 ;
00059   virtual int  send_message(int P_id, C_MessageFrame *P_msg) = 0 ;
00060 
00061 
00062 protected:
00063   char *m_library_name ;
00064 private:
00065 } ;
00066 
00067 #endif // _C_TCAPSTACK_
00068 
00069 
00070 
00071 
00072 
00073 
00074