00001 /** 00002 * @file Platform/Aperios1.3.2/IPEndpoint.h 00003 * 00004 * @author <A href=mailto:robocup@m-wachter.de>Michael Wachter</A> 00005 */ 00006 00007 #ifndef _IPEndpoint_H_ 00008 #define _IPEndpoint_H_ 00009 00010 /** 00011 * static class for system calls 00012 * @attention the implementation is system specific! 00013 */ 00014 00015 #include <ant.h> 00016 #include <EndpointTypes.h> 00017 #include <IPAddress.h> 00018 #include "ProcessFramework.h" 00019 00020 class IPEndpoint 00021 { 00022 00023 public: 00024 IPEndpoint(int sbs = 16384, int rbs = 16384); 00025 ~IPEndpoint(); 00026 virtual void listenCont(antEnvMsg* msg) {}; 00027 virtual void sendCont(antEnvMsg* msg) {}; 00028 virtual void receiveCont(antEnvMsg* msg) {}; 00029 virtual void closeCont(antEnvMsg* msg) {}; 00030 virtual void connectCont(antEnvMsg* msg){}; 00031 00032 00033 protected: 00034 antModuleRef endpoint; /*< ANT Library Endpoint */ 00035 00036 antSharedBuffer sendBuffer; /*< ANT buffer for sending */ 00037 byte* sharedSendBuffer; /*< Pointer to the data */ 00038 int sharedSendBufferSize; 00039 int sharedReceiveBufferSize; 00040 00041 00042 antSharedBuffer receiveBuffer;/*< ANT buffer for receiving */ 00043 byte* sharedReceiveBuffer; /*< Data received */ 00044 00045 /* Pointers to the entry-point selectors in the process-framework 00046 * Need to be pointers because an IPEndpoint can be created before 00047 * the entry-points are created 00048 */ 00049 00050 int* listenContSelector; 00051 int* sendContSelector; 00052 int* receiveContSelector; 00053 int* closeContSelector; 00054 int* connectContSelector; 00055 00056 /* 00057 * Stack-Ref 00058 */ 00059 00060 antStackRef ipStackRef; 00061 OID* myOID_; 00062 00063 00064 00065 00066 }; 00067 00068 Out& operator<<(Out& stream, const IPAddress& ipAddress); 00069 00070 #endif // _IPEndpoint_H_
1.3.6