summaryrefslogtreecommitdiff
path: root/IvyPPC/IvyEventArgs.cs
diff options
context:
space:
mode:
authorfcolin2007-02-01 12:05:47 +0000
committerfcolin2007-02-01 12:05:47 +0000
commit3593a483d5566779f1d56e037615685cdc77c0a0 (patch)
tree300986bb2f463148fd0773efc5f69654ae2cd53f /IvyPPC/IvyEventArgs.cs
parent3ce9b3f180e3f52c7be79e0a23bbd1a0b5120ac6 (diff)
downloadivy-csharp-3593a483d5566779f1d56e037615685cdc77c0a0.zip
ivy-csharp-3593a483d5566779f1d56e037615685cdc77c0a0.tar.gz
ivy-csharp-3593a483d5566779f1d56e037615685cdc77c0a0.tar.bz2
ivy-csharp-3593a483d5566779f1d56e037615685cdc77c0a0.tar.xz
modification structure svn
Diffstat (limited to 'IvyPPC/IvyEventArgs.cs')
-rw-r--r--IvyPPC/IvyEventArgs.cs84
1 files changed, 84 insertions, 0 deletions
diff --git a/IvyPPC/IvyEventArgs.cs b/IvyPPC/IvyEventArgs.cs
new file mode 100644
index 0000000..e394802
--- /dev/null
+++ b/IvyPPC/IvyEventArgs.cs
@@ -0,0 +1,84 @@
+using System;
+using System.Collections.Generic;
+using System.Text;
+
+namespace IvyBus
+{
+ /// <summary> The EventArgs Classes
+ /// </summary>
+ ///
+ public class IvyEventArgs : EventArgs
+ {
+ private IvyClient client;
+ private int id;
+ private string arg;
+
+ public IvyClient Client
+ {
+ get { return client; }
+ }
+
+ public int Id
+ {
+ get { return id; }
+ }
+
+ public string Argument
+ {
+ get { return arg; }
+ }
+ public IvyEventArgs(IvyClient app, int id, string arg)
+ {
+ this.client = app;
+ this.id = id;
+ this.arg = arg;
+ }
+ }
+ public class IvyDieEventArgs : IvyEventArgs
+ {
+ /* return value for Die Event */
+ private bool forceExit;
+
+ public bool ForceExit
+ {
+ get { return forceExit; }
+ set { forceExit = value; }
+ }
+ public IvyDieEventArgs(IvyClient app, int id, string arg)
+ : base(app, id, arg)
+ {
+ forceExit = true;
+ }
+ }
+ public class IvyMessageEventArgs : EventArgs
+ {
+ private IvyClient client;
+ private int id;
+ private string[] args;
+
+ public IvyClient Client
+ {
+ get { return client; }
+ }
+
+ public int Id
+ {
+ get { return id; }
+ }
+
+ public string[] Arguments
+ {
+ get { return args; }
+ }
+ public string this[int i]
+ {
+ get { return args[i]; }
+ }
+ public IvyMessageEventArgs(IvyClient app, int id, string[] args)
+ {
+ this.client = app;
+ this.id = id;
+ this.args = args;
+ }
+ }
+}