aboutsummaryrefslogtreecommitdiff
path: root/doc/html/api/fr/dgac/ivy/Ivy.html
blob: 3e44d3e9795c49d6977ec2128b7a500f37e55ef4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Frameset//EN""http://www.w3.org/TR/REC-html40/frameset.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc on Wed Aug 08 16:40:15 CEST 2001 -->
<TITLE>
: Class  Ivy
</TITLE>
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
</HEAD>
<BODY BGCOLOR="white">

<!-- ========== START OF NAVBAR ========== -->
<A NAME="navbar_top"><!-- --></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">
  <TR ALIGN="center" VALIGN="top">
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../overview-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
  </TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>

<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;PREV CLASS&nbsp;
&nbsp;<A HREF="../../../fr/dgac/ivy/IvyApplicationAdapter.html"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../../index.html" TARGET="_top"><B>FRAMES</B></A>  &nbsp;
&nbsp;<A HREF="Ivy.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  SUMMARY: &nbsp;INNER&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: &nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<!-- =========== END OF NAVBAR =========== -->

<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
fr.dgac.ivy</FONT>
<BR>
Class  Ivy</H2>
<PRE>
java.lang.Object
  |
  +--<B>fr.dgac.ivy.Ivy</B>
</PRE>
<DL>
<DT><B>All Implemented Interfaces:</B> <DD>java.util.EventListener, <A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html">IvyApplicationListener</A>, java.lang.Runnable</DD>
</DL>
<HR>
<DL>
<DT>public class <B>Ivy</B><DT>extends java.lang.Object<DT>implements java.lang.Runnable, <A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html">IvyApplicationListener</A></DL>

<P>
A class connecting to the Ivy software bus.
 For example:
<pre>
Ivy bus = new Ivy("Dummy agent","ready",null);
bus.bindMsg("(.*)",myMessageListener);
bus.start(null);
</pre>
<P>
<HR>

<P>
<!-- ======== INNER CLASS SUMMARY ======== -->


<!-- =========== FIELD SUMMARY =========== -->

<A NAME="field_summary"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Field Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#appName">appName</A></B></CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;the name of the application on the bus</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#DEFAULT_DOMAIN">DEFAULT_DOMAIN</A></B></CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;the domain for the UDP rendez vous</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#DEFAULT_PORT">DEFAULT_PORT</A></B></CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;the port for the UDP rendez vous, if none is supplied</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#PROCOCOLVERSION">PROCOCOLVERSION</A></B></CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;the protocol version number</TD>
</TR>
</TABLE>
&nbsp;
<!-- ======== CONSTRUCTOR SUMMARY ======== -->

<A NAME="constructor_summary"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Constructor Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#Ivy(java.lang.String, java.lang.String, fr.dgac.ivy.IvyApplicationListener)">Ivy</A></B>(java.lang.String&nbsp;name,
    java.lang.String&nbsp;message,
    <A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html">IvyApplicationListener</A>&nbsp;appcb)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Readies the structures for the software bus connexion.

 </TD>
</TR>
</TABLE>
&nbsp;
<!-- ========== METHOD SUMMARY =========== -->

<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Method Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#addApplicationListener(fr.dgac.ivy.IvyApplicationListener)">addApplicationListener</A></B>(<A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html">IvyApplicationListener</A>&nbsp;callback)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;adds an application listener to a bus</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#bindMsg(java.lang.String, fr.dgac.ivy.IvyMessageListener)">bindMsg</A></B>(java.lang.String&nbsp;regexp,
        <A HREF="../../../fr/dgac/ivy/IvyMessageListener.html">IvyMessageListener</A>&nbsp;callback)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Subscribes to a regular expression.

 </TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#connect(fr.dgac.ivy.IvyClient)">connect</A></B>(<A HREF="../../../fr/dgac/ivy/IvyClient.html">IvyClient</A>&nbsp;client)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;invoked when a Ivy Client has joined the bus</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#die(fr.dgac.ivy.IvyClient, int)">die</A></B>(<A HREF="../../../fr/dgac/ivy/IvyClient.html">IvyClient</A>&nbsp;client,
    int&nbsp;id)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;invoked when a peer request us to leave the bus</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#directMessage(fr.dgac.ivy.IvyClient, int, java.lang.String)">directMessage</A></B>(<A HREF="../../../fr/dgac/ivy/IvyClient.html">IvyClient</A>&nbsp;client,
              int&nbsp;id,
              java.lang.String&nbsp;msgarg)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;invoked when a peer sends us a direct message</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#disconnect(fr.dgac.ivy.IvyClient)">disconnect</A></B>(<A HREF="../../../fr/dgac/ivy/IvyClient.html">IvyClient</A>&nbsp;client)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;invoked when a Ivy Client has left the bus</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#removeApplicationListener(int)">removeApplicationListener</A></B>(int&nbsp;id)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;removes an application listener</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#run()">run</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#sendMsg(java.lang.String)">sendMsg</A></B>(java.lang.String&nbsp;message)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Performs a pattern matching according to everyone's regexps, and sends
 the results to the relevant ivy agents.
 </TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#start(java.lang.String)">start</A></B>(java.lang.String&nbsp;domainbus)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;connects the Ivy bus to a domain or list of domains</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#stop()">stop</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;disconnects from the Ivy bus.
 </TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../fr/dgac/ivy/Ivy.html#unBindMsg(int)">unBindMsg</A></B>(int&nbsp;id)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;unsubscribes a regular expression</TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TD><B>Methods inherited from class java.lang.Object</B></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD>
</TR>
</TABLE>
&nbsp;
<P>

<!-- ============ FIELD DETAIL =========== -->

<A NAME="field_detail"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Field Detail</B></FONT></TD>
</TR>
</TABLE>

<A NAME="appName"><!-- --></A><H3>
appName</H3>
<PRE>
public java.lang.String <B>appName</B></PRE>
<DL>
<DD>the name of the application on the bus</DL>
<HR>

<A NAME="PROCOCOLVERSION"><!-- --></A><H3>
PROCOCOLVERSION</H3>
<PRE>
public static final int <B>PROCOCOLVERSION</B></PRE>
<DL>
<DD>the protocol version number</DL>
<HR>

<A NAME="DEFAULT_PORT"><!-- --></A><H3>
DEFAULT_PORT</H3>
<PRE>
public static final int <B>DEFAULT_PORT</B></PRE>
<DL>
<DD>the port for the UDP rendez vous, if none is supplied</DL>
<HR>

<A NAME="DEFAULT_DOMAIN"><!-- --></A><H3>
DEFAULT_DOMAIN</H3>
<PRE>
public static final java.lang.String <B>DEFAULT_DOMAIN</B></PRE>
<DL>
<DD>the domain for the UDP rendez vous</DL>

<!-- ========= CONSTRUCTOR DETAIL ======== -->

<A NAME="constructor_detail"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Constructor Detail</B></FONT></TD>
</TR>
</TABLE>

<A NAME="Ivy(java.lang.String, java.lang.String, fr.dgac.ivy.IvyApplicationListener)"><!-- --></A><H3>
Ivy</H3>
<PRE>
public <B>Ivy</B>(java.lang.String&nbsp;name,
           java.lang.String&nbsp;message,
           <A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html">IvyApplicationListener</A>&nbsp;appcb)</PRE>
<DL>
<DD>Readies the structures for the software bus connexion.

 All the dirty work is done un the start() method<DD><DL>
<DT><B>Parameters:</B><DD><CODE>name</CODE> - The name of your Ivy agent on the software bus<DD><CODE>message</CODE> - The hellow message you will send once ready<DD><CODE>appcb</CODE> - A callback handling the notification of connexions and
 disconnections, may be null<DT><B>See Also: </B><DD><A HREF="../../../fr/dgac/ivy/Ivy.html#start(java.lang.String)"><CODE>start(java.lang.String)</CODE></A></DL>
</DD>
</DL>

<!-- ============ METHOD DETAIL ========== -->

<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Method Detail</B></FONT></TD>
</TR>
</TABLE>

<A NAME="start(java.lang.String)"><!-- --></A><H3>
start</H3>
<PRE>
public void <B>start</B>(java.lang.String&nbsp;domainbus)
           throws <A HREF="../../../fr/dgac/ivy/IvyException.html">IvyException</A></PRE>
<DL>
<DD>connects the Ivy bus to a domain or list of domains<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>domainbus</CODE> - a domain of the form 10.0.0:1234, it is similar to the
 netmask without the trailing .255. This will determine the meeting point
 of the different applications. Right now, this is done with an UDP
 broadcast. Beware of routing problems ! You can also use a comma
 separated list of domains.</DL>
</DD>
</DL>
<HR>

<A NAME="stop()"><!-- --></A><H3>
stop</H3>
<PRE>
public void <B>stop</B>()</PRE>
<DL>
<DD>disconnects from the Ivy bus.
 TODO is there a bug here ? There is still a thread running and a
 standalone application won't quit here.<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="sendMsg(java.lang.String)"><!-- --></A><H3>
sendMsg</H3>
<PRE>
public int <B>sendMsg</B>(java.lang.String&nbsp;message)</PRE>
<DL>
<DD>Performs a pattern matching according to everyone's regexps, and sends
 the results to the relevant ivy agents.
 <p><em>There is one thread for each client connected, we could also
 create another thread each time we send a message.</em><DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>message</CODE> - A String which will be compared to the regular
 expressions of the different clients<DT><B>Returns:</B><DD>the number of messages actually sent</DL>
</DD>
</DL>
<HR>

<A NAME="bindMsg(java.lang.String, fr.dgac.ivy.IvyMessageListener)"><!-- --></A><H3>
bindMsg</H3>
<PRE>
public int <B>bindMsg</B>(java.lang.String&nbsp;regexp,
                   <A HREF="../../../fr/dgac/ivy/IvyMessageListener.html">IvyMessageListener</A>&nbsp;callback)</PRE>
<DL>
<DD>Subscribes to a regular expression.

 The callback will be executed with
 the saved parameters of the regexp as arguments when a message will sent
 by another agent. A program <em>doesn't</em> receive its own messages.
 <p>Example:
 <br>the Ivy agent A performs <pre>b.bindMsg("^Hello (*)",cb);</pre>
 <br>the Ivy agent B performs <pre>b2.sendMsg("Hello world");</pre>
 <br>a thread in A will uun the callback cb with its second argument set
 to a array of String, with one single element, "world"<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>regexp</CODE> - a perl regular expression, groups are done with parenthesis<DD><CODE>callback</CODE> - any objects implementing the IvyMessageListener
 interface, on the AWT/Swing framework<DT><B>Returns:</B><DD>the id of the regular expression</DL>
</DD>
</DL>
<HR>

<A NAME="unBindMsg(int)"><!-- --></A><H3>
unBindMsg</H3>
<PRE>
public void <B>unBindMsg</B>(int&nbsp;id)
               throws <A HREF="../../../fr/dgac/ivy/IvyException.html">IvyException</A></PRE>
<DL>
<DD>unsubscribes a regular expression<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>id</CODE> - the id of the regular expression, returned when it was bound</DL>
</DD>
</DL>
<HR>

<A NAME="addApplicationListener(fr.dgac.ivy.IvyApplicationListener)"><!-- --></A><H3>
addApplicationListener</H3>
<PRE>
public int <B>addApplicationListener</B>(<A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html">IvyApplicationListener</A>&nbsp;callback)</PRE>
<DL>
<DD>adds an application listener to a bus<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>callback</CODE> - is an object implementing the IvyApplicationListener
 interface<DT><B>Returns:</B><DD>the id of the application listener, useful if you wish to remove
 it later</DL>
</DD>
</DL>
<HR>

<A NAME="removeApplicationListener(int)"><!-- --></A><H3>
removeApplicationListener</H3>
<PRE>
public void <B>removeApplicationListener</B>(int&nbsp;id)</PRE>
<DL>
<DD>removes an application listener<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>id</CODE> - the id of the application listener to remove</DL>
</DD>
</DL>
<HR>

<A NAME="connect(fr.dgac.ivy.IvyClient)"><!-- --></A><H3>
connect</H3>
<PRE>
public void <B>connect</B>(<A HREF="../../../fr/dgac/ivy/IvyClient.html">IvyClient</A>&nbsp;client)</PRE>
<DL>
<DD><B>Description copied from interface: <CODE><A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html">IvyApplicationListener</A></CODE></B></DD>
<DD>invoked when a Ivy Client has joined the bus<DD><DL>
<DT><B>Specified by: </B><DD><CODE><A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html#connect(fr.dgac.ivy.IvyClient)">connect</A></CODE> in interface <CODE><A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html">IvyApplicationListener</A></CODE></DL>
</DD>
<DD>Following copied from interface: <CODE>fr.dgac.ivy.IvyApplicationListener</CODE></DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>client</CODE> - the peer</DL>
</DD>
</DL>
<HR>

<A NAME="disconnect(fr.dgac.ivy.IvyClient)"><!-- --></A><H3>
disconnect</H3>
<PRE>
public void <B>disconnect</B>(<A HREF="../../../fr/dgac/ivy/IvyClient.html">IvyClient</A>&nbsp;client)</PRE>
<DL>
<DD><B>Description copied from interface: <CODE><A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html">IvyApplicationListener</A></CODE></B></DD>
<DD>invoked when a Ivy Client has left the bus<DD><DL>
<DT><B>Specified by: </B><DD><CODE><A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html#disconnect(fr.dgac.ivy.IvyClient)">disconnect</A></CODE> in interface <CODE><A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html">IvyApplicationListener</A></CODE></DL>
</DD>
<DD>Following copied from interface: <CODE>fr.dgac.ivy.IvyApplicationListener</CODE></DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>client</CODE> - the peer</DL>
</DD>
</DL>
<HR>

<A NAME="die(fr.dgac.ivy.IvyClient, int)"><!-- --></A><H3>
die</H3>
<PRE>
public void <B>die</B>(<A HREF="../../../fr/dgac/ivy/IvyClient.html">IvyClient</A>&nbsp;client,
                int&nbsp;id)</PRE>
<DL>
<DD><B>Description copied from interface: <CODE><A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html">IvyApplicationListener</A></CODE></B></DD>
<DD>invoked when a peer request us to leave the bus<DD><DL>
<DT><B>Specified by: </B><DD><CODE><A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html#die(fr.dgac.ivy.IvyClient, int)">die</A></CODE> in interface <CODE><A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html">IvyApplicationListener</A></CODE></DL>
</DD>
<DD>Following copied from interface: <CODE>fr.dgac.ivy.IvyApplicationListener</CODE></DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>client</CODE> - the peer</DL>
</DD>
</DL>
<HR>

<A NAME="directMessage(fr.dgac.ivy.IvyClient, int, java.lang.String)"><!-- --></A><H3>
directMessage</H3>
<PRE>
public void <B>directMessage</B>(<A HREF="../../../fr/dgac/ivy/IvyClient.html">IvyClient</A>&nbsp;client,
                          int&nbsp;id,
                          java.lang.String&nbsp;msgarg)</PRE>
<DL>
<DD><B>Description copied from interface: <CODE><A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html">IvyApplicationListener</A></CODE></B></DD>
<DD>invoked when a peer sends us a direct message<DD><DL>
<DT><B>Specified by: </B><DD><CODE><A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html#directMessage(fr.dgac.ivy.IvyClient, int, java.lang.String)">directMessage</A></CODE> in interface <CODE><A HREF="../../../fr/dgac/ivy/IvyApplicationListener.html">IvyApplicationListener</A></CODE></DL>
</DD>
<DD>Following copied from interface: <CODE>fr.dgac.ivy.IvyApplicationListener</CODE></DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>client</CODE> - the peer<DD><CODE>id</CODE> - &nbsp;<DD><CODE>msgarg</CODE> - the message itself
 this is not yet implemented in java. I believe it has no real use :)</DL>
</DD>
</DL>
<HR>

<A NAME="run()"><!-- --></A><H3>
run</H3>
<PRE>
public void <B>run</B>()</PRE>
<DL>
<DD><DL>
<DT><B>Specified by: </B><DD><CODE>run</CODE> in interface <CODE>java.lang.Runnable</CODE></DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>

<!-- ========== START OF NAVBAR ========== -->
<A NAME="navbar_bottom"><!-- --></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">
  <TR ALIGN="center" VALIGN="top">
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../overview-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
  </TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>

<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;PREV CLASS&nbsp;
&nbsp;<A HREF="../../../fr/dgac/ivy/IvyApplicationAdapter.html"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../../index.html" TARGET="_top"><B>FRAMES</B></A>  &nbsp;
&nbsp;<A HREF="Ivy.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  SUMMARY: &nbsp;INNER&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: &nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<!-- =========== END OF NAVBAR =========== -->

<HR>

</BODY>
</HTML>