PageRenderTime 47ms CodeModel.GetById 14ms RepoModel.GetById 0ms app.codeStats 0ms

/Java tutorial/tutorial/networking/end.html

https://gitlab.com/PNNutkung/Java-API
HTML | 496 lines | 394 code | 77 blank | 25 comment | 0 complexity | 4900bcf4c206ba7bddcd991aa715e205 MD5 | raw file
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  3. "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  4. <html lang="en-US" xmlns="http://www.w3.org/1999/xhtml">
  5. <head>
  6. <title>Custom Networking: End of Trail (The Java&trade; Tutorials)</title>
  7. <meta http-equiv="X-UA-Compatible" content="IE=edge" />
  8. <meta name="description" content="This networking Java tutorial describes networking capabilities of the Java platform, working with URLs, sockets, datagrams, and cookies" />
  9. <meta name="keywords" content="java programming, learn java, java sample code, java networking, java url, java socket, datagram, java cookie" />
  10. <style type="text/css">
  11. body {
  12. margin-left:10px;
  13. margin-right:10px;
  14. line-height: 1.5;
  15. FONT-FAMILY: Arial, Helvetica, sans-serif;
  16. font-size: 0.8em;
  17. }
  18. a:link{text-decoration:none; color:#09569d;}
  19. a:visited{text-decoration:none; color: #3a87cf;}
  20. a:hover{text-decoration:underline; }
  21. code{
  22. font-family:Monaco,Courier,"Courier New";
  23. }
  24. .header-container {
  25. background-color: #fff;
  26. border-bottom: 1px solid #C1CFDA;
  27. -webkit-box-shadow: 0 2px 2px rgba(117, 163, 231, 0.1);
  28. box-shadow: 0 2px 2px rgba(117, 163, 231, 0.1);
  29. }
  30. .bookwrapper {
  31. width: auto;
  32. margin: auto;
  33. }
  34. .clearfix {
  35. }
  36. .clearfloat {
  37. clear: both;
  38. overflow: auto;
  39. height: 0px;
  40. font-size: 1px;
  41. line-height: 0px;
  42. }
  43. #brandProdName {
  44. width: auto;
  45. height: auto;
  46. }
  47. #logocover {
  48. display: block;
  49. background: transparent url(../images/oracle-java-logo.png) 0px 0px no-repeat;
  50. height: 50px;
  51. width: 229px;
  52. float: left;
  53. }
  54. #productName {
  55. font-size: 16px;
  56. position: relative;
  57. top: 19px;
  58. padding-left: 3px;
  59. color: #457798;
  60. white-space: nowrap;
  61. width: 340px;
  62. }
  63. .FigureCaption {
  64. font-family: sans-serif;
  65. text-align: center;
  66. }
  67. #TopBar_bl {
  68. width: 100%;
  69. height: 60px;
  70. }
  71. #TopBar_br {
  72. width: 100%;
  73. height: 60px;
  74. }
  75. #TopBar_tl {
  76. margin-left: -110px;
  77. margin-right: -100px;
  78. align: left;
  79. height: 60px;
  80. }
  81. #TopBar_tr {
  82. width: 100%;
  83. height: 60px;
  84. }
  85. #TopBar {
  86. min-width:700px;
  87. padding:25px 100px 10px;
  88. margin-bottom:25px;
  89. clear:both;
  90. border-bottom:1px solid #d2dde5;
  91. border-radius: 3px;
  92. background:#efefef; /* Old browsers */
  93. /* IE9 SVG, needs conditional override of 'filter' to 'none' */
  94. background: url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiA/Pgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgdmlld0JveD0iMCAwIDEgMSIgcHJlc2VydmVBc3BlY3RSYXRpbz0ibm9uZSI+CiAgPGxpbmVhckdyYWRpZW50IGlkPSJncmFkLXVjZ2ctZ2VuZXJhdGVkIiBncmFkaWVudFVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgeDE9IjAlIiB5MT0iMCUiIHgyPSIwJSIgeTI9IjEwMCUiPgogICAgPHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iI2ZmZmZmZiIgc3RvcC1vcGFjaXR5PSIxIi8+CiAgICA8c3RvcCBvZmZzZXQ9IjEwMCUiIHN0b3AtY29sb3I9IiNlMmVmZjkiIHN0b3Atb3BhY2l0eT0iMSIvPgogIDwvbGluZWFyR3JhZGllbnQ+CiAgPHJlY3QgeD0iMCIgeT0iMCIgd2lkdGg9IjEiIGhlaWdodD0iMSIgZmlsbD0idXJsKCNncmFkLXVjZ2ctZ2VuZXJhdGVkKSIgLz4KPC9zdmc+);
  95. background: -moz-linear-gradient(top, #ffffff 0%, #e2eff9 100%); /* FF3.6+ */
  96. background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#ffffff), color-stop(100%,#e2eff9)); /* Chrome,Safari4+ */
  97. background: -webkit-linear-gradient(top, #ffffff 0%,#e2eff9 100%); /* Chrome10+,Safari5.1+ */
  98. background: -o-linear-gradient(top, #ffffff 0%,#e2eff9 100%); /* Opera 11.10+ */
  99. background: -ms-linear-gradient(top, #ffffff 0%,#e2eff9 100%); /* IE10+ */
  100. background: linear-gradient(to bottom, #ffffff 0%,#e2eff9 100%); /* W3C */
  101. filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#ffffff', endColorstr='#e2eff9',GradientType=0 ); /* IE6-8 */
  102. }
  103. #TopBar_left {
  104. line-height: 14px;
  105. position: absolute;
  106. padding-top: 30px;
  107. padding-right: 30px;
  108. padding-left: 30px;
  109. text-align: left;
  110. font: 13px/20px Arial, Helvetica, sans-serif;
  111. font-weight: bold;
  112. font-size: 20px;
  113. color: #333;
  114. }
  115. #TopBar_right {
  116. line-height: 12px;
  117. float: right;
  118. padding-top: 10px;
  119. padding-right: 30px;
  120. text-align: left;
  121. }
  122. @media print {
  123. #BreadCrumbs, #Download {
  124. display: none;
  125. }
  126. }
  127. @media print {
  128. #TopBar_right {
  129. display: none;
  130. }
  131. }
  132. #TopBar_right a {
  133. font-size: 10px;
  134. margin: 3px;
  135. padding: 0;
  136. }
  137. #BreadCrumbs {
  138. padding: 15px 5px 0.5em 0;
  139. font-family: sans-serif;
  140. float: right;
  141. }
  142. #BreadCrumbs a {
  143. color:#09569d;
  144. }
  145. #BreadCrumbs a:visited, #BreadCrumbs a:link {
  146. text-decoration: none;
  147. }
  148. #BreadCrumbs a:hover, #BreadCrumbs a:active {
  149. text-decoration: underline;
  150. }
  151. #PageTitle {
  152. margin: 0 5px 0.5em 0;
  153. color: #F90000;
  154. }
  155. #PageContent{
  156. margin: 0 5px 0 20px;
  157. }
  158. .LeftBar_shown {
  159. width: 13em;
  160. float: left;
  161. }
  162. @media print {
  163. .LeftBar_shown {
  164. display: none;
  165. }
  166. }
  167. .LeftBar_hidden {
  168. display: none;
  169. }
  170. #Footer {
  171. padding-top: 10px;
  172. padding-left: 10px;
  173. margin-right: 10px;
  174. }
  175. .footertext {
  176. font-size: 10px;
  177. font-family: sans-serif;
  178. margin-top: 1px;
  179. }
  180. .NavBit {
  181. padding: 15px 5px 0.5em 0;
  182. font-family: sans-serif;
  183. }
  184. @media print {
  185. .NavBit {
  186. display: none;
  187. }
  188. }
  189. #TagNotes {
  190. text-align: right;
  191. }
  192. @media print {
  193. #TagNotes a:visited, #TagNotes a:link {
  194. color: #35556B;
  195. text-decoration: none;
  196. }
  197. }
  198. #Contents a, .NavBit a, #TagNotes a {
  199. color:#09569d;
  200. }
  201. #TagNotes a:visited, #TagNotes a:link,
  202. #Contents a:visited, #Contents a:link,
  203. .NavBit a:visited, .NavBit a:link {
  204. text-decoration: none;
  205. }
  206. #TagNotes a:hover, #TagNotes a:active,
  207. #Contents a:hover, #Contents a:active,
  208. .NavBit a:hover, .NavBit a:active {
  209. text-decoration: underline;
  210. }
  211. #Contents {
  212. float: left;
  213. font-family: sans-serif;
  214. }
  215. @media print {
  216. #Contents {
  217. display: none;
  218. }
  219. }
  220. @media screen {
  221. div.PrintHeaders {
  222. display: none;
  223. }
  224. }
  225. .linkLESSON, .nolinkLESSON {
  226. margin-left: 0.5em;
  227. text-indent: -0.5em;
  228. }
  229. .linkAHEAD, .nolinkAHEAD, .linkQUESTIONS, .nolinkQUESTIONS {
  230. margin-left: 1.5em;
  231. text-indent: -0.5em
  232. }
  233. .linkBHEAD, .nolinkBHEAD {
  234. margin-left: 2.5em;
  235. text-indent: -0.5em
  236. }
  237. .linkCHEAD, .nolinkCHEAD {
  238. margin-left: 3.5em;
  239. text-indent: -0.5em
  240. }
  241. .nolinkLESSON, .nolinkAHEAD, .nolinkBHEAD, .nolinkCHEAD,
  242. .nolinkQUESTIONS {
  243. font-weight: bold;
  244. color: #333;
  245. }
  246. .MainFlow_indented {
  247. margin-right: 10px;
  248. margin-left: 15em;
  249. margin-bottom: 2em;
  250. }
  251. .MainFlow_wide {
  252. margin-right: 10px;
  253. margin-left: 10px;
  254. margin-bottom: 2em;
  255. }
  256. @media print {
  257. .MainFlow_indented, .MainFlow_wide {
  258. padding-top: 0;
  259. margin-top: 10px;
  260. margin-right: 10px;
  261. margin-left: 0;
  262. }
  263. }
  264. h1, h2, h3, h4, h5 {
  265. color: #333;
  266. }
  267. h1 {
  268. font-weight: bold;
  269. font-size: 20px;
  270. }
  271. h2 {
  272. font-weight: bold;
  273. font-size: 17px;
  274. }
  275. h3 {
  276. font-weight: bold;
  277. font-size: 14px;
  278. }
  279. h4 {
  280. font-size: 15px;
  281. }
  282. h5 {
  283. font-size: 12px;
  284. }
  285. #ToggleLeft {
  286. display: none;
  287. }
  288. .note {
  289. margin: 0 30px 0px 30px;
  290. }
  291. .codeblock {
  292. margin: 0 30px 0px 30px;
  293. font-size:12px;
  294. font-family:Monaco,Courier,"Courier New";
  295. }
  296. .tocli {
  297. list-style-type:none;
  298. }
  299. .betadraft {
  300. color: red;
  301. }
  302. </style>
  303. </head>
  304. <body>
  305. <noscript>
  306. A browser with JavaScript enabled is required for this page to operate properly.
  307. </noscript>
  308. <!-- endheader -->
  309. <div class="header-container">
  310. <div class="bookwrapper clearfix">
  311. <div id="brandProdName">
  312. <div id="logocover"></div>
  313. <div id="productName" >Documentation</div>
  314. </div>
  315. <br class="clearfloat" />
  316. </div>
  317. </div>
  318. <div id="TopBar">
  319. <div id="TopBar_tr"> <div id="TopBar_tl"> <div id="TopBar_br"> <div id="TopBar_bl">
  320. <div id="TopBar_left">
  321. The Java&trade; Tutorials
  322. </div>
  323. <div id="TopBar_right">
  324. <a target="_blank"
  325. href="http://www.oracle.com/technetwork/java/javase/downloads/java-se-7-tutorial-2012-02-28-1536013.html">Download Ebooks</a><br />
  326. <a target="_blank"
  327. href="http://www.oracle.com/technetwork/java/javase/downloads/index.html">Download JDK</a>
  328. <br />
  329. <a href="../search.html" target="_blank">Search Java Tutorials</a>
  330. </div>
  331. </div> </div> </div> </div> </div>
  332. <div class="MainFlow_wide">
  333. <div id="BreadCrumbs">
  334. <a href="../index.html" target="_top">Home</a>
  335. </div>
  336. <div class="NavBit">
  337. <a href="cookies/custom.html">&laquo;&nbsp;Previous</a>
  338. &bull;
  339. <a href="./TOC.html">Trail</a>
  340. </div>
  341. <div id="PageTitle"><h1>Custom Networking: End of Trail</h1></div>
  342. <div id="PageContent">
  343. <p>You have reached the end of the "Custom Networking" trail.</p>
  344. <p>If you have comments or suggestions about this trail,
  345. use our <a href="http://docs.oracle.com/javase/feedback.html">feedback page</a>
  346. to tell us about it.
  347. </p>
  348. <!--
  349. <h2>
  350. What next?
  351. </h2>
  352. <p>Once you've caught your breath,
  353. you have several choices of where to go next.
  354. You can go to the <a href="../index.html">front page</a>
  355. to see all of your choices,
  356. or you can go directly to one of the following related trails:
  357. </p>
  358. -->
  359. <!--
  360. <p><a href="../rmi/index.html"><img src="../images/security1_2Header.gif" alt="Trail sign 1.2" align="left" width="32" height="32" border="0" /> RMI</a>: RMI is a Java-to-Java alternative to IDL for writing client/server programs.</p>
  361. -->
  362. <p><img src="../images/security1_2Header.gif" alt="Trail sign 1.2" align="left" width="32" height="32" border="0" />
  363. <a class="TutorialLink" target="_top" href="../rmi/index.html">RMI</a>: RMI is a Java-to-Java alternative to IDL for writing client/server programs.</p>
  364. <!--
  365. <p><a href="../security/index.html"><img src="../images/security1_2Header.gif" alt="Trail sign 1.2" align="left" width="32" height="32" border="0" /> Security Features in Java SE</a>: When writing programs that communicate, you need to understand the security implications.</p>
  366. -->
  367. <p><img src="../images/security1_2Header.gif" alt="Trail sign 1.2" align="left" width="32" height="32" border="0" />
  368. <a class="TutorialLink" target="_top" href="../security/index.html">Security Features in Java SE</a>: When writing programs that communicate, you need to understand the security implications.</p>
  369. <!--
  370. <p><a href="../jdbc/index.html"><img src="../images/security1_2Header.gif" alt="Trail sign 1.2" align="left" width="32" height="32" border="0" /> JDBC Database Access</a>: This trail shows you how to access a database from Java programs.</p>
  371. -->
  372. <p><img src="../images/security1_2Header.gif" alt="Trail sign 1.2" align="left" width="32" height="32" border="0" />
  373. <a class="TutorialLink" target="_top" href="../jdbc/index.html">JDBC Database Access</a>: This trail shows you how to access a database from Java programs.</p>
  374. </div>
  375. <div class="NavBit">
  376. <a href="cookies/custom.html">&laquo; Previous</a>
  377. &bull;
  378. <a href="./TOC.html">TOC</a>
  379. </div>
  380. </div>
  381. <hr class="clearfloat"/>
  382. <div id="Footer">
  383. <table width="100%" border="0" cellspacing="0" cellpadding="5" summary="">
  384. <tr>
  385. <td>
  386. <p class="footertext"><a name="license_info">Your use of this</a> page and all the material on pages under &quot;The Java Tutorials&quot; banner
  387. is subject to these <a href="../information/cpyr.html">legal notices</a>.
  388. </p>
  389. <p class="footertext">Copyright &copy; 1995, 2014 Oracle and/or its affiliates. All rights reserved.</p>
  390. </td>
  391. <td align="right">
  392. <p class="footertext">Problems with the examples? Try <a target="_blank"
  393. href="../information/run-examples.html">Compiling and Running
  394. the Examples: FAQs</a>.
  395. </p>
  396. <p class="footertext">
  397. Complaints? Compliments? Suggestions? <a target="_blank"
  398. href="http://docs.oracle.com/javase/feedback.html">Give
  399. us your feedback</a>.
  400. </p>
  401. </td>
  402. </tr>
  403. </table>
  404. </div>
  405. <div class="PrintHeaders">
  406. <b>Previous page:</b> Custom CookieManager
  407. </div>
  408. <!-- Start SiteCatalyst code -->
  409. <script type="text/javascript" language="JavaScript" src="http://www.oracle.com/ocom/groups/systemobject/@mktg_admin/documents/systemobject/s_code_download.js"></script>
  410. <script type="text/javascript" language="JavaScript" src="http://www.oracle.com/ocom/groups/systemobject/@mktg_admin/documents/systemobject/s_code.js"></script>
  411. <noscript>
  412. A browser with JavaScript enabled is required for this page to operate properly.
  413. </noscript>
  414. <!-- ********** DO NOT ALTER ANYTHING BELOW THIS LINE ! *********** -->
  415. <!-- Below code will send the info to Omniture server -->
  416. <script type="text/javascript" language="javascript">var s_code=s.t();if(s_code)document.write(s_code)</script>
  417. <!-- End SiteCatalyst code -->
  418. </body>
  419. </html>