]> sjero.net Git - linphone/blob - p2pproxy/dependencies-src/jxse-src-2.5/api/src/net/jxta/socket/package.html
remove mediastreamer2 and add it as a submodule instead.
[linphone] / p2pproxy / dependencies-src / jxse-src-2.5 / api / src / net / jxta / socket / package.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2 <html>
3 <head>
4 </head>
5 <body>
6 <p>The socket package provides interface ala {@link java.net.Socket}
7 over JXTA pipes. Since the PipeService provides uni-directional, and
8 unreliable communication channels, the JxtaSocket employs it's own
9 protocol over pipes to establish bi-directional connections for every
10 request. In addition the JxtaSocket also employs the reliability
11 library to ensure reliable delivery of data.&nbsp; Another feature of
12 JxtaSockets is chunking, which relieves applications from having to
13 worry about mtu size, just remember to invoke flush at the end of data
14 transmission<br>
15 </p>
16 <p><br>
17 </p>
18 <p>JxtaSocket defines the following message elements employed during
19 the life cycle of a JxtaSocket :<br>
20 </p>
21 <div style="margin-left: 40px;"><><span style="color: rgb(51, 51, 255);">
22 &lt;Cred&gt;</span>Credentials to determine trust<span
23  style="color: rgb(51, 51, 255);">&lt;/Cred&gt;</span></><br>
24 <><span style="color: rgb(51, 51, 255);">&lt;reqPipe&gt;</span>requestor's
25 pipe advertisement<span style="color: rgb(51, 51, 255);">&lt;/reqPipe&gt;</span></><br>
26 <span style="color: rgb(51, 51, 255);">&lt;remPipe&gt;</span>Remote
27 pipe advertisement<span style="color: rgb(51, 51, 255);">&lt;/remPipe&gt;</span><br>
28 <span style="color: rgb(51, 51, 255);">&lt;reqPeer&gt;</span>Remote
29 peer advertisement<span style="color: rgb(51, 51, 255);">&lt;/remPeer&gt;</span><br>
30 <span style="color: rgb(51, 51, 255);">&lt;stream&gt;</span>true|false
31 == reliable|or not<span style="color: rgb(51, 51, 255);">&lt;/stream&gt;</span><br>
32 <span style="color: rgb(51, 51, 255);">&lt;close&gt;</span>close request<span
33  style="color: rgb(51, 51, 255);">&lt;/close&gt;<br>
34 </span><span style="color: rgb(51, 51, 255);">&lt;closeACK&gt;</span>ack
35 close request<span style="color: rgb(51, 51, 255);">&lt;/closeACK&gt;</span><span
36  style="color: rgb(51, 51, 255);"></span><br>
37 <span style="color: rgb(51, 51, 255);">&lt;data&gt;</span>data<span
38  style="color: rgb(51, 51, 255);">&lt;/data&gt;</span><br>
39 </div>
40 <p>The socket package also provides interface ala {@link
41 java.net.MulticastSocket} over propagated pipes.&nbsp; Keep in mind
42 JxtaMulticastSocket does not provide chunking nor reliability at this
43 time, therefore one must consider configuration parameters such as the
44 multicast datagram size defined for the TCP Message Transport :<br>
45 </p>
46 <div style="margin-left: 80px;"><span style="color: rgb(51, 51, 255);">&lt;MulticastSize&gt;</span><br>
47 &nbsp;&nbsp;&nbsp; 16384<br>
48 <span style="color: rgb(51, 51, 255);">&lt;/MulticastSize&gt;</span><br>
49 </div>
50 <p>As well as any other mtu size imposed by the JXTA Platform, or the
51 operating system.<br>
52 </p>
53 <p>For examples on how to utilize the net.jxta.socket see the online
54 tutorials on <a
55  href="http://platform.jxta.org/source/browse/platform/www/java/tutorial/examples/socket">JxtaSocket</a>,
56 and <a
57  href="http://platform.jxta.org/source/browse/platform/www/java/tutorial/examples/multicast">JxtaMulticastSocket</a>
58 available at <a href="http://www.jxta.org/Tutorials.html">http://www.jxta.org/Tutorials.html</a><br>
59 </p>
60 <p><br>
61 </p>
62 </body>
63 </html>