diff options
author | fcolin | 2007-02-01 13:00:37 +0000 |
---|---|---|
committer | fcolin | 2007-02-01 13:00:37 +0000 |
commit | 500e25c685a49ff50e486a23f2171cd1b737f140 (patch) | |
tree | 4a9e6acb11479aeaf19b891b345ce677526376e1 /Ivy/IvyApplication.h | |
parent | 27cc7f3435b1561d686aa214c5083aa2a41b39f1 (diff) | |
download | ivy-cplusplus-500e25c685a49ff50e486a23f2171cd1b737f140.zip ivy-cplusplus-500e25c685a49ff50e486a23f2171cd1b737f140.tar.gz ivy-cplusplus-500e25c685a49ff50e486a23f2171cd1b737f140.tar.bz2 ivy-cplusplus-500e25c685a49ff50e486a23f2171cd1b737f140.tar.xz |
Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1)
Diffstat (limited to 'Ivy/IvyApplication.h')
-rw-r--r-- | Ivy/IvyApplication.h | 80 |
1 files changed, 80 insertions, 0 deletions
diff --git a/Ivy/IvyApplication.h b/Ivy/IvyApplication.h new file mode 100644 index 0000000..8884735 --- /dev/null +++ b/Ivy/IvyApplication.h @@ -0,0 +1,80 @@ +#if !defined(AFX_BUSAPPLICATION_H__F7F08FE8_E653_11D0_AE3E_080009F92591__INCLUDED_)
+#define AFX_BUSAPPLICATION_H__F7F08FE8_E653_11D0_AE3E_080009F92591__INCLUDED_
+
+#if _MSC_VER >= 1000
+#pragma once
+#endif // _MSC_VER >= 1000
+// IvyApplication.h : header file
+//
+#include "BufferedSocket.h"
+#include "Ivy.h"
+
+class Regexp;
+
+/////////////////////////////////////////////////////////////////////////////
+// IvyApplication command target
+
+class IvyApplication : public CBufferedSocket
+{
+// Attributes
+public:
+
+
+ typedef enum {
+
+ Bye, /* quit l'application ( non utilise ) */
+ AddRegexp, /* expression reguliere d'un client */
+ Msg, /* message reel */
+ Error, /* error message */
+ DelRegexp, /* Remove expression reguliere */
+ EndRegexp, /* end of the regexp list */
+ StartRegexp, /* debut des expressions */
+ DirectMsg, /* message direct a destination de l'appli */
+ Die /* demande de terminaison de l'appli */
+
+ }MsgType;
+
+
+// Operations
+public:
+ IvyApplication(Ivy *bus);
+ virtual ~IvyApplication();
+
+// Overrides
+public:
+ BOOL SameApplication( IvyApplication *app );
+ UINT remoteService;
+ const char *GetName(void);
+ int SendMsg( const char *message );
+ void SendMsg( MsgType msg, int id, const char * arg = NULL);
+ UINT Create();
+ void OnReceive( char *line );
+ void Create( const char * host, UINT &port );
+ // ClassWizard generated virtual function overrides
+ //{{AFX_VIRTUAL(IvyApplication)
+ public:
+ virtual void OnAccept(int nErrorCode);
+ virtual void OnClose(int nErrorCode);
+ //}}AFX_VIRTUAL
+
+ // Generated message map functions
+ //{{AFX_MSG(IvyApplication)
+ // NOTE - the ClassWizard will add and remove member functions here.
+ //}}AFX_MSG
+
+// Implementation
+protected:
+ string appname;
+ bool AppConnectedCallbackCalled;
+ Ivy *bus;
+ /* liste des souscriptions remote */
+ vector<Regexp*> regexp_in;
+
+};
+
+/////////////////////////////////////////////////////////////////////////////
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Developer Studio will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_BUSAPPLICATION_H__F7F08FE8_E653_11D0_AE3E_080009F92591__INCLUDED_)
|