diff options
author | fcolin | 2007-02-01 12:56:26 +0000 |
---|---|---|
committer | fcolin | 2007-02-01 12:56:26 +0000 |
commit | 1a6db4ddfa3ab1868b8e76bec6c62a6528de2832 (patch) | |
tree | ed7db31f661b9a404cf90ee38caf60060eccd468 /Bus/Ivy/Ivy.cxx | |
parent | 9cc867ca9b6d5d05f51d4f736d511ca99da268e3 (diff) | |
download | ivy-cplusplus-1a6db4ddfa3ab1868b8e76bec6c62a6528de2832.zip ivy-cplusplus-1a6db4ddfa3ab1868b8e76bec6c62a6528de2832.tar.gz ivy-cplusplus-1a6db4ddfa3ab1868b8e76bec6c62a6528de2832.tar.bz2 ivy-cplusplus-1a6db4ddfa3ab1868b8e76bec6c62a6528de2832.tar.xz |
Utilisateur : Fcolin Date : 1/06/06 Heure : 10:14 Archivé dans $/Bus/Ivy Commentaire: ajout Binding Callback et SetFilter (vss 25)
Diffstat (limited to 'Bus/Ivy/Ivy.cxx')
-rw-r--r-- | Bus/Ivy/Ivy.cxx | 30 |
1 files changed, 28 insertions, 2 deletions
diff --git a/Bus/Ivy/Ivy.cxx b/Bus/Ivy/Ivy.cxx index 66c1715..2da3766 100644 --- a/Bus/Ivy/Ivy.cxx +++ b/Bus/Ivy/Ivy.cxx @@ -64,6 +64,7 @@ Ivy::Ivy(const char* name, const char * ready, IvyApplicationCallback *callback, ApplicationName = name;
messages_classes_count = 0;
messages_classes = NULL;
+ binding_callback = NULL;
application_callback = synchronous ? new IvySynchronousApplicationCallback(callback) : callback;
direct_callback = NULL;
die_callback = NULL;
@@ -337,6 +338,27 @@ void Ivy::CallApplicationDisconnectedCallback(IvyApplication * app) application_callback->OnApplicationDisconnected( app );
}
}
+void Ivy::CallBindingAddCallback(IvyApplication * app, int id, const char * regexp)
+{
+ if ( binding_callback )
+ {
+ binding_callback->OnAddBind( app, id, regexp );
+ }
+}
+void Ivy::CallBindingRemoveCallback(IvyApplication * app, int id, const char * regexp)
+{
+ if ( binding_callback )
+ {
+ binding_callback->OnRemoveBind( app, id, regexp );
+ }
+}
+void Ivy::CallBindingFilterCallback(IvyApplication * app, int id, const char * regexp)
+{
+ if ( binding_callback )
+ {
+ binding_callback->OnFilterBind( app, id, regexp );
+ }
+}
void Ivy::SendDirectMsg(IvyApplication * app, int id, const char *message)
{
app->SendMsg( IvyApplication::DirectMsg, id, message );
@@ -358,8 +380,12 @@ bool Ivy::CheckRegexp(const char * exp) }
return regexp_ok;
}
-
-void Ivy::Classes(int argc, const char **argv )
+void Ivy::SetBindCallback( IvyBindingCallback* bind_callback )
+{
+ binding_callback = synchronous ? new IvySynchronousBindingCallback(bind_callback) : bind_callback;
+}
+
+void Ivy::SetFilter(int argc, const char **argv )
{
messages_classes_count = argc;
messages_classes = argv;
|