diff --git a/.hgtags b/.hgtags
index d028bdc8cd17474b9bf8a689f6a3b0fca0b3f738..e73ad87229fb5816f79d4a443023d91092fc430e 100644
--- a/.hgtags
+++ b/.hgtags
@@ -222,3 +222,4 @@ a2a2a91075ad85becbe10a39d7fd04ef9bea8df5 jdk8-b92
c4908732fef5235f1b98cafe0ce507771ef7892c jdk8-b98
6a099a36589bd933957272ba63e5263bede29971 jdk8-b99
5be9c5bfcfe9b2a40412b4fb364377d49de014eb jdk8-b100
+6901612328239fbd471d20823113c1cf3fdaebee jdk8-b101
diff --git a/make/sun/javazic/tzdata/VERSION b/make/sun/javazic/tzdata/VERSION
index 8ad1064e0581993ba8e28c93183ba74629d72d86..e50b6f37dccfb56442cc4e985671d77d9841ede3 100644
--- a/make/sun/javazic/tzdata/VERSION
+++ b/make/sun/javazic/tzdata/VERSION
@@ -21,4 +21,4 @@
# or visit www.oracle.com if you need additional information or have any
# questions.
#
-tzdata2013c
+tzdata2013d
diff --git a/make/sun/javazic/tzdata/africa b/make/sun/javazic/tzdata/africa
index 2f5d3c5e3fc95d449a193e43508ba8355d63e8ed..6b19b982c6bf31f71a86e12d3276e68ce3e026a4 100644
--- a/make/sun/javazic/tzdata/africa
+++ b/make/sun/javazic/tzdata/africa
@@ -1,22 +1,22 @@
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# This code is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 2 only, as
# published by the Free Software Foundation. Oracle designates this
# particular file as subject to the "Classpath" exception as provided
# by Oracle in the LICENSE file that accompanied this code.
-#
+#
# This code is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
# version 2 for more details (a copy is included in the LICENSE file that
# accompanied this code).
-#
+#
# You should have received a copy of the GNU General Public License version
# 2 along with this work; if not, write to the Free Software Foundation,
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
-#
+#
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
# or visit www.oracle.com if you need additional information or have any
# questions.
@@ -875,12 +875,18 @@ Zone Indian/Mayotte 3:00:56 - LMT 1911 Jul # Mamoutzou
# announced that year's Ramadan daylight-saving transitions would be
# 2012-07-20 and 2012-08-20; see
# This
*/
SubjectCodeSource(Subject subject,
- LinkedList
* This method always returns immediately, whether or not the image
@@ -157,7 +157,7 @@ public interface AppletContext {
* @param stream stream to be associated with the specified key. If this
* parameter is
* Instantiate a JavaBean.
*
* Instantiate a JavaBean.
*
+# ISO 3166 alpha-2 country codes
+#
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
-# ISO 3166 alpha-2 country codes
#
-# From Paul Eggert (2006-09-27):
+# From Paul Eggert (2013-05-27):
#
# This file contains a table with the following columns:
# 1. ISO 3166-1 alpha-2 country code, current as of
-# ISO 3166-1 Newsletter VI-1 (2007-09-21). See:
-#
-# ISO 3166 Maintenance agency (ISO 3166/MA)
-# .
+# ISO 3166-1 Newsletter VI-15 (2013-05-10). See: Updates on ISO 3166
+# http://www.iso.org/iso/home/standards/country_codes/updates_on_iso_3166.htm
# 2. The usual English name for the country,
# chosen so that alphabetic sorting of subsets produces helpful lists.
# This is not the same as the English name in the ISO 3166 tables.
@@ -43,8 +41,9 @@
#
# Lines beginning with `#' are comments.
#
-# From Arthur David Olson (2011-08-17):
-# Resynchronized today with the ISO 3166 site (adding SS for South Sudan).
+# This table is intended as an aid for users, to help them select time
+# zone data appropriate for their practical needs. It is not intended
+# to take or endorse any position on legal or territorial claims.
#
#country-
#code country name
@@ -77,7 +76,7 @@ BL St Barthelemy
BM Bermuda
BN Brunei
BO Bolivia
-BQ Bonaire Sint Eustatius & Saba
+BQ Bonaire, St Eustatius & Saba
BR Brazil
BS Bahamas
BT Bhutan
@@ -258,7 +257,7 @@ SR Suriname
SS South Sudan
ST Sao Tome & Principe
SV El Salvador
-SX Sint Maarten
+SX St Maarten (Dutch part)
SY Syria
SZ Swaziland
TC Turks & Caicos Is
diff --git a/make/sun/javazic/tzdata/leapseconds b/make/sun/javazic/tzdata/leapseconds
index ab6720ded58c9f2e86155bbc458e14830dbb4cf7..912801227a2334d8def9f04e6d4c094ad8a1d3f4 100644
--- a/make/sun/javazic/tzdata/leapseconds
+++ b/make/sun/javazic/tzdata/leapseconds
@@ -1,22 +1,22 @@
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# This code is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 2 only, as
# published by the Free Software Foundation. Oracle designates this
# particular file as subject to the "Classpath" exception as provided
# by Oracle in the LICENSE file that accompanied this code.
-#
+#
# This code is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
# version 2 for more details (a copy is included in the LICENSE file that
# accompanied this code).
-#
+#
# You should have received a copy of the GNU General Public License version
# 2 along with this work; if not, write to the Free Software Foundation,
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
-#
+#
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
# or visit www.oracle.com if you need additional information or have any
# questions.
diff --git a/make/sun/javazic/tzdata/northamerica b/make/sun/javazic/tzdata/northamerica
index 858bf811ac9e08c1fa1a8824f860054115016706..43a0b22504bb4f312e284b9e765414565c337dac 100644
--- a/make/sun/javazic/tzdata/northamerica
+++ b/make/sun/javazic/tzdata/northamerica
@@ -1,22 +1,22 @@
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# This code is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 2 only, as
# published by the Free Software Foundation. Oracle designates this
# particular file as subject to the "Classpath" exception as provided
# by Oracle in the LICENSE file that accompanied this code.
-#
+#
# This code is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
# version 2 for more details (a copy is included in the LICENSE file that
# accompanied this code).
-#
+#
# You should have received a copy of the GNU General Public License version
# 2 along with this work; if not, write to the Free Software Foundation,
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
-#
+#
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
# or visit www.oracle.com if you need additional information or have any
# questions.
diff --git a/make/sun/javazic/tzdata/pacificnew b/make/sun/javazic/tzdata/pacificnew
index 7738a48087be6586975d307d416763727c823663..09000c3457a9333a19a8207c57644cfc4d117621 100644
--- a/make/sun/javazic/tzdata/pacificnew
+++ b/make/sun/javazic/tzdata/pacificnew
@@ -1,22 +1,22 @@
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# This code is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 2 only, as
# published by the Free Software Foundation. Oracle designates this
# particular file as subject to the "Classpath" exception as provided
# by Oracle in the LICENSE file that accompanied this code.
-#
+#
# This code is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
# version 2 for more details (a copy is included in the LICENSE file that
# accompanied this code).
-#
+#
# You should have received a copy of the GNU General Public License version
# 2 along with this work; if not, write to the Free Software Foundation,
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
-#
+#
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
# or visit www.oracle.com if you need additional information or have any
# questions.
diff --git a/make/sun/javazic/tzdata/solar87 b/make/sun/javazic/tzdata/solar87
index 46b1d56025f5858a1c155b1d8f7633ff0d9580e0..0512ca410c1079872bd24884ec54f2138120e4a7 100644
--- a/make/sun/javazic/tzdata/solar87
+++ b/make/sun/javazic/tzdata/solar87
@@ -1,22 +1,22 @@
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# This code is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 2 only, as
# published by the Free Software Foundation. Oracle designates this
# particular file as subject to the "Classpath" exception as provided
# by Oracle in the LICENSE file that accompanied this code.
-#
+#
# This code is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
# version 2 for more details (a copy is included in the LICENSE file that
# accompanied this code).
-#
+#
# You should have received a copy of the GNU General Public License version
# 2 along with this work; if not, write to the Free Software Foundation,
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
-#
+#
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
# or visit www.oracle.com if you need additional information or have any
# questions.
diff --git a/make/sun/javazic/tzdata/solar88 b/make/sun/javazic/tzdata/solar88
index 71b60d5d74adb0d63c30f4c330a00a1f59bb79b2..3314cb1d64017729a34a3b56ada60c85106d9e85 100644
--- a/make/sun/javazic/tzdata/solar88
+++ b/make/sun/javazic/tzdata/solar88
@@ -1,22 +1,22 @@
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# This code is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 2 only, as
# published by the Free Software Foundation. Oracle designates this
# particular file as subject to the "Classpath" exception as provided
# by Oracle in the LICENSE file that accompanied this code.
-#
+#
# This code is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
# version 2 for more details (a copy is included in the LICENSE file that
# accompanied this code).
-#
+#
# You should have received a copy of the GNU General Public License version
# 2 along with this work; if not, write to the Free Software Foundation,
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
-#
+#
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
# or visit www.oracle.com if you need additional information or have any
# questions.
diff --git a/make/sun/javazic/tzdata/solar89 b/make/sun/javazic/tzdata/solar89
index ae2bea8876acd1358fb90131f00f89733b51eb78..3aa88cf0893b86a83de1aadfaa9df70bb5568afc 100644
--- a/make/sun/javazic/tzdata/solar89
+++ b/make/sun/javazic/tzdata/solar89
@@ -1,22 +1,22 @@
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# This code is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 2 only, as
# published by the Free Software Foundation. Oracle designates this
# particular file as subject to the "Classpath" exception as provided
# by Oracle in the LICENSE file that accompanied this code.
-#
+#
# This code is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
# version 2 for more details (a copy is included in the LICENSE file that
# accompanied this code).
-#
+#
# You should have received a copy of the GNU General Public License version
# 2 along with this work; if not, write to the Free Software Foundation,
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
-#
+#
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
# or visit www.oracle.com if you need additional information or have any
# questions.
diff --git a/make/sun/javazic/tzdata/southamerica b/make/sun/javazic/tzdata/southamerica
index d1865d3f19b07bb58aa6aff4924fc5c649daf7c4..e7df18ad2c31b64ffaa913ca26c364bec1219953 100644
--- a/make/sun/javazic/tzdata/southamerica
+++ b/make/sun/javazic/tzdata/southamerica
@@ -1,22 +1,22 @@
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# This code is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 2 only, as
# published by the Free Software Foundation. Oracle designates this
# particular file as subject to the "Classpath" exception as provided
# by Oracle in the LICENSE file that accompanied this code.
-#
+#
# This code is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
# version 2 for more details (a copy is included in the LICENSE file that
# accompanied this code).
-#
+#
# You should have received a copy of the GNU General Public License version
# 2 along with this work; if not, write to the Free Software Foundation,
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
-#
+#
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
# or visit www.oracle.com if you need additional information or have any
# questions.
@@ -994,7 +994,7 @@ Rule Brazil 2007 only - Feb 25 0:00 0 -
# adopted by the same states as before.
Rule Brazil 2007 only - Oct Sun>=8 0:00 1:00 S
# From Frederico A. C. Neves (2008-09-10):
-# Acording to this decree
+# According to this decree
#
# http://www.planalto.gov.br/ccivil_03/_Ato2007-2010/2008/Decreto/D6558.htm
#
@@ -1226,7 +1226,7 @@ Zone America/Rio_Branco -4:31:12 - LMT 1914
# http://www.emol.com/noticias/nacional/detalle/detallenoticias.asp?idnoticia=467651
#
#
-# This is not yet reflected in the offical "cambio de hora" site, but
+# This is not yet reflected in the official "cambio de hora" site, but
# probably will be soon:
#
# http://www.horaoficial.cl/cambio.htm
diff --git a/make/sun/javazic/tzdata/systemv b/make/sun/javazic/tzdata/systemv
index 0b0a2665654507daa6e5e991001485fefea5d4be..f909f9c76dbd4cfc8f9b8fa9ac1de182dfc61dcc 100644
--- a/make/sun/javazic/tzdata/systemv
+++ b/make/sun/javazic/tzdata/systemv
@@ -1,22 +1,22 @@
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# This code is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 2 only, as
# published by the Free Software Foundation. Oracle designates this
# particular file as subject to the "Classpath" exception as provided
# by Oracle in the LICENSE file that accompanied this code.
-#
+#
# This code is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
# version 2 for more details (a copy is included in the LICENSE file that
# accompanied this code).
-#
+#
# You should have received a copy of the GNU General Public License version
# 2 along with this work; if not, write to the Free Software Foundation,
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
-#
+#
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
# or visit www.oracle.com if you need additional information or have any
# questions.
diff --git a/make/sun/javazic/tzdata/zone.tab b/make/sun/javazic/tzdata/zone.tab
index cbcdc075bf77a7950240542795b0caa90e3b0c00..aa247c26df84376ab6c38655deee596cce6252c1 100644
--- a/make/sun/javazic/tzdata/zone.tab
+++ b/make/sun/javazic/tzdata/zone.tab
@@ -1,41 +1,44 @@
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# This code is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 2 only, as
# published by the Free Software Foundation. Oracle designates this
# particular file as subject to the "Classpath" exception as provided
# by Oracle in the LICENSE file that accompanied this code.
-#
+#
# This code is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
# version 2 for more details (a copy is included in the LICENSE file that
# accompanied this code).
-#
+#
# You should have received a copy of the GNU General Public License version
# 2 along with this work; if not, write to the Free Software Foundation,
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
-#
+#
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
# or visit www.oracle.com if you need additional information or have any
# questions.
#
-#
+# TZ zone descriptions
+#
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
#
-# TZ zone descriptions
-#
-# From Paul Eggert (1996-08-05):
+# From Paul Eggert (2013-05-27):
#
# This file contains a table with the following columns:
# 1. ISO 3166 2-character country code. See the file `iso3166.tab'.
+# This identifies a country that overlaps the zone. The country may
+# overlap other zones and the zone may overlap other countries.
# 2. Latitude and longitude of the zone's principal location
# in ISO 6709 sign-degrees-minutes-seconds format,
# either +-DDMM+-DDDMM or +-DDMMSS+-DDDMMSS,
# first latitude (+ is north), then longitude (+ is east).
+# This location need not lie within the column-1 country.
# 3. Zone name used in value of TZ environment variable.
+# Please see the 'Theory' file for how zone names are chosen.
# 4. Comments; present if and only if the country has multiple rows.
#
# Columns are separated by a single tab.
@@ -45,6 +48,10 @@
#
# Lines beginning with `#' are comments.
#
+# This table is intended as an aid for users, to help them select time
+# zone data appropriate for their practical needs. It is not intended
+# to take or endorse any position on legal or territorial claims.
+#
#country-
#code coordinates TZ comments
AD +4230+00131 Europe/Andorra
@@ -239,7 +246,7 @@ ID -0002+10920 Asia/Pontianak west & central Borneo
ID -0507+11924 Asia/Makassar east & south Borneo, Sulawesi (Celebes), Bali, Nusa Tengarra, west Timor
ID -0232+14042 Asia/Jayapura west New Guinea (Irian Jaya) & Malukus (Moluccas)
IE +5320-00615 Europe/Dublin
-IL +3146+03514 Asia/Jerusalem
+IL +314650+0351326 Asia/Jerusalem
IM +5409-00428 Europe/Isle_of_Man
IN +2232+08822 Asia/Kolkata
IO -0720+07225 Indian/Chagos
diff --git a/make/tools/CharsetMapping/IBM290.c2b b/make/tools/CharsetMapping/IBM290.c2b
new file mode 100644
index 0000000000000000000000000000000000000000..16cb4665efcc6831254a4e11c27f6fde53ca7ab1
--- /dev/null
+++ b/make/tools/CharsetMapping/IBM290.c2b
@@ -0,0 +1,100 @@
+#
+# Diff of
+# b2c: cdctables.zip/Package2.zip/IBM-290.zip/012234B0.TPMAP100
+# c2b: cdctables.zip/Package2.zip/IBM-290.zip/012234B0.UPMAP100
+#
+# fullwidth form
+0x4B U+FF0E
+0x4C U+FF1C
+0x4D U+FF08
+0x4E U+FF0B
+0x4F U+FF5C
+0x50 U+FF06
+0x5A U+FF01
+0x5C U+FF0A
+0x5D U+FF09
+0x5E U+FF1B
+0x60 U+FF0D
+0x61 U+FF0F
+0x62 U+FF41
+0x63 U+FF42
+0x64 U+FF43
+0x65 U+FF44
+0x66 U+FF45
+0x67 U+FF46
+0x68 U+FF47
+0x69 U+FF48
+0x6B U+FF0C
+0x6C U+FF05
+0x6D U+FF3F
+0x6E U+FF1E
+0x6F U+FF1F
+0x70 U+FF3B
+0x71 U+FF49
+0x72 U+FF4A
+0x73 U+FF4B
+0x74 U+FF4C
+0x75 U+FF4D
+0x76 U+FF4E
+0x77 U+FF4F
+0x78 U+FF50
+0x79 U+FF40
+0x7A U+FF1A
+0x7B U+FF03
+0x7C U+FF20
+0x7D U+FF07
+0x7E U+FF1D
+0x7F U+FF02
+0x80 U+FF3D
+0x8B U+FF51
+0x9B U+FF52
+0xA0 U+FF5E
+0xAB U+FF53
+0xB0 U+FF3E
+0xB2 U+FF3C
+0xB3 U+FF54
+0xB4 U+FF55
+0xB5 U+FF56
+0xB6 U+FF57
+0xB7 U+FF58
+0xB8 U+FF59
+0xB9 U+FF5A
+0xC0 U+FF5B
+0xC1 U+FF21
+0xC2 U+FF22
+0xC3 U+FF23
+0xC4 U+FF24
+0xC5 U+FF25
+0xC6 U+FF26
+0xC7 U+FF27
+0xC8 U+FF28
+0xC9 U+FF29
+0xD0 U+FF5D
+0xD1 U+FF2A
+0xD2 U+FF2B
+0xD3 U+FF2C
+0xD4 U+FF2D
+0xD5 U+FF2E
+0xD6 U+FF2F
+0xD7 U+FF30
+0xD8 U+FF31
+0xD9 U+FF32
+0xE0 U+FF04
+0xE2 U+FF33
+0xE3 U+FF34
+0xE4 U+FF35
+0xE5 U+FF36
+0xE6 U+FF37
+0xE7 U+FF38
+0xE8 U+FF39
+0xE9 U+FF3A
+0xF0 U+FF10
+0xF1 U+FF11
+0xF2 U+FF12
+0xF3 U+FF13
+0xF4 U+FF14
+0xF5 U+FF15
+0xF6 U+FF16
+0xF7 U+FF17
+0xF8 U+FF18
+0xF9 U+FF19
diff --git a/make/tools/CharsetMapping/IBM290.map b/make/tools/CharsetMapping/IBM290.map
new file mode 100644
index 0000000000000000000000000000000000000000..4b46f581677d6a14d397c03c15530a2467676c6b
--- /dev/null
+++ b/make/tools/CharsetMapping/IBM290.map
@@ -0,0 +1,232 @@
+#
+# b2c mapping for IBM290, generated from
+# cdctables.zip/Package2.zip/IBM-290.zip/012234B0.TPMAP100
+#
+0x00 U+0000
+0x01 U+0001
+0x02 U+0002
+0x03 U+0003
+0x04 U+009C
+0x05 U+0009
+0x06 U+0086
+0x07 U+007F
+0x08 U+0097
+0x09 U+008D
+0x0A U+008E
+0x0B U+000B
+0x0C U+000C
+0x0D U+000D
+0x0E U+000E
+0x0F U+000F
+0x10 U+0010
+0x11 U+0011
+0x12 U+0012
+0x13 U+0013
+0x14 U+009D
+0x15 U+0085
+0x16 U+0008
+0x17 U+0087
+0x18 U+0018
+0x19 U+0019
+0x1A U+0092
+0x1B U+008F
+0x1C U+001C
+0x1D U+001D
+0x1E U+001E
+0x1F U+001F
+0x20 U+0080
+0x21 U+0081
+0x22 U+0082
+0x23 U+0083
+0x24 U+0084
+0x25 U+000A
+0x26 U+0017
+0x27 U+001B
+0x28 U+0088
+0x29 U+0089
+0x2A U+008A
+0x2B U+008B
+0x2C U+008C
+0x2D U+0005
+0x2E U+0006
+0x2F U+0007
+0x30 U+0090
+0x31 U+0091
+0x32 U+0016
+0x33 U+0093
+0x34 U+0094
+0x35 U+0095
+0x36 U+0096
+0x37 U+0004
+0x38 U+0098
+0x39 U+0099
+0x3A U+009A
+0x3B U+009B
+0x3C U+0014
+0x3D U+0015
+0x3E U+009E
+0x3F U+001A
+0x40 U+0020
+0x41 U+FF61
+0x42 U+FF62
+0x43 U+FF63
+0x44 U+FF64
+0x45 U+FF65
+0x46 U+FF66
+0x47 U+FF67
+0x48 U+FF68
+0x49 U+FF69
+0x4A U+00A3
+0x4B U+002E
+0x4C U+003C
+0x4D U+0028
+0x4E U+002B
+0x4F U+007C
+0x50 U+0026
+0x51 U+FF6A
+0x52 U+FF6B
+0x53 U+FF6C
+0x54 U+FF6D
+0x55 U+FF6E
+0x56 U+FF6F
+0x58 U+FF70
+0x5A U+0021
+0x5B U+00A5
+0x5C U+002A
+0x5D U+0029
+0x5E U+003B
+0x5F U+00AC
+0x60 U+002D
+0x61 U+002F
+0x62 U+0061
+0x63 U+0062
+0x64 U+0063
+0x65 U+0064
+0x66 U+0065
+0x67 U+0066
+0x68 U+0067
+0x69 U+0068
+0x6B U+002C
+0x6C U+0025
+0x6D U+005F
+0x6E U+003E
+0x6F U+003F
+0x70 U+005B
+0x71 U+0069
+0x72 U+006A
+0x73 U+006B
+0x74 U+006C
+0x75 U+006D
+0x76 U+006E
+0x77 U+006F
+0x78 U+0070
+0x79 U+0060
+0x7A U+003A
+0x7B U+0023
+0x7C U+0040
+0x7D U+0027
+0x7E U+003D
+0x7F U+0022
+0x80 U+005D
+0x81 U+FF71
+0x82 U+FF72
+0x83 U+FF73
+0x84 U+FF74
+0x85 U+FF75
+0x86 U+FF76
+0x87 U+FF77
+0x88 U+FF78
+0x89 U+FF79
+0x8A U+FF7A
+0x8B U+0071
+0x8C U+FF7B
+0x8D U+FF7C
+0x8E U+FF7D
+0x8F U+FF7E
+0x90 U+FF7F
+0x91 U+FF80
+0x92 U+FF81
+0x93 U+FF82
+0x94 U+FF83
+0x95 U+FF84
+0x96 U+FF85
+0x97 U+FF86
+0x98 U+FF87
+0x99 U+FF88
+0x9A U+FF89
+0x9B U+0072
+0x9D U+FF8A
+0x9E U+FF8B
+0x9F U+FF8C
+0xA0 U+007E
+0xA1 U+203E
+0xA2 U+FF8D
+0xA3 U+FF8E
+0xA4 U+FF8F
+0xA5 U+FF90
+0xA6 U+FF91
+0xA7 U+FF92
+0xA8 U+FF93
+0xA9 U+FF94
+0xAA U+FF95
+0xAB U+0073
+0xAC U+FF96
+0xAD U+FF97
+0xAE U+FF98
+0xAF U+FF99
+0xB0 U+005E
+0xB1 U+00A2
+0xB2 U+005C
+0xB3 U+0074
+0xB4 U+0075
+0xB5 U+0076
+0xB6 U+0077
+0xB7 U+0078
+0xB8 U+0079
+0xB9 U+007A
+0xBA U+FF9A
+0xBB U+FF9B
+0xBC U+FF9C
+0xBD U+FF9D
+0xBE U+FF9E
+0xBF U+FF9F
+0xC0 U+007B
+0xC1 U+0041
+0xC2 U+0042
+0xC3 U+0043
+0xC4 U+0044
+0xC5 U+0045
+0xC6 U+0046
+0xC7 U+0047
+0xC8 U+0048
+0xC9 U+0049
+0xD0 U+007D
+0xD1 U+004A
+0xD2 U+004B
+0xD3 U+004C
+0xD4 U+004D
+0xD5 U+004E
+0xD6 U+004F
+0xD7 U+0050
+0xD8 U+0051
+0xD9 U+0052
+0xE0 U+0024
+0xE2 U+0053
+0xE3 U+0054
+0xE4 U+0055
+0xE5 U+0056
+0xE6 U+0057
+0xE7 U+0058
+0xE8 U+0059
+0xE9 U+005A
+0xF0 U+0030
+0xF1 U+0031
+0xF2 U+0032
+0xF3 U+0033
+0xF4 U+0034
+0xF5 U+0035
+0xF6 U+0036
+0xF7 U+0037
+0xF8 U+0038
+0xF9 U+0039
+0xFF U+009F
diff --git a/make/tools/CharsetMapping/IBM300.c2b b/make/tools/CharsetMapping/IBM300.c2b
new file mode 100644
index 0000000000000000000000000000000000000000..ee1989e6116d7ebdc2d9af46bf0d5abef5648a8b
--- /dev/null
+++ b/make/tools/CharsetMapping/IBM300.c2b
@@ -0,0 +1,50 @@
+#
+# Diff of
+# b2c: cdctables.zip/Package2.zip/IBM-300.zip/012C34B0.TPMAP120
+# c2b: cdctables.zip/Package2.zip/IBM-300.zip/012C34B0.UPMAP120
+#
+4260 2212
+426A 00A6
+43A1 301C
+444A 2014
+446E F86F
+447C 2016
+4C7D 9E7C
+4EB3 9830
+4F5E 5861
+507F 91AC
+5190 56CA
+51F1 6805
+51FA 91B1
+5261 9EB4
+52A1 881F
+52C9 840A
+52DA 7E61
+52EC 4FE0
+5353 8EC0
+5373 7E6B
+53B3 8346
+53DA 9A52
+53E8 87EC
+53EE 7130
+53F8 8523
+5443 5C5B
+5464 9DD7
+547D 5699
+5481 525D
+54A3 6414
+54A4 7626
+54CA 7C1E
+54CD 6451
+54D4 555E
+54FA 6F51
+5550 7006
+5553 79B1
+555F 9EB5
+55C0 5C62
+55C1 985A
+5B72 6522
+5BFE 688E
+60F1 7E48
+61B0 8141
+66C8 9839
diff --git a/make/tools/CharsetMapping/IBM300.map b/make/tools/CharsetMapping/IBM300.map
new file mode 100644
index 0000000000000000000000000000000000000000..4c207cbab3c80682f6bbc2e1ec32edc876472d7e
--- /dev/null
+++ b/make/tools/CharsetMapping/IBM300.map
@@ -0,0 +1,11644 @@
+#
+# b2c mapping for IBM300, generated from
+# cdctables.zip/Package2.zip/IBM-300.zip/012C34B0.TPMAP120
+#
+#
javax.security.auth.Policy.
@@ -469,7 +473,8 @@ public class PolicyFile extends javax.security.auth.Policy {
* @param policyFile the policy Reader object.
*/
private void init(URL policy) {
- PolicyParser pp = new PolicyParser(expandProperties);
+ sun.security.provider.PolicyParser pp =
+ new sun.security.provider.PolicyParser(expandProperties);
try {
InputStreamReader isr
= new InputStreamReader(getInputStream(policy));
@@ -477,12 +482,12 @@ public class PolicyFile extends javax.security.auth.Policy {
isr.close();
KeyStore keyStore = initKeyStore(policy, pp.getKeyStoreUrl(),
pp.getKeyStoreType());
- EnumerationSubjectCodeSource class contains
@@ -57,7 +58,7 @@ class SubjectCodeSource extends CodeSource implements java.io.Serializable {
});
private Subject subject;
- private LinkedListSubjectCodeSource SubjectCodeSource as a LinkedList
* of PolicyParser.PrincipalEntry objects.
*/
- LinkedList
select s.value.toString() from java.lang.String s
- where /java/(s.value.toString())
+ where /java/.test(s.value.toString())
select heap.findClass("java.lang.System").statics.props
- select heap.findClass("java.lang.System").props
@@ -536,7 +535,7 @@ refer to the following built-in variables.
Example: print number of classes that have specific name pattern
- select filter(heap.classes(), "/java.net./(it.name)")
+ select filter(heap.classes(), "/java.net./.test(it.name)")
@@ -559,14 +558,14 @@ Examples:
- select count(heap.classes(), "/java.io./(it.name)")
+ select count(heap.classes(), "/java.io./.test(it.name)")
- select filter(heap.classes(), "/java.io./(it.name)")
+ select filter(heap.classes(), "/java.io./.test(it.name)")
@@ -619,13 +618,13 @@ Examples:
- select filter(referrers(u), "! /java.net./(classof(it).name)")
+ select filter(referrers(u), "! /java.net./.test(classof(it).name)")
from java.net.URL u
- select max(map(heap.objects('java.lang.String', false), 'it.count'))
+ select max(map(heap.objects('java.lang.String', false), 'it.value.length'))
@@ -775,7 +774,7 @@ and walk until parent is null using the callback function to map call.
- select max(heap.objects('java.lang.String'), 'lhs.count > rhs.count')
+ select max(heap.objects('java.lang.String'), 'lhs.value.length > rhs.value.length')
- select map(filter(heap.findClass('java.lang.System').props.table, 'it != null'),
+ select map(filter(heap.findClass('java.lang.System').statics.props.table, 'it != null'),
function (it) {
var res = "";
while (it != null) {
diff --git a/src/share/classes/java/applet/AppletContext.java b/src/share/classes/java/applet/AppletContext.java
index 87623ee334f50f9a42b9c344f9953c22e8f17226..f28308cfb11628ed880248f2e9516cd7e428463e 100644
--- a/src/share/classes/java/applet/AppletContext.java
+++ b/src/share/classes/java/applet/AppletContext.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -56,7 +56,7 @@ public interface AppletContext {
/**
* Returns an Image object that can then be painted on
- * the screen. The url argument that is
+ * the screen. The url argument that is
* passed as an argument must specify an absolute URL.
* null, the specified key is removed
* in this applet context.
- * @throws IOException if the stream size exceeds a certain
+ * @throws IOException if the stream size exceeds a certain
* size limit. Size limit is decided by the implementor of this
* interface.
* @since 1.4
diff --git a/src/share/classes/java/awt/AWTException.java b/src/share/classes/java/awt/AWTException.java
index a8c555c6c8972a3b81d2e0f7aec6a93195dee518..3c03635837fe93d95e883a8cbfba04d8f31b0d0a 100644
--- a/src/share/classes/java/awt/AWTException.java
+++ b/src/share/classes/java/awt/AWTException.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 1997, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,7 @@ package java.awt;
/**
- * Signals that an Absract Window Toolkit exception has occurred.
+ * Signals that an Abstract Window Toolkit exception has occurred.
*
* @author Arthur van Hoff
*/
diff --git a/src/share/classes/java/beans/AppletInitializer.java b/src/share/classes/java/beans/AppletInitializer.java
index 9e4b7239d6155386b3b6b73b0187b279b962a1b6..2c271a236cadb16e2101e2fcbdff60580148a674 100644
--- a/src/share/classes/java/beans/AppletInitializer.java
+++ b/src/share/classes/java/beans/AppletInitializer.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 2000, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -68,7 +68,6 @@ public interface AppletInitializer {
* the Applet with its Container during the subsequent invocation of its
* addChildren() method.
*
- *
- * See the excecute method for details on how
+ * See the execute method for details on how
* methods are chosen using the dynamic types of the target
* and arguments.
*
@@ -147,6 +147,8 @@ public class Expression extends Statement {
* @see #setValue
*
* @return The result of applying this method to these arguments.
+ * @throws Exception if the method with the specified methodName
+ * throws an exception
*/
public Object getValue() throws Exception {
if (value == unbound) {
diff --git a/src/share/classes/java/beans/IndexedPropertyDescriptor.java b/src/share/classes/java/beans/IndexedPropertyDescriptor.java
index d3f16d2901e0a1cef2be8fdf07ec845d96a5dc18..1d59f7afddb15fb310785b6fba04e74b990733ae 100644
--- a/src/share/classes/java/beans/IndexedPropertyDescriptor.java
+++ b/src/share/classes/java/beans/IndexedPropertyDescriptor.java
@@ -207,6 +207,8 @@ public class IndexedPropertyDescriptor extends PropertyDescriptor {
* Sets the method that should be used to read an indexed property value.
*
* @param readMethod The new indexed read method.
+ * @throws IntrospectionException if an exception occurs during
+ * introspection.
*/
public synchronized void setIndexedReadMethod(Method readMethod)
throws IntrospectionException {
@@ -285,6 +287,8 @@ public class IndexedPropertyDescriptor extends PropertyDescriptor {
* Sets the method that should be used to write an indexed property value.
*
* @param writeMethod The new indexed write method.
+ * @throws IntrospectionException if an exception occurs during
+ * introspection.
*/
public synchronized void setIndexedWriteMethod(Method writeMethod)
throws IntrospectionException {
diff --git a/src/share/classes/java/beans/Introspector.java b/src/share/classes/java/beans/Introspector.java
index 783fcbef315e586b1ddf5cf9a0aab8d3049f234c..acc0f77f389b451afd7e0e8eec4390ebf7e11751 100644
--- a/src/share/classes/java/beans/Introspector.java
+++ b/src/share/classes/java/beans/Introspector.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1996, 2011, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -93,8 +93,17 @@ import sun.reflect.misc.ReflectUtil;
public class Introspector {
// Flags that can be used to control getBeanInfo:
+ /**
+ * Flag to indicate to use of all beaninfo.
+ */
public final static int USE_ALL_BEANINFO = 1;
+ /**
+ * Flag to indicate to ignore immediate beaninfo.
+ */
public final static int IGNORE_IMMEDIATE_BEANINFO = 2;
+ /**
+ * Flag to indicate to ignore all beaninfo.
+ */
public final static int IGNORE_ALL_BEANINFO = 3;
// Static Caches to speed up introspection.
@@ -202,7 +211,7 @@ public class Introspector {
* If the BeanInfo class for a Java Bean has been previously Introspected
* based on the same arguments, then the BeanInfo class is retrieved
* from the BeanInfo cache.
- *
+ * @return the BeanInfo for the bean
* @param beanClass The bean class to be analyzed.
* @param stopClass The baseclass at which to stop the analysis. Any
* methods/properties/events in the stopClass or in its baseclasses
diff --git a/src/share/classes/java/beans/PersistenceDelegate.java b/src/share/classes/java/beans/PersistenceDelegate.java
index 01c5bb123876af66d4ed2281bd5a262f93af69aa..bbdcdbf060c0026f7a07faec60bae724f1d5be39 100644
--- a/src/share/classes/java/beans/PersistenceDelegate.java
+++ b/src/share/classes/java/beans/PersistenceDelegate.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -197,6 +197,7 @@ public abstract class PersistenceDelegate {
* The default implementation, calls the initialize
* method of the type's superclass.
*
+ * @param type the type of the instances
* @param oldInstance The instance to be copied.
* @param newInstance The instance that is to be modified.
* @param out The stream to which any initialization statements should be written.
diff --git a/src/share/classes/java/beans/PropertyChangeSupport.java b/src/share/classes/java/beans/PropertyChangeSupport.java
index c3c73179b1a4637c3216c327e9c70aa8480e0923..d55ae76efc8ded9fa4c7c8c1ce554f418bc02966 100644
--- a/src/share/classes/java/beans/PropertyChangeSupport.java
+++ b/src/share/classes/java/beans/PropertyChangeSupport.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1996, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -156,7 +156,7 @@ public class PropertyChangeSupport implements Serializable {
* PropertyChangeListenerProxy, perform the cast, and examine
* the parameter.
*
- *
+ * {@code
* PropertyChangeListener[] listeners = bean.getPropertyChangeListeners();
* for (int i = 0; i < listeners.length; i++) {
* if (listeners[i] instanceof PropertyChangeListenerProxy) {
@@ -168,7 +168,7 @@ public class PropertyChangeSupport implements Serializable {
* }
* }
* }
- *
+ * }
*
* @see PropertyChangeListenerProxy
* @return all of the PropertyChangeListeners added or an
diff --git a/src/share/classes/java/beans/PropertyDescriptor.java b/src/share/classes/java/beans/PropertyDescriptor.java
index 0abdcad972b6e19e23ac9eea7aad1a8f8e22fd4e..c519b504d58afee94795d0024ba0c129e376c046 100644
--- a/src/share/classes/java/beans/PropertyDescriptor.java
+++ b/src/share/classes/java/beans/PropertyDescriptor.java
@@ -243,6 +243,7 @@ public class PropertyDescriptor extends FeatureDescriptor {
* Sets the method that should be used to read the property value.
*
* @param readMethod The new read method.
+ * @throws IntrospectionException if the read method is invalid
*/
public synchronized void setReadMethod(Method readMethod)
throws IntrospectionException {
@@ -313,6 +314,7 @@ public class PropertyDescriptor extends FeatureDescriptor {
* Sets the method that should be used to write the property value.
*
* @param writeMethod The new write method.
+ * @throws IntrospectionException if the write method is invalid
*/
public synchronized void setWriteMethod(Method writeMethod)
throws IntrospectionException {
diff --git a/src/share/classes/java/beans/Transient.java b/src/share/classes/java/beans/Transient.java
index 0a2761ce8b9106f19cfb95a4ca885356b882166a..165621b39fd041b8645079f21df59bea95ac9eaf 100644
--- a/src/share/classes/java/beans/Transient.java
+++ b/src/share/classes/java/beans/Transient.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2008, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2008, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -40,7 +40,7 @@ import static java.lang.annotation.RetentionPolicy.RUNTIME;
* A {@code true} value for the "transient" attribute
* indicates to encoders derived from {@link Encoder}
* that this feature should be ignored.
- *
+ * * The {@code Transient} annotation may be be used * in any of the methods that are involved * in a {@link FeatureDescriptor} subclass @@ -49,7 +49,7 @@ import static java.lang.annotation.RetentionPolicy.RUNTIME; * to put the annotation and it is this declaration * that takes precedence in the case of multiple annotations * being defined for the same feature. - *
+ ** To declare a feature non-transient in a class * whose superclass declares it transient, * use {@code @Transient(false)}. @@ -64,5 +64,11 @@ import static java.lang.annotation.RetentionPolicy.RUNTIME; @Target({METHOD}) @Retention(RUNTIME) public @interface Transient { + /** + * Returns whether or not the {@code Introspector} should + * construct artifacts for the annotated method. + * @return whether or not the {@code Introspector} should + * construct artifacts for the annotated method + */ boolean value() default true; } diff --git a/src/share/classes/java/beans/VetoableChangeSupport.java b/src/share/classes/java/beans/VetoableChangeSupport.java index 6b7e268eba7e1fa0d8d76a5b3a1b935b3d98c85c..293ae5af2c61a2e1820359c9bec7cb7f1ef06740 100644 --- a/src/share/classes/java/beans/VetoableChangeSupport.java +++ b/src/share/classes/java/beans/VetoableChangeSupport.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1996, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -42,7 +42,7 @@ import java.util.Map.Entry; *
* Here is an example of {@code VetoableChangeSupport} usage that follows * the rules and recommendations laid out in the JavaBeans™ specification: - *
+ * {@code
* public class MyBean {
* private final VetoableChangeSupport vcs = new VetoableChangeSupport(this);
*
@@ -68,7 +68,7 @@ import java.util.Map.Entry;
*
* [...]
* }
- *
+ * }
* * A {@code VetoableChangeSupport} instance is thread-safe. *
@@ -156,7 +156,7 @@ public class VetoableChangeSupport implements Serializable {
* VetoableChangeListenerProxy, perform the cast, and examine
* the parameter.
*
- *
+ * {@code
* VetoableChangeListener[] listeners = bean.getVetoableChangeListeners();
* for (int i = 0; i < listeners.length; i++) {
* if (listeners[i] instanceof VetoableChangeListenerProxy) {
@@ -168,7 +168,7 @@ public class VetoableChangeSupport implements Serializable {
* }
* }
* }
- *
+ * }
*
* @see VetoableChangeListenerProxy
* @return all of the VetoableChangeListeners added or an
diff --git a/src/share/classes/java/beans/beancontext/BeanContext.java b/src/share/classes/java/beans/beancontext/BeanContext.java
index c6217289fafdffe8c10f97cdd996b189f0e8b035..308147b9e3c1d22b06a8490c4ee9230586aef755 100644
--- a/src/share/classes/java/beans/beancontext/BeanContext.java
+++ b/src/share/classes/java/beans/beancontext/BeanContext.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 2006, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -64,10 +64,12 @@ public interface BeanContext extends BeanContextChild, Collection, DesignMode, V
* and is defined by the
* java.beans.Beans.instantiate() method.
*
+ * @return a javaBean named as a child of this
+ * BeanContext
* @param beanName The name of the JavaBean to instantiate
* as a child of this BeanContext
- * @throws IOException
- * @throws ClassNotFoundException if the class identified
+ * @throws IOException if an IO problem occurs
+ * @throws ClassNotFoundException if the class identified
* by the beanName parameter is not found
*/
Object instantiateChild(String beanName) throws IOException, ClassNotFoundException;
@@ -83,7 +85,7 @@ public interface BeanContext extends BeanContextChild, Collection, DesignMode, V
* @return an InputStream for reading the resource,
* or null if the resource could not
* be found.
- * @throws IllegalArgumentException if
+ * @throws IllegalArgumentException if
* the resource is not valid
*/
InputStream getResourceAsStream(String name, BeanContextChild bcc) throws IllegalArgumentException;
@@ -98,7 +100,7 @@ public interface BeanContext extends BeanContextChild, Collection, DesignMode, V
* @param bcc the specified child
* @return a URL for the named
* resource for the specified child
- * @throws IllegalArgumentException
+ * @throws IllegalArgumentException
* if the resource is not valid
*/
URL getResource(String name, BeanContextChild bcc) throws IllegalArgumentException;
@@ -109,7 +111,7 @@ public interface BeanContext extends BeanContextChild, Collection, DesignMode, V
* this BeanContext whenever it adds
* or removes a child Component(s).
*
- * @param bcml the BeanContextMembershipListener to be added
+ * @param bcml the BeanContextMembershipListener to be added
*/
void addBeanContextMembershipListener(BeanContextMembershipListener bcml);
diff --git a/src/share/classes/java/beans/beancontext/BeanContextChild.java b/src/share/classes/java/beans/beancontext/BeanContextChild.java
index 841e3ccbc5edb5f20ab5d0f26ea04375ed116a0b..e84b7a7eeb50ddfb6dccce7fec012c757e43e94d 100644
--- a/src/share/classes/java/beans/beancontext/BeanContextChild.java
+++ b/src/share/classes/java/beans/beancontext/BeanContextChild.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 2006, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -82,7 +82,7 @@ public interface BeanContextChild {
*
* @param bc The BeanContext with which
* to associate this BeanContextChild.
- * @throws PropertyVetoException if the
+ * @throws PropertyVetoException if the
* addition of the specified BeanContext is refused.
*/
void setBeanContext(BeanContext bc) throws PropertyVetoException;
diff --git a/src/share/classes/java/beans/beancontext/BeanContextChildSupport.java b/src/share/classes/java/beans/beancontext/BeanContextChildSupport.java
index 056913b654aa5ae22c7d5142d7fb2b1e42e62d9f..b2b855867b57a262eeeafd7de9a6b20df582dbe0 100644
--- a/src/share/classes/java/beans/beancontext/BeanContextChildSupport.java
+++ b/src/share/classes/java/beans/beancontext/BeanContextChildSupport.java
@@ -78,6 +78,7 @@ public class BeanContextChildSupport implements BeanContextChild, BeanContextSer
* construct a BeanContextChildSupport where the JavaBean component
* itself implements BeanContextChild, and encapsulates this, delegating
* that interface to this implementation
+ * @param bcc the underlying bean context child
*/
public BeanContextChildSupport(BeanContextChild bcc) {
@@ -94,7 +95,7 @@ public class BeanContextChildSupport implements BeanContextChild, BeanContextSer
* this BeanContextChildSupport.
* @param bc the new value to be assigned to the BeanContext
* property
- * @throws PropertyVetoException if the change is rejected
+ * @throws PropertyVetoException if the change is rejected
*/
public synchronized void setBeanContext(BeanContext bc) throws PropertyVetoException {
if (bc == beanContext) return;
@@ -361,6 +362,9 @@ public class BeanContextChildSupport implements BeanContextChild, BeanContextSer
*/
protected VetoableChangeSupport vcSupport;
+ /**
+ * The bean context.
+ */
protected transient BeanContext beanContext;
/**
diff --git a/src/share/classes/java/beans/beancontext/BeanContextMembershipEvent.java b/src/share/classes/java/beans/beancontext/BeanContextMembershipEvent.java
index 6b5f4f5609cd653d9c791b0df5067e53a684fdaa..24406d4e7db9b56fe312a4541c66214dd4dd96a2 100644
--- a/src/share/classes/java/beans/beancontext/BeanContextMembershipEvent.java
+++ b/src/share/classes/java/beans/beancontext/BeanContextMembershipEvent.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 2009, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -103,6 +103,7 @@ public class BeanContextMembershipEvent extends BeanContextEvent {
* Is the child specified affected by the event?
* @return true if affected, false
* if not
+ * @param child the object to check for being affected
*/
public boolean contains(Object child) {
return children.contains(child);
diff --git a/src/share/classes/java/beans/beancontext/BeanContextServices.java b/src/share/classes/java/beans/beancontext/BeanContextServices.java
index 168056c260d8b240b1e9fe2bc5830ebf5526b5a6..0348817bfe86d8a3c4bc9c1b44db9ee37b8e0203 100644
--- a/src/share/classes/java/beans/beancontext/BeanContextServices.java
+++ b/src/share/classes/java/beans/beancontext/BeanContextServices.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1998, 2004, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -60,6 +60,7 @@ public interface BeanContextServices extends BeanContext, BeanContextServicesLis
* @param serviceClass the service to add
* @param serviceProvider the BeanContextServiceProvider
* associated with the service
+ * @return true if the service was successful added, false otherwise
*/
boolean addService(Class serviceClass, BeanContextServiceProvider serviceProvider);
@@ -108,7 +109,7 @@ public interface BeanContextServices extends BeanContext, BeanContextServicesLis
* @param bcsrl the
* BeanContextServiceRevokedListener to notify
* if the service should later become revoked
- * @throws TooManyListenersException
+ * @throws TooManyListenersException if there are too many listeners
* @return a reference to this context's named
* Service as requested or null
*/
diff --git a/src/share/classes/java/beans/beancontext/BeanContextServicesSupport.java b/src/share/classes/java/beans/beancontext/BeanContextServicesSupport.java
index 94d104b14bdc55a49c834bf4f3da55728c204898..ca0942efef983fa3de939d04d21da62e2a6de09d 100644
--- a/src/share/classes/java/beans/beancontext/BeanContextServicesSupport.java
+++ b/src/share/classes/java/beans/beancontext/BeanContextServicesSupport.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1998, 2009, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -603,12 +603,16 @@ public class BeanContextServicesSupport extends BeanContextSupport
serviceProvider = bcsp;
}
+ /**
+ * Returns the service provider.
+ * @return the service provider
+ */
protected BeanContextServiceProvider getServiceProvider() {
return serviceProvider;
}
- /*
- * fields
+ /**
+ * The service provider.
*/
protected BeanContextServiceProvider serviceProvider;
@@ -618,6 +622,9 @@ public class BeanContextServicesSupport extends BeanContextSupport
* subclasses can override this method to create new subclasses of
* BCSSServiceProvider without having to overrride addService() in
* order to instantiate.
+ * @param sc the class
+ * @param bcsp the service provider
+ * @return a service provider without overriding addService()
*/
protected BCSSServiceProvider createBCSSServiceProvider(Class sc, BeanContextServiceProvider bcsp) {
@@ -629,7 +636,7 @@ public class BeanContextServicesSupport extends BeanContextSupport
/**
* add a BeanContextServicesListener
*
- * @throws NullPointerException
+ * @throws NullPointerException if the argument is null
*/
public void addBeanContextServicesListener(BeanContextServicesListener bcsl) {
@@ -660,6 +667,8 @@ public class BeanContextServicesSupport extends BeanContextSupport
/**
* add a service
+ * @param serviceClass the service class
+ * @param bcsp the service provider
*/
public boolean addService(Class serviceClass, BeanContextServiceProvider bcsp) {
@@ -668,6 +677,10 @@ public class BeanContextServicesSupport extends BeanContextSupport
/**
* add a service
+ * @param serviceClass the service class
+ * @param bcsp the service provider
+ * @param fireEvent whether or not an event should be fired
+ * @return true if the service was successfully added
*/
protected boolean addService(Class serviceClass, BeanContextServiceProvider bcsp, boolean fireEvent) {
@@ -709,6 +722,9 @@ public class BeanContextServicesSupport extends BeanContextSupport
/**
* remove a service
+ * @param serviceClass the service class
+ * @param bcsp the service provider
+ * @param revokeCurrentServicesNow whether or not to revoke the service
*/
public void revokeService(Class serviceClass, BeanContextServiceProvider bcsp, boolean revokeCurrentServicesNow) {
@@ -1067,6 +1083,7 @@ public class BeanContextServicesSupport extends BeanContextSupport
/**
* Fires a BeanContextServiceEvent notifying of a new service.
+ * @param serviceClass the service class
*/
protected final void fireServiceAdded(Class serviceClass) {
BeanContextServiceAvailableEvent bcssae = new BeanContextServiceAvailableEvent(getBeanContextServicesPeer(), serviceClass);
@@ -1109,6 +1126,8 @@ public class BeanContextServicesSupport extends BeanContextSupport
* Fires a BeanContextServiceRevokedEvent
* indicating that a particular service is
* no longer available.
+ * @param serviceClass the service class
+ * @param revokeNow whether or not the event should be revoked now
*/
protected final void fireServiceRevoked(Class serviceClass, boolean revokeNow) {
Object[] copy;
diff --git a/src/share/classes/java/beans/beancontext/BeanContextSupport.java b/src/share/classes/java/beans/beancontext/BeanContextSupport.java
index 85b1a5a292fd9b33b4fab1e15143a593ac5aae74..a549e2dc317c9c997a97afe668e0859f4011b341 100644
--- a/src/share/classes/java/beans/beancontext/BeanContextSupport.java
+++ b/src/share/classes/java/beans/beancontext/BeanContextSupport.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 2004, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -62,7 +62,6 @@ import java.util.Map;
/**
* This helper class provides a utility implementation of the
* java.beans.beancontext.BeanContext interface.
- *
* * Since this class directly implements the BeanContext interface, the class * can, and is intended to be used either by subclassing this implementation, @@ -351,9 +350,8 @@ public class BeanContextSupport extends BeanContextChildSupport * of Child without having to override add() or the other Collection * methods that add children to the set. *
- * * @param targetChild the child to create the Child on behalf of - * @param peer the peer if the tragetChild and the peer are related by an implementation of BeanContextProxy + * @param peer the peer if the tragetChild and the peer are related by an implementation of BeanContextProxy * @return Subtype-specific subclass of Child without overriding collection methods */ protected BCSChild createBCSChild(Object targetChild, Object peer) { @@ -492,6 +490,7 @@ public class BeanContextSupport extends BeanContextChildSupport * @param callChildSetBC used to indicate that * the child should be notified that it is no * longer nested in this BeanContext. + * @return whether or not was present before being removed */ protected boolean remove(Object targetChild, boolean callChildSetBC) { @@ -580,7 +579,8 @@ public class BeanContextSupport extends BeanContextChildSupport /** * add Collection to set of Children (Unsupported) * implementations must synchronized on the hierarchy lock and "children" protected field - * @throws UnsupportedOperationException + * @throws UnsupportedOperationException thrown unconditionally by this implementation + * @return this implementation unconditionally throws {@code UnsupportedOperationException} */ public boolean addAll(Collection c) { throw new UnsupportedOperationException(); @@ -589,7 +589,9 @@ public class BeanContextSupport extends BeanContextChildSupport /** * remove all specified children (Unsupported) * implementations must synchronized on the hierarchy lock and "children" protected field - * @throws UnsupportedOperationException + * @throws UnsupportedOperationException thrown unconditionally by this implementation + * @return this implementation unconditionally throws {@code UnsupportedOperationException} + */ public boolean removeAll(Collection c) { throw new UnsupportedOperationException(); @@ -599,7 +601,8 @@ public class BeanContextSupport extends BeanContextChildSupport /** * retain only specified children (Unsupported) * implementations must synchronized on the hierarchy lock and "children" protected field - * @throws UnsupportedOperationException + * @throws UnsupportedOperationException thrown unconditionally by this implementation + * @return this implementation unconditionally throws {@code UnsupportedOperationException} */ public boolean retainAll(Collection c) { throw new UnsupportedOperationException(); @@ -608,7 +611,7 @@ public class BeanContextSupport extends BeanContextChildSupport /** * clear the children (Unsupported) * implementations must synchronized on the hierarchy lock and "children" protected field - * @throws UnsupportedOperationException + * @throws UnsupportedOperationException thrown unconditionally by this implementation */ public void clear() { throw new UnsupportedOperationException(); @@ -618,7 +621,7 @@ public class BeanContextSupport extends BeanContextChildSupport * Adds a BeanContextMembershipListener * * @param bcml the BeanContextMembershipListener to add - * @throws NullPointerException + * @throws NullPointerException if the argument is null */ public void addBeanContextMembershipListener(BeanContextMembershipListener bcml) { @@ -636,7 +639,7 @@ public class BeanContextSupport extends BeanContextChildSupport * Removes a BeanContextMembershipListener * * @param bcml the BeanContextMembershipListener to remove - * @throws NullPointerException + * @throws NullPointerException if the argument is null */ public void removeBeanContextMembershipListener(BeanContextMembershipListener bcml) { @@ -655,7 +658,7 @@ public class BeanContextSupport extends BeanContextChildSupport * @param bcc the child object making the request. * * @return the requested resource as an InputStream - * @throws NullPointerException + * @throws NullPointerException if the argument is null */ public InputStream getResourceAsStream(String name, BeanContextChild bcc) { @@ -849,6 +852,8 @@ public class BeanContextSupport extends BeanContextChildSupport * * This method should not however be used by subclasses to replace their * own implementation (if any) of writeObject(). + * @param oos the {@code ObjectOutputStream} to use during serialization + * @throws IOException if serialization failed */ protected void bcsPreSerializationHook(ObjectOutputStream oos) throws IOException { @@ -864,6 +869,9 @@ public class BeanContextSupport extends BeanContextChildSupport * * This method should not however be used by subclasses to replace their * own implementation (if any) of readObject(). + * @param ois the {@code ObjectInputStream} to use during deserialization + * @throws IOException if deserialization failed + * @throws ClassNotFoundException if needed classes are not found */ protected void bcsPreDeserializationHook(ObjectInputStream ois) throws IOException, ClassNotFoundException { @@ -914,6 +922,8 @@ public class BeanContextSupport extends BeanContextChildSupport * used by readObject to deserialize a collection. * @param ois the ObjectInputStream to use * @param coll the Collection + * @throws IOException if deserialization failed + * @throws ClassNotFoundException if needed classes are not found */ protected final void deserialize(ObjectInputStream ois, Collection coll) throws IOException, ClassNotFoundException { int count = 0; @@ -1005,6 +1015,9 @@ public class BeanContextSupport extends BeanContextChildSupport * When an instance of this class is used as a delegate for the * implementation of the BeanContext protocols (and its subprotocols) * there exists a 'chicken and egg' problem during deserialization + * @param ois the ObjectInputStream to use + * @throws IOException if deserialization failed + * @throws ClassNotFoundException if needed classes are not found */ public final void readChildren(ObjectInputStream ois) throws IOException, ClassNotFoundException { @@ -1122,6 +1135,7 @@ public class BeanContextSupport extends BeanContextChildSupport * immediately prior to their being added to the BeanContext. * * + * @param targetChild the child to create the Child on behalf of * @return true iff the child may be added to this BeanContext, otherwise false. */ @@ -1136,6 +1150,7 @@ public class BeanContextSupport extends BeanContextChildSupport * immediately prior to their being removed from the BeanContext. * * + * @param targetChild the child to create the Child on behalf of * @return true iff the child may be removed from this BeanContext, otherwise false. */ @@ -1147,6 +1162,8 @@ public class BeanContextSupport extends BeanContextChildSupport * subclasses may override this method to simply extend add() semantics * after the child has been added and before the event notification has * occurred. The method is called with the child synchronized. + * @param child the child + * @param bcsc the BCSChild */ protected void childJustAddedHook(Object child, BCSChild bcsc) { @@ -1156,6 +1173,8 @@ public class BeanContextSupport extends BeanContextChildSupport * subclasses may override this method to simply extend remove() semantics * after the child has been removed and before the event notification has * occurred. The method is called with the child synchronized. + * @param child the child + * @param bcsc the BCSChild */ protected void childJustRemovedHook(Object child, BCSChild bcsc) { @@ -1254,6 +1273,7 @@ public class BeanContextSupport extends BeanContextChildSupport /** * Fire a BeanContextshipEvent on the BeanContextMembershipListener interface + * @param bcme the event to fire */ protected final void fireChildrenAdded(BeanContextMembershipEvent bcme) { @@ -1267,6 +1287,7 @@ public class BeanContextSupport extends BeanContextChildSupport /** * Fire a BeanContextshipEvent on the BeanContextMembershipListener interface + * @param bcme the event to fire */ protected final void fireChildrenRemoved(BeanContextMembershipEvent bcme) { diff --git a/src/share/classes/java/net/Authenticator.java b/src/share/classes/java/net/Authenticator.java index bc9945c5ddbb56653c9fa4c32ab67a5ed9adf294..28df05ca0d367cea036fec93a41cc19923402d1a 100644 --- a/src/share/classes/java/net/Authenticator.java +++ b/src/share/classes/java/net/Authenticator.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2004, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -103,17 +103,17 @@ class Authenticator { * Sets the authenticator that will be used by the networking code * when a proxy or an HTTP server asks for authentication. *
- * First, if there is a security manager, its checkPermission
+ * First, if there is a security manager, its {@code checkPermission}
* method is called with a
- * NetPermission("setDefaultAuthenticator") permission.
+ * {@code NetPermission("setDefaultAuthenticator")} permission.
* This may result in a java.lang.SecurityException.
*
- * @param a The authenticator to be set. If a is null then
+ * @param a The authenticator to be set. If a is {@code null} then
* any previously set authenticator is removed.
*
* @throws SecurityException
* if a security manager exists and its
- * checkPermission method doesn't allow
+ * {@code checkPermission} method doesn't allow
* setting the default authenticator.
*
* @see SecurityManager#checkPermission
@@ -134,9 +134,9 @@ class Authenticator {
* Ask the authenticator that has been registered with the system
* for a password.
*
- * First, if there is a security manager, its checkPermission
+ * First, if there is a security manager, its {@code checkPermission}
* method is called with a
- * NetPermission("requestPasswordAuthentication") permission.
+ * {@code NetPermission("requestPasswordAuthentication")} permission.
* This may result in a java.lang.SecurityException.
*
* @param addr The InetAddress of the site requesting authorization,
@@ -151,7 +151,7 @@ class Authenticator {
*
* @throws SecurityException
* if a security manager exists and its
- * checkPermission method doesn't allow
+ * {@code checkPermission} method doesn't allow
* the password authentication request.
*
* @see SecurityManager#checkPermission
@@ -193,9 +193,9 @@ class Authenticator {
* because the hostname can be provided in cases where the InetAddress
* is not available.
*
- * First, if there is a security manager, its checkPermission
+ * First, if there is a security manager, its {@code checkPermission}
* method is called with a
- * NetPermission("requestPasswordAuthentication") permission.
+ * {@code NetPermission("requestPasswordAuthentication")} permission.
* This may result in a java.lang.SecurityException.
*
* @param host The hostname of the site requesting authentication.
@@ -211,7 +211,7 @@ class Authenticator {
*
* @throws SecurityException
* if a security manager exists and its
- * checkPermission method doesn't allow
+ * {@code checkPermission} method doesn't allow
* the password authentication request.
*
* @see SecurityManager#checkPermission
@@ -254,9 +254,9 @@ class Authenticator {
* Ask the authenticator that has been registered with the system
* for a password.
*
- * First, if there is a security manager, its checkPermission
+ * First, if there is a security manager, its {@code checkPermission}
* method is called with a
- * NetPermission("requestPasswordAuthentication") permission.
+ * {@code NetPermission("requestPasswordAuthentication")} permission.
* This may result in a java.lang.SecurityException.
*
* @param host The hostname of the site requesting authentication.
@@ -275,7 +275,7 @@ class Authenticator {
*
* @throws SecurityException
* if a security manager exists and its
- * checkPermission method doesn't allow
+ * {@code checkPermission} method doesn't allow
* the password authentication request.
*
* @see SecurityManager#checkPermission
@@ -320,8 +320,8 @@ class Authenticator {
}
/**
- * Gets the hostname of the
- * site or proxy requesting authentication, or null
+ * Gets the {@code hostname} of the
+ * site or proxy requesting authentication, or {@code null}
* if not available.
*
* @return the hostname of the connection requiring authentication, or null
@@ -333,8 +333,8 @@ class Authenticator {
}
/**
- * Gets the InetAddress of the
- * site requesting authorization, or null
+ * Gets the {@code InetAddress} of the
+ * site requesting authorization, or {@code null}
* if not available.
*
* @return the InetAddress of the site requesting authorization, or null
@@ -346,7 +346,7 @@ class Authenticator {
/**
* Gets the port number for the requested connection.
- * @return an int indicating the
+ * @return an {@code int} indicating the
* port for the requested connection.
*/
protected final int getRequestingPort() {
diff --git a/src/share/classes/java/net/ContentHandler.java b/src/share/classes/java/net/ContentHandler.java
index 79bcb0a30cadb531e8200e401e1e2829a60fbce5..8c585cbf35405a59a66d97542dfe2d43c9257e88 100644
--- a/src/share/classes/java/net/ContentHandler.java
+++ b/src/share/classes/java/net/ContentHandler.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -28,21 +28,21 @@ package java.net;
import java.io.IOException;
/**
- * The abstract class ContentHandler is the superclass
- * of all classes that read an Object from a
- * URLConnection.
+ * The abstract class {@code ContentHandler} is the superclass
+ * of all classes that read an {@code Object} from a
+ * {@code URLConnection}.
*
* An application does not generally call the
- * getContent method in this class directly. Instead, an
- * application calls the getContent method in class
- * URL or in URLConnection.
+ * {@code getContent} method in this class directly. Instead, an
+ * application calls the {@code getContent} method in class
+ * {@code URL} or in {@code URLConnection}.
* The application's content handler factory (an instance of a class that
- * implements the interface ContentHandlerFactory set
- * up by a call to setContentHandler) is
- * called with a String giving the MIME type of the
+ * implements the interface {@code ContentHandlerFactory} set
+ * up by a call to {@code setContentHandler}) is
+ * called with a {@code String} giving the MIME type of the
* object being received on the socket. The factory returns an
- * instance of a subclass of ContentHandler, and its
- * getContent method is called to create the object.
+ * instance of a subclass of {@code ContentHandler}, and its
+ * {@code getContent} method is called to create the object.
*
* If no content handler could be found, URLConnection will
* look for a content handler in a user-defineable set of places.
@@ -75,7 +75,7 @@ abstract public class ContentHandler {
* creates an object from it.
*
* @param urlc a URL connection.
- * @return the object read by the ContentHandler.
+ * @return the object read by the {@code ContentHandler}.
* @exception IOException if an I/O error occurs while reading the object.
*/
abstract public Object getContent(URLConnection urlc) throws IOException;
@@ -90,7 +90,7 @@ abstract public class ContentHandler {
*
* @param urlc a URL connection.
* @param classes an array of types requested
- * @return the object read by the ContentHandler that is
+ * @return the object read by the {@code ContentHandler} that is
* the first match of the suggested types.
* null if none of the requested are supported.
* @exception IOException if an I/O error occurs while reading the object.
diff --git a/src/share/classes/java/net/ContentHandlerFactory.java b/src/share/classes/java/net/ContentHandlerFactory.java
index 69a909c5795d948acd231b8ace8aeb9c6c5de7cb..64112e3a80620b7dc6fe3151d2d4e30c64159487 100644
--- a/src/share/classes/java/net/ContentHandlerFactory.java
+++ b/src/share/classes/java/net/ContentHandlerFactory.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 1997, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -28,10 +28,10 @@ package java.net;
/**
* This interface defines a factory for content handlers. An
* implementation of this interface should map a MIME type into an
- * instance of ContentHandler.
+ * instance of {@code ContentHandler}.
*
- * This interface is used by the URLStreamHandler class
- * to create a ContentHandler for a MIME type.
+ * This interface is used by the {@code URLStreamHandler} class
+ * to create a {@code ContentHandler} for a MIME type.
*
* @author James Gosling
* @see java.net.ContentHandler
@@ -40,13 +40,13 @@ package java.net;
*/
public interface ContentHandlerFactory {
/**
- * Creates a new ContentHandler to read an object from
- * a URLStreamHandler.
+ * Creates a new {@code ContentHandler} to read an object from
+ * a {@code URLStreamHandler}.
*
* @param mimetype the MIME type for which a content handler is desired.
- * @return a new ContentHandler to read an object from a
- * URLStreamHandler.
+ * @return a new {@code ContentHandler} to read an object from a
+ * {@code URLStreamHandler}.
* @see java.net.ContentHandler
* @see java.net.URLStreamHandler
*/
diff --git a/src/share/classes/java/net/CookieHandler.java b/src/share/classes/java/net/CookieHandler.java
index 3fbc5bc1ce14c343d5818574b0d02738a31c9237..ef91d009feb6e421a46d7f919dd50b6402a9f806 100644
--- a/src/share/classes/java/net/CookieHandler.java
+++ b/src/share/classes/java/net/CookieHandler.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2003, 2008, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -66,7 +66,7 @@ public abstract class CookieHandler {
* there is no system-wide cookie handler currently set.
* @throws SecurityException
* If a security manager has been installed and it denies
- * {@link NetPermission}("getCookieHandler")
+ * {@link NetPermission}{@code ("getCookieHandler")}
* @see #setDefault(CookieHandler)
*/
public synchronized static CookieHandler getDefault() {
@@ -83,10 +83,10 @@ public abstract class CookieHandler {
* Note: non-standard http protocol handlers may ignore this setting.
*
* @param cHandler The HTTP cookie handler, or
- * null to unset.
+ * {@code null} to unset.
* @throws SecurityException
* If a security manager has been installed and it denies
- * {@link NetPermission}("setCookieHandler")
+ * {@link NetPermission}{@code ("setCookieHandler")}
* @see #getDefault()
*/
public synchronized static void setDefault(CookieHandler cHandler) {
@@ -114,7 +114,7 @@ public abstract class CookieHandler {
* called after all request headers related to choosing cookies
* are added, and before the request is sent.
URI representing the intended use for the
+ * @param uri a {@code URI} representing the intended use for the
* cookies
* @param requestHeaders - a Map from request header
* field names to lists of field values representing
@@ -136,7 +136,7 @@ public abstract class CookieHandler {
* fields that are named Set-Cookie2, present in the response
* headers into a cookie cache.
*
- * @param uri a URI where the cookies come from
+ * @param uri a {@code URI} where the cookies come from
* @param responseHeaders an immutable map from field names to
* lists of field values representing the response
* header fields returned
diff --git a/src/share/classes/java/net/CookieManager.java b/src/share/classes/java/net/CookieManager.java
index b8cae55342b572496e7395347f9c9a0e1e79c7cf..bb80f0a7f25bcefdb4c7e4098e13b55699d5f743 100644
--- a/src/share/classes/java/net/CookieManager.java
+++ b/src/share/classes/java/net/CookieManager.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2005, 2011, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -131,7 +131,7 @@ public class CookieManager extends CookieHandler
*
* This constructor will create new cookie manager with default * cookie store and accept policy. The effect is same as - * CookieManager(null, null). + * {@code CookieManager(null, null)}. */ public CookieManager() { this(null, null); @@ -141,12 +141,12 @@ public class CookieManager extends CookieHandler /** * Create a new cookie manager with specified cookie store and cookie policy. * - * @param store a CookieStore to be used by cookie manager. - * if null, cookie manager will use a default one, + * @param store a {@code CookieStore} to be used by cookie manager. + * if {@code null}, cookie manager will use a default one, * which is an in-memory CookieStore implmentation. - * @param cookiePolicy a CookiePolicy instance + * @param cookiePolicy a {@code CookiePolicy} instance * to be used by cookie manager as policy callback. - * if null, ACCEPT_ORIGINAL_SERVER will + * if {@code null}, ACCEPT_ORIGINAL_SERVER will * be used. */ public CookieManager(CookieStore store, @@ -170,11 +170,11 @@ public class CookieManager extends CookieHandler /** * To set the cookie policy of this cookie manager. * - *
A instance of CookieManager will have + *
A instance of {@code CookieManager} will have * cookie policy ACCEPT_ORIGINAL_SERVER by default. Users always * can call this method to set another cookie policy. * - * @param cookiePolicy the cookie policy. Can be null, which + * @param cookiePolicy the cookie policy. Can be {@code null}, which * has no effects on current cookie policy. */ public void setCookiePolicy(CookiePolicy cookiePolicy) { diff --git a/src/share/classes/java/net/CookiePolicy.java b/src/share/classes/java/net/CookiePolicy.java index 3de98f904da2224ffc425a6fb1f9e8134aa4a698..80948359153f2dbb85f2d86e3da067edd8484c42 100644 --- a/src/share/classes/java/net/CookiePolicy.java +++ b/src/share/classes/java/net/CookiePolicy.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2013, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -71,8 +71,8 @@ public interface CookiePolicy { * * @param uri the URI to consult accept policy with * @param cookie the HttpCookie object in question - * @return true if this cookie should be accepted; - * otherwise, false + * @return {@code true} if this cookie should be accepted; + * otherwise, {@code false} */ public boolean shouldAccept(URI uri, HttpCookie cookie); } diff --git a/src/share/classes/java/net/CookieStore.java b/src/share/classes/java/net/CookieStore.java index 89b9c41dd01a717dc39b7bd845dc03b6ae6b8eaa..648817e4b52df2286561179319c915d0b00d5355 100644 --- a/src/share/classes/java/net/CookieStore.java +++ b/src/share/classes/java/net/CookieStore.java @@ -32,8 +32,8 @@ import java.util.Map; * A CookieStore object represents a storage for cookie. Can store and retrieve * cookies. * - *
{@link CookieManager} will call CookieStore.add to save cookies - * for every incoming HTTP response, and call CookieStore.get to + *
{@link CookieManager} will call {@code CookieStore.add} to save cookies
+ * for every incoming HTTP response, and call {@code CookieStore.get} to
* retrieve cookie for every outgoing HTTP request. A CookieStore
* is responsible for removing HttpCookie instances which have expired.
*
@@ -55,11 +55,11 @@ public interface CookieStore {
* then it is replaced with the new one.
*
* @param uri the uri this cookie associated with.
- * if null, this cookie will not be associated
+ * if {@code null}, this cookie will not be associated
* with an URI
* @param cookie the cookie to store
*
- * @throws NullPointerException if cookie is null
+ * @throws NullPointerException if {@code cookie} is {@code null}
*
* @see #get
*
@@ -77,7 +77,7 @@ public interface CookieStore {
*
* @param uri the uri associated with the cookies to be returned
*
- * @throws NullPointerException if uri is null
+ * @throws NullPointerException if {@code uri} is {@code null}
*
* @see #add
*
@@ -108,14 +108,14 @@ public interface CookieStore {
* Remove a cookie from store.
*
* @param uri the uri this cookie associated with.
- * if null, the cookie to be removed is not associated
- * with an URI when added; if not null, the cookie
+ * if {@code null}, the cookie to be removed is not associated
+ * with an URI when added; if not {@code null}, the cookie
* to be removed is associated with the given URI when added.
* @param cookie the cookie to remove
*
- * @return true if this store contained the specified cookie
+ * @return {@code true} if this store contained the specified cookie
*
- * @throws NullPointerException if cookie is null
+ * @throws NullPointerException if {@code cookie} is {@code null}
*/
public boolean remove(URI uri, HttpCookie cookie);
@@ -123,7 +123,7 @@ public interface CookieStore {
/**
* Remove all cookies in this cookie store.
*
- * @return true if this store changed as a result of the call
+ * @return {@code true} if this store changed as a result of the call
*/
public boolean removeAll();
}
diff --git a/src/share/classes/java/net/DatagramPacket.java b/src/share/classes/java/net/DatagramPacket.java
index 1f6af9eb939d97a91b72d4cd68921ab058dee218..b0728f01cd0d55dea7d1add8d6ebe18dc0e46f82 100644
--- a/src/share/classes/java/net/DatagramPacket.java
+++ b/src/share/classes/java/net/DatagramPacket.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -68,11 +68,11 @@ class DatagramPacket {
int port;
/**
- * Constructs a DatagramPacket for receiving packets of
- * length length, specifying an offset into the buffer.
+ * Constructs a {@code DatagramPacket} for receiving packets of
+ * length {@code length}, specifying an offset into the buffer.
*
- * The length argument must be less than or equal to
- * buf.length.
+ * The {@code length} argument must be less than or equal to
+ * {@code buf.length}.
*
* @param buf buffer for holding the incoming datagram.
* @param offset the offset for the buffer
@@ -87,11 +87,11 @@ class DatagramPacket {
}
/**
- * Constructs a DatagramPacket for receiving packets of
- * length length.
+ * Constructs a {@code DatagramPacket} for receiving packets of
+ * length {@code length}.
*
- * The length argument must be less than or equal to
- * buf.length.
+ * The {@code length} argument must be less than or equal to
+ * {@code buf.length}.
*
* @param buf buffer for holding the incoming datagram.
* @param length the number of bytes to read.
@@ -102,10 +102,10 @@ class DatagramPacket {
/**
* Constructs a datagram packet for sending packets of length
- * length with offset ioffsetto the
+ * {@code length} with offset {@code ioffset}to the
* specified port number on the specified host. The
- * length argument must be less than or equal to
- * buf.length.
+ * {@code length} argument must be less than or equal to
+ * {@code buf.length}.
*
* @param buf the packet data.
* @param offset the packet data offset.
@@ -125,10 +125,10 @@ class DatagramPacket {
/**
* Constructs a datagram packet for sending packets of length
- * length with offset ioffsetto the
+ * {@code length} with offset {@code ioffset}to the
* specified port number on the specified host. The
- * length argument must be less than or equal to
- * buf.length.
+ * {@code length} argument must be less than or equal to
+ * {@code buf.length}.
*
* @param buf the packet data.
* @param offset the packet data offset.
@@ -147,9 +147,9 @@ class DatagramPacket {
/**
* Constructs a datagram packet for sending packets of length
- * length to the specified port number on the specified
- * host. The length argument must be less than or equal
- * to buf.length.
+ * {@code length} to the specified port number on the specified
+ * host. The {@code length} argument must be less than or equal
+ * to {@code buf.length}.
*
* @param buf the packet data.
* @param length the packet length.
@@ -164,9 +164,9 @@ class DatagramPacket {
/**
* Constructs a datagram packet for sending packets of length
- * length to the specified port number on the specified
- * host. The length argument must be less than or equal
- * to buf.length.
+ * {@code length} to the specified port number on the specified
+ * host. The {@code length} argument must be less than or equal
+ * to {@code buf.length}.
*
* @param buf the packet data.
* @param length the packet length.
@@ -207,8 +207,8 @@ class DatagramPacket {
/**
* Returns the data buffer. The data received or the data to be sent
- * starts from the offset in the buffer,
- * and runs for length long.
+ * starts from the {@code offset} in the buffer,
+ * and runs for {@code length} long.
*
* @return the buffer used to receive or send data
* @see #setData(byte[], int, int)
@@ -277,7 +277,7 @@ class DatagramPacket {
/**
* Sets the IP address of the machine to which this datagram
* is being sent.
- * @param iaddr the InetAddress
+ * @param iaddr the {@code InetAddress}
* @since JDK1.1
* @see #getAddress()
*/
@@ -303,7 +303,7 @@ class DatagramPacket {
* Sets the SocketAddress (usually IP address + port number) of the remote
* host to which this datagram is being sent.
*
- * @param address the SocketAddress
+ * @param address the {@code SocketAddress}
* @throws IllegalArgumentException if address is null or is a
* SocketAddress subclass not supported by this socket
*
@@ -324,7 +324,7 @@ class DatagramPacket {
* Gets the SocketAddress (usually IP address + port number) of the remote
* host that this packet is being sent to or is coming from.
*
- * @return the SocketAddress
+ * @return the {@code SocketAddress}
* @since 1.4
* @see #setSocketAddress
*/
@@ -335,7 +335,7 @@ class DatagramPacket {
/**
* Set the data buffer for this packet. With the offset of
* this DatagramPacket set to 0, and the length set to
- * the length of buf.
+ * the length of {@code buf}.
*
* @param buf the buffer to set for this packet.
*
diff --git a/src/share/classes/java/net/DatagramSocket.java b/src/share/classes/java/net/DatagramSocket.java
index d6ffca23755ed1b8411f47052b90441d639da2c5..ab60a263ac7479bdb4dad34fea89246d11cd8e5c 100644
--- a/src/share/classes/java/net/DatagramSocket.java
+++ b/src/share/classes/java/net/DatagramSocket.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -47,14 +47,14 @@ import java.security.PrivilegedExceptionAction;
* a DatagramSocket is bound to a more specific address.
*
* Example:
- *
+ * {@code
* DatagramSocket s = new DatagramSocket(null);
* s.bind(new InetSocketAddress(8888));
- *
+ * }
* Which is equivalent to:
- *
+ * {@code
* DatagramSocket s = new DatagramSocket(8888);
- *
+ * }
* Both cases will create a DatagramSocket able to receive broadcasts on
* UDP port 8888.
*
@@ -161,14 +161,14 @@ class DatagramSocket implements java.io.Closeable {
* an IP address chosen by the kernel.
*
*
If there is a security manager,
- * its checkListen method is first called
+ * its {@code checkListen} method is first called
* with 0 as its argument to ensure the operation is allowed.
* This could result in a SecurityException.
*
* @exception SocketException if the socket could not be opened,
* or the socket could not bind to the specified local port.
* @exception SecurityException if a security manager exists and its
- * checkListen method doesn't allow the operation.
+ * {@code checkListen} method doesn't allow the operation.
*
* @see SecurityManager#checkListen
*/
@@ -195,21 +195,21 @@ class DatagramSocket implements java.io.Closeable {
* Creates a datagram socket, bound to the specified local
* socket address.
*
- * If, if the address is null, creates an unbound socket.
+ * If, if the address is {@code null}, creates an unbound socket.
*
*
If there is a security manager,
- * its checkListen method is first called
+ * its {@code checkListen} method is first called
* with the port from the socket address
* as its argument to ensure the operation is allowed.
* This could result in a SecurityException.
*
- * @param bindaddr local socket address to bind, or null
+ * @param bindaddr local socket address to bind, or {@code null}
* for an unbound socket.
*
* @exception SocketException if the socket could not be opened,
* or the socket could not bind to the specified local port.
* @exception SecurityException if a security manager exists and its
- * checkListen method doesn't allow the operation.
+ * {@code checkListen} method doesn't allow the operation.
*
* @see SecurityManager#checkListen
* @since 1.4
@@ -234,8 +234,8 @@ class DatagramSocket implements java.io.Closeable {
* an IP address chosen by the kernel.
*
*
If there is a security manager,
- * its checkListen method is first called
- * with the port argument
+ * its {@code checkListen} method is first called
+ * with the {@code port} argument
* as its argument to ensure the operation is allowed.
* This could result in a SecurityException.
*
@@ -243,7 +243,7 @@ class DatagramSocket implements java.io.Closeable {
* @exception SocketException if the socket could not be opened,
* or the socket could not bind to the specified local port.
* @exception SecurityException if a security manager exists and its
- * checkListen method doesn't allow the operation.
+ * {@code checkListen} method doesn't allow the operation.
*
* @see SecurityManager#checkListen
*/
@@ -259,8 +259,8 @@ class DatagramSocket implements java.io.Closeable {
* an IP address chosen by the kernel.
*
*
If there is a security manager,
- * its checkListen method is first called
- * with the port argument
+ * its {@code checkListen} method is first called
+ * with the {@code port} argument
* as its argument to ensure the operation is allowed.
* This could result in a SecurityException.
*
@@ -270,7 +270,7 @@ class DatagramSocket implements java.io.Closeable {
* @exception SocketException if the socket could not be opened,
* or the socket could not bind to the specified local port.
* @exception SecurityException if a security manager exists and its
- * checkListen method doesn't allow the operation.
+ * {@code checkListen} method doesn't allow the operation.
*
* @see SecurityManager#checkListen
* @since JDK1.1
@@ -319,10 +319,10 @@ class DatagramSocket implements java.io.Closeable {
}
/**
- * Get the DatagramSocketImpl attached to this socket,
+ * Get the {@code DatagramSocketImpl} attached to this socket,
* creating it if necessary.
*
- * @return the DatagramSocketImpl attached to that
+ * @return the {@code DatagramSocketImpl} attached to that
* DatagramSocket
* @throws SocketException if creation fails.
* @since 1.4
@@ -336,14 +336,14 @@ class DatagramSocket implements java.io.Closeable {
/**
* Binds this DatagramSocket to a specific address and port.
*
- * If the address is null, then the system will pick up
+ * If the address is {@code null}, then the system will pick up
* an ephemeral port and a valid local address to bind the socket.
*
* @param addr The address and port to bind to.
* @throws SocketException if any error happens during the bind, or if the
* socket is already bound.
* @throws SecurityException if a security manager exists and its
- * checkListen method doesn't allow the operation.
+ * {@code checkListen} method doesn't allow the operation.
* @throws IllegalArgumentException if addr is a SocketAddress subclass
* not supported by this socket.
* @since 1.4
@@ -496,7 +496,7 @@ class DatagramSocket implements java.io.Closeable {
* Returns the binding state of the socket.
*
* If the socket was bound prior to being {@link #close closed},
- * then this method will continue to return true
+ * then this method will continue to return {@code true}
* after the socket is closed.
*
* @return true if the socket successfully bound to an address
@@ -510,7 +510,7 @@ class DatagramSocket implements java.io.Closeable {
* Returns the connection state of the socket.
*
* If the socket was connected prior to being {@link #close closed},
- * then this method will continue to return true
+ * then this method will continue to return {@code true}
* after the socket is closed.
*
* @return true if the socket successfully connected to a server
@@ -522,7 +522,7 @@ class DatagramSocket implements java.io.Closeable {
/**
* Returns the address to which this socket is connected. Returns
- * null if the socket is not connected.
+ * {@code null} if the socket is not connected.
*
* If the socket was connected prior to being {@link #close closed},
* then this method will continue to return the connected address
@@ -536,7 +536,7 @@ class DatagramSocket implements java.io.Closeable {
/**
* Returns the port number to which this socket is connected.
- * Returns -1 if the socket is not connected.
+ * Returns {@code -1} if the socket is not connected.
*
* If the socket was connected prior to being {@link #close closed},
* then this method will continue to return the connected port number
@@ -550,14 +550,14 @@ class DatagramSocket implements java.io.Closeable {
/**
* Returns the address of the endpoint this socket is connected to, or
- * null if it is unconnected.
+ * {@code null} if it is unconnected.
*
* If the socket was connected prior to being {@link #close closed},
* then this method will continue to return the connected address
* after the socket is closed.
*
- * @return a SocketAddress representing the remote
- * endpoint of this socket, or null if it is
+ * @return a {@code SocketAddress} representing the remote
+ * endpoint of this socket, or {@code null} if it is
* not connected yet.
* @see #getInetAddress()
* @see #getPort()
@@ -573,8 +573,8 @@ class DatagramSocket implements java.io.Closeable {
/**
* Returns the address of the endpoint this socket is bound to.
*
- * @return a SocketAddress representing the local endpoint of this
- * socket, or null if it is closed or not bound yet.
+ * @return a {@code SocketAddress} representing the local endpoint of this
+ * socket, or {@code null} if it is closed or not bound yet.
* @see #getLocalAddress()
* @see #getLocalPort()
* @see #bind(SocketAddress)
@@ -591,28 +591,28 @@ class DatagramSocket implements java.io.Closeable {
/**
* Sends a datagram packet from this socket. The
- * DatagramPacket includes information indicating the
+ * {@code DatagramPacket} includes information indicating the
* data to be sent, its length, the IP address of the remote host,
* and the port number on the remote host.
*
*
If there is a security manager, and the socket is not currently
* connected to a remote address, this method first performs some
- * security checks. First, if p.getAddress().isMulticastAddress()
+ * security checks. First, if {@code p.getAddress().isMulticastAddress()}
* is true, this method calls the
- * security manager's checkMulticast method
- * with p.getAddress() as its argument.
+ * security manager's {@code checkMulticast} method
+ * with {@code p.getAddress()} as its argument.
* If the evaluation of that expression is false,
* this method instead calls the security manager's
- * checkConnect method with arguments
- * p.getAddress().getHostAddress() and
- * p.getPort(). Each call to a security manager method
+ * {@code checkConnect} method with arguments
+ * {@code p.getAddress().getHostAddress()} and
+ * {@code p.getPort()}. Each call to a security manager method
* could result in a SecurityException if the operation is not allowed.
*
- * @param p the DatagramPacket to be sent.
+ * @param p the {@code DatagramPacket} to be sent.
*
* @exception IOException if an I/O error occurs.
* @exception SecurityException if a security manager exists and its
- * checkMulticast or checkConnect
+ * {@code checkMulticast} or {@code checkConnect}
* method doesn't allow the send.
* @exception PortUnreachableException may be thrown if the socket is connected
* to a currently unreachable destination. Note, there is no
@@ -674,20 +674,20 @@ class DatagramSocket implements java.io.Closeable {
/**
* Receives a datagram packet from this socket. When this method
- * returns, the DatagramPacket's buffer is filled with
+ * returns, the {@code DatagramPacket}'s buffer is filled with
* the data received. The datagram packet also contains the sender's
* IP address, and the port number on the sender's machine.
*
* This method blocks until a datagram is received. The
- * length field of the datagram packet object contains
+ * {@code length} field of the datagram packet object contains
* the length of the received message. If the message is longer than
* the packet's length, the message is truncated.
*
* If there is a security manager, a packet cannot be received if the
- * security manager's checkAccept method
+ * security manager's {@code checkAccept} method
* does not allow it.
*
- * @param p the DatagramPacket into which to place
+ * @param p the {@code DatagramPacket} into which to place
* the incoming data.
* @exception IOException if an I/O error occurs.
* @exception SocketTimeoutException if setSoTimeout was previously called
@@ -786,17 +786,17 @@ class DatagramSocket implements java.io.Closeable {
* Gets the local address to which the socket is bound.
*
*
If there is a security manager, its
- * checkConnect method is first called
- * with the host address and -1
+ * {@code checkConnect} method is first called
+ * with the host address and {@code -1}
* as its arguments to see if the operation is allowed.
*
* @see SecurityManager#checkConnect
* @return the local address to which the socket is bound,
- * null if the socket is closed, or
- * an InetAddress representing
+ * {@code null} if the socket is closed, or
+ * an {@code InetAddress} representing
* {@link InetAddress#isAnyLocalAddress wildcard}
* address if either the socket is not bound, or
- * the security manager checkConnect
+ * the security manager {@code checkConnect}
* method does not allow the operation
* @since 1.1
*/
@@ -824,8 +824,8 @@ class DatagramSocket implements java.io.Closeable {
* is bound.
*
* @return the port number on the local host to which this socket is bound,
- -1 if the socket is closed, or
- 0 if it is not bound yet.
+ {@code -1} if the socket is closed, or
+ {@code 0} if it is not bound yet.
*/
public int getLocalPort() {
if (isClosed())
@@ -883,7 +883,7 @@ class DatagramSocket implements java.io.Closeable {
/**
* Sets the SO_SNDBUF option to the specified value for this
- * DatagramSocket. The SO_SNDBUF option is used by the
+ * {@code DatagramSocket}. The SO_SNDBUF option is used by the
* network implementation as a hint to size the underlying
* network I/O buffers. The SO_SNDBUF setting may also be used
* by the network implementation to determine the maximum size
@@ -897,7 +897,7 @@ class DatagramSocket implements java.io.Closeable {
* is high.
*
* Note: If {@link #send(DatagramPacket)} is used to send a
- * DatagramPacket that is larger than the setting
+ * {@code DatagramPacket} that is larger than the setting
* of SO_SNDBUF then it is implementation specific if the
* packet is sent or discarded.
*
@@ -921,10 +921,10 @@ class DatagramSocket implements java.io.Closeable {
}
/**
- * Get value of the SO_SNDBUF option for this DatagramSocket, that is the
- * buffer size used by the platform for output on this DatagramSocket.
+ * Get value of the SO_SNDBUF option for this {@code DatagramSocket}, that is the
+ * buffer size used by the platform for output on this {@code DatagramSocket}.
*
- * @return the value of the SO_SNDBUF option for this DatagramSocket
+ * @return the value of the SO_SNDBUF option for this {@code DatagramSocket}
* @exception SocketException if there is an error in
* the underlying protocol, such as an UDP error.
* @see #setSendBufferSize
@@ -942,7 +942,7 @@ class DatagramSocket implements java.io.Closeable {
/**
* Sets the SO_RCVBUF option to the specified value for this
- * DatagramSocket. The SO_RCVBUF option is used by the
+ * {@code DatagramSocket}. The SO_RCVBUF option is used by the
* the network implementation as a hint to size the underlying
* network I/O buffers. The SO_RCVBUF setting may also be used
* by the network implementation to determine the maximum size
@@ -979,10 +979,10 @@ class DatagramSocket implements java.io.Closeable {
}
/**
- * Get value of the SO_RCVBUF option for this DatagramSocket, that is the
- * buffer size used by the platform for input on this DatagramSocket.
+ * Get value of the SO_RCVBUF option for this {@code DatagramSocket}, that is the
+ * buffer size used by the platform for input on this {@code DatagramSocket}.
*
- * @return the value of the SO_RCVBUF option for this DatagramSocket
+ * @return the value of the SO_RCVBUF option for this {@code DatagramSocket}
* @exception SocketException if there is an error in the underlying protocol, such as an UDP error.
* @see #setReceiveBufferSize(int)
*/
@@ -1005,26 +1005,26 @@ class DatagramSocket implements java.io.Closeable {
* socket to the same socket address. This is typically for the
* purpose of receiving multicast packets
* (See {@link java.net.MulticastSocket}). The
- * SO_REUSEADDR socket option allows multiple
+ * {@code SO_REUSEADDR} socket option allows multiple
* sockets to be bound to the same socket address if the
- * SO_REUSEADDR socket option is enabled prior
+ * {@code SO_REUSEADDR} socket option is enabled prior
* to binding the socket using {@link #bind(SocketAddress)}.
*
* Note: This functionality is not supported by all existing platforms,
* so it is implementation specific whether this option will be ignored
* or not. However, if it is not supported then
- * {@link #getReuseAddress()} will always return false.
+ * {@link #getReuseAddress()} will always return {@code false}.
*
- * When a DatagramSocket is created the initial setting - * of SO_REUSEADDR is disabled. + * When a {@code DatagramSocket} is created the initial setting + * of {@code SO_REUSEADDR} is disabled. *
- * The behaviour when SO_REUSEADDR is enabled or
+ * The behaviour when {@code SO_REUSEADDR} is enabled or
* disabled after a socket is bound (See {@link #isBound()})
* is not defined.
*
* @param on whether to enable or disable the
* @exception SocketException if an error occurs enabling or
- * disabling the SO_RESUEADDR socket option,
+ * disabling the {@code SO_RESUEADDR} socket option,
* or the socket is closed.
* @since 1.4
* @see #getReuseAddress()
@@ -1045,7 +1045,7 @@ class DatagramSocket implements java.io.Closeable {
/**
* Tests if SO_REUSEADDR is enabled.
*
- * @return a boolean indicating whether or not SO_REUSEADDR is enabled.
+ * @return a {@code boolean} indicating whether or not SO_REUSEADDR is enabled.
* @exception SocketException if there is an error
* in the underlying protocol, such as an UDP error.
* @since 1.4
@@ -1083,7 +1083,7 @@ class DatagramSocket implements java.io.Closeable {
/**
* Tests if SO_BROADCAST is enabled.
- * @return a boolean indicating whether or not SO_BROADCAST is enabled.
+ * @return a {@code boolean} indicating whether or not SO_BROADCAST is enabled.
* @exception SocketException if there is an error
* in the underlying protocol, such as an UDP error.
* @since 1.4
@@ -1105,7 +1105,7 @@ class DatagramSocket implements java.io.Closeable {
* 255} or an IllegalArgumentException will be thrown.
*
Notes: *
For Internet Protocol v4 the value consists of an
- * integer, the least significant 8 bits of which
+ * {@code integer}, the least significant 8 bits of which
* represent the value of the TOS octet in IP packets sent by
* the socket.
* RFC 1349 defines the TOS values as follows:
@@ -1123,10 +1123,10 @@ class DatagramSocket implements java.io.Closeable {
* SocketException indicating that the operation is not
* permitted.
*
- * for Internet Protocol v6 tc is the value that
+ * for Internet Protocol v6 {@code tc} is the value that
* would be placed into the sin6_flowinfo field of the IP header.
*
- * @param tc an int value for the bitset.
+ * @param tc an {@code int} value for the bitset.
* @throws SocketException if there is an error setting the
* traffic class or type-of-service
* @since 1.4
@@ -1205,7 +1205,7 @@ class DatagramSocket implements java.io.Closeable {
* DatagramChannel.open} method.
*
* @return the datagram channel associated with this datagram socket,
- * or null if this socket was not created for a channel
+ * or {@code null} if this socket was not created for a channel
*
* @since 1.4
* @spec JSR-51
@@ -1224,14 +1224,14 @@ class DatagramSocket implements java.io.Closeable {
* application. The factory can be specified only once.
*
* When an application creates a new datagram socket, the socket
- * implementation factory's createDatagramSocketImpl method is
+ * implementation factory's {@code createDatagramSocketImpl} method is
* called to create the actual datagram socket implementation.
*
- * Passing null to the method is a no-op unless the factory
+ * Passing {@code null} to the method is a no-op unless the factory
* was already set.
*
*
If there is a security manager, this method first calls
- * the security manager's checkSetFactory method
+ * the security manager's {@code checkSetFactory} method
* to ensure the operation is allowed.
* This could result in a SecurityException.
*
@@ -1240,7 +1240,7 @@ class DatagramSocket implements java.io.Closeable {
* datagram socket factory.
* @exception SocketException if the factory is already defined.
* @exception SecurityException if a security manager exists and its
- * checkSetFactory method doesn't allow the
+ * {@code checkSetFactory} method doesn't allow the
operation.
* @see
java.net.DatagramSocketImplFactory#createDatagramSocketImpl()
diff --git a/src/share/classes/java/net/DatagramSocketImpl.java b/src/share/classes/java/net/DatagramSocketImpl.java
index 3ed11e4b9d265eaf93e71c52805aace7839a9b98..524f06b83ca1bf14f716c230216584e184fd9217 100644
--- a/src/share/classes/java/net/DatagramSocketImpl.java
+++ b/src/share/classes/java/net/DatagramSocketImpl.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1996, 2006, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -101,7 +101,7 @@ public abstract class DatagramSocketImpl implements SocketOptions {
protected void disconnect() {}
/**
- * Peek at the packet to see who it is from. Updates the specified InetAddress
+ * Peek at the packet to see who it is from. Updates the specified {@code InetAddress}
* to the address which the packet came from.
* @param i an InetAddress object
* @return the port number which the packet came from.
@@ -114,7 +114,7 @@ public abstract class DatagramSocketImpl implements SocketOptions {
/**
* Peek at the packet to see who it is from. The data is copied into the specified
- * DatagramPacket. The data is returned,
+ * {@code DatagramPacket}. The data is returned,
* but not consumed, so that a subsequent peekData/receive operation
* will see the same data.
* @param p the Packet Received.
@@ -163,7 +163,7 @@ public abstract class DatagramSocketImpl implements SocketOptions {
/**
* Set the TTL (time-to-live) option.
- * @param ttl an int specifying the time-to-live value
+ * @param ttl an {@code int} specifying the time-to-live value
* @exception IOException if an I/O exception occurs
* while setting the time-to-live option.
* @see #getTimeToLive()
@@ -174,7 +174,7 @@ public abstract class DatagramSocketImpl implements SocketOptions {
* Retrieve the TTL (time-to-live) option.
* @exception IOException if an I/O exception occurs
* while retrieving the time-to-live option
- * @return an int representing the time-to-live value
+ * @return an {@code int} representing the time-to-live value
* @see #setTimeToLive(int)
*/
protected abstract int getTimeToLive() throws IOException;
@@ -227,7 +227,7 @@ public abstract class DatagramSocketImpl implements SocketOptions {
/**
* Gets the local port.
- * @return an int representing the local port value
+ * @return an {@code int} representing the local port value
*/
protected int getLocalPort() {
return localPort;
@@ -235,7 +235,7 @@ public abstract class DatagramSocketImpl implements SocketOptions {
/**
* Gets the datagram socket file descriptor.
- * @return a FileDescriptor object representing the datagram socket
+ * @return a {@code FileDescriptor} object representing the datagram socket
* file descriptor
*/
protected FileDescriptor getFileDescriptor() {
diff --git a/src/share/classes/java/net/DatagramSocketImplFactory.java b/src/share/classes/java/net/DatagramSocketImplFactory.java
index e89aeb30a6cb62f2b966006af3d141954658f9a5..4d891962ae273d649d07f19bbc581e4e9c43520c 100644
--- a/src/share/classes/java/net/DatagramSocketImplFactory.java
+++ b/src/share/classes/java/net/DatagramSocketImplFactory.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1999, 2002, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -27,7 +27,7 @@ package java.net;
/**
* This interface defines a factory for datagram socket implementations. It
- * is used by the classes DatagramSocket to create actual socket
+ * is used by the classes {@code DatagramSocket} to create actual socket
* implementations.
*
* @author Yingxian Wang
@@ -37,9 +37,9 @@ package java.net;
public
interface DatagramSocketImplFactory {
/**
- * Creates a new DatagramSocketImpl instance.
+ * Creates a new {@code DatagramSocketImpl} instance.
*
- * @return a new instance of DatagramSocketImpl.
+ * @return a new instance of {@code DatagramSocketImpl}.
* @see java.net.DatagramSocketImpl
*/
DatagramSocketImpl createDatagramSocketImpl();
diff --git a/src/share/classes/java/net/FileNameMap.java b/src/share/classes/java/net/FileNameMap.java
index b9bdb6e53e00744533b933e4d07e83eebc108c5e..393b5aa6d9e948c172d048251d37a24d77a1d25c 100644
--- a/src/share/classes/java/net/FileNameMap.java
+++ b/src/share/classes/java/net/FileNameMap.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1996, 1999, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -37,7 +37,7 @@ public interface FileNameMap {
/**
* Gets the MIME type for the specified file name.
* @param fileName the specified file name
- * @return a String indicating the MIME
+ * @return a {@code String} indicating the MIME
* type for the specified file name.
*/
public String getContentTypeFor(String fileName);
diff --git a/src/share/classes/java/net/HttpCookie.java b/src/share/classes/java/net/HttpCookie.java
index d265e284c267ead981ee631fcc7c9dd4101b1f62..fb02ae3e03d195a9373c8f6c68ddff6da5842b58 100644
--- a/src/share/classes/java/net/HttpCookie.java
+++ b/src/share/classes/java/net/HttpCookie.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2005, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -470,7 +470,7 @@ public final class HttpCookie implements Cloneable {
* protocol.
*
* @return {@code false} if the cookie can be sent over any standard
- * protocol; otherwise, true
+ * protocol; otherwise, {@code true}
*
* @see #setSecure
*/
diff --git a/src/share/classes/java/net/HttpRetryException.java b/src/share/classes/java/net/HttpRetryException.java
index 8829c1e90dd556c372bfd5153efae9fec353437f..d498a653f1ce1eca6b7b5e85bc88e69141f0476a 100644
--- a/src/share/classes/java/net/HttpRetryException.java
+++ b/src/share/classes/java/net/HttpRetryException.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2004, 2008, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2004, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -43,7 +43,7 @@ class HttpRetryException extends IOException {
private String location;
/**
- * Constructs a new HttpRetryException from the
+ * Constructs a new {@code HttpRetryException} from the
* specified response code and exception detail message
*
* @param detail the detail message.
@@ -55,7 +55,7 @@ class HttpRetryException extends IOException {
}
/**
- * Constructs a new HttpRetryException with detail message
+ * Constructs a new {@code HttpRetryException} with detail message
* responseCode and the contents of the Location response header field.
*
* @param detail the detail message.
diff --git a/src/share/classes/java/net/HttpURLConnection.java b/src/share/classes/java/net/HttpURLConnection.java
index b93f1e731bd11bb1856a75bd2e992d02915605be..be23241e5a631cb7be4e4dd9c7d7410e44aaa406 100644
--- a/src/share/classes/java/net/HttpURLConnection.java
+++ b/src/share/classes/java/net/HttpURLConnection.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1996, 2011, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -76,14 +76,14 @@ abstract public class HttpURLConnection extends URLConnection {
/**
* The chunk-length when using chunked encoding streaming mode for output.
- * A value of -1 means chunked encoding is disabled for output.
+ * A value of {@code -1} means chunked encoding is disabled for output.
* @since 1.5
*/
protected int chunkLength = -1;
/**
* The fixed content-length when using fixed-length streaming mode.
- * A value of -1 means fixed-length streaming mode is disabled
+ * A value of {@code -1} means fixed-length streaming mode is disabled
* for output.
*
*
NOTE: {@link #fixedContentLengthLong} is recommended instead
@@ -103,15 +103,15 @@ abstract public class HttpURLConnection extends URLConnection {
protected long fixedContentLengthLong = -1;
/**
- * Returns the key for the nth header field.
- * Some implementations may treat the 0th
+ * Returns the key for the {@code n}th header field.
+ * Some implementations may treat the {@code 0}th
* header field as special, i.e. as the status line returned by the HTTP
* server. In this case, {@link #getHeaderField(int) getHeaderField(0)} returns the status
- * line, but getHeaderFieldKey(0) returns null.
+ * line, but {@code getHeaderFieldKey(0)} returns null.
*
* @param n an index, where {@code n >=0}.
- * @return the key for the nth header field,
- * or null if the key does not exist.
+ * @return the key for the {@code n}th header field,
+ * or {@code null} if the key does not exist.
*/
public String getHeaderFieldKey (int n) {
return null;
@@ -251,8 +251,8 @@ abstract public class HttpURLConnection extends URLConnection {
}
/**
- * Returns the value for the nth header field.
- * Some implementations may treat the 0th
+ * Returns the value for the {@code n}th header field.
+ * Some implementations may treat the {@code 0}th
* header field as special, i.e. as the status line returned by the HTTP
* server.
*
@@ -261,8 +261,8 @@ abstract public class HttpURLConnection extends URLConnection {
* the headers in the message.
*
* @param n an index, where {@code n>=0}.
- * @return the value of the nth header field,
- * or null if the value does not exist.
+ * @return the value of the {@code n}th header field,
+ * or {@code null} if the value does not exist.
* @see java.net.HttpURLConnection#getHeaderFieldKey(int)
*/
public String getHeaderField(int n) {
@@ -270,7 +270,7 @@ abstract public class HttpURLConnection extends URLConnection {
}
/**
- * An int representing the three digit HTTP Status-Code.
+ * An {@code int} representing the three digit HTTP Status-Code.
*
true, the protocol will automatically follow redirects.
- * If false, the protocol will not automatically follow
+ * If {@code true}, the protocol will automatically follow redirects.
+ * If {@code false}, the protocol will not automatically follow
* redirects.
*
- * This field is set by the setInstanceFollowRedirects
- * method. Its value is returned by the getInstanceFollowRedirects
+ * This field is set by the {@code setInstanceFollowRedirects}
+ * method. Its value is returned by the {@code getInstanceFollowRedirects}
* method.
*
* Its default value is based on the value of the static followRedirects @@ -328,14 +328,14 @@ abstract public class HttpURLConnection extends URLConnection { * cannot change this variable. *
* If there is a security manager, this method first calls
- * the security manager's checkSetFactory method
+ * the security manager's {@code checkSetFactory} method
* to ensure the operation is allowed.
* This could result in a SecurityException.
*
- * @param set a boolean indicating whether or not
+ * @param set a {@code boolean} indicating whether or not
* to follow HTTP redirects.
* @exception SecurityException if a security manager exists and its
- * checkSetFactory method doesn't
+ * {@code checkSetFactory} method doesn't
* allow the operation.
* @see SecurityManager#checkSetFactory
* @see #getFollowRedirects()
@@ -350,12 +350,12 @@ abstract public class HttpURLConnection extends URLConnection {
}
/**
- * Returns a boolean indicating
+ * Returns a {@code boolean} indicating
* whether or not HTTP redirects (3xx) should
* be automatically followed.
*
- * @return true if HTTP redirects should
- * be automatically followed, false if not.
+ * @return {@code true} if HTTP redirects should
+ * be automatically followed, {@code false} if not.
* @see #setFollowRedirects(boolean)
*/
public static boolean getFollowRedirects() {
@@ -364,13 +364,13 @@ abstract public class HttpURLConnection extends URLConnection {
/**
* Sets whether HTTP redirects (requests with response code 3xx) should
- * be automatically followed by this HttpURLConnection
+ * be automatically followed by this {@code HttpURLConnection}
* instance.
*
* The default value comes from followRedirects, which defaults to
* true.
*
- * @param followRedirects a boolean indicating
+ * @param followRedirects a {@code boolean} indicating
* whether or not to follow HTTP redirects.
*
* @see java.net.HttpURLConnection#instanceFollowRedirects
@@ -382,11 +382,11 @@ abstract public class HttpURLConnection extends URLConnection {
}
/**
- * Returns the value of this HttpURLConnection's
- * instanceFollowRedirects field.
+ * Returns the value of this {@code HttpURLConnection}'s
+ * {@code instanceFollowRedirects} field.
*
- * @return the value of this HttpURLConnection's
- * instanceFollowRedirects field.
+ * @return the value of this {@code HttpURLConnection}'s
+ * {@code instanceFollowRedirects} field.
* @see java.net.HttpURLConnection#instanceFollowRedirects
* @see #setInstanceFollowRedirects(boolean)
* @since 1.3
@@ -540,7 +540,7 @@ abstract public class HttpURLConnection extends URLConnection {
* Returns null if none could be discerned from the responses
* (the result was not valid HTTP).
* @throws IOException if an error occurred connecting to the server.
- * @return the HTTP response message, or null
+ * @return the HTTP response message, or {@code null}
*/
public String getResponseMessage() throws IOException {
getResponseCode();
@@ -583,7 +583,7 @@ abstract public class HttpURLConnection extends URLConnection {
* @exception IOException if an error occurs while computing
* the permission.
*
- * @return a SocketPermission object representing the
+ * @return a {@code SocketPermission} object representing the
* permission necessary to connect to the destination
* host and port.
*/
diff --git a/src/share/classes/java/net/IDN.java b/src/share/classes/java/net/IDN.java
index 563d356804fc53ca1e8334eaf7792620c7ee0a88..0e48155895639aea9aa79fb01890e75c1a0afbc7 100644
--- a/src/share/classes/java/net/IDN.java
+++ b/src/share/classes/java/net/IDN.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -104,7 +104,7 @@ public final class IDN {
* @param input the string to be processed
* @param flag process flag; can be 0 or any logical OR of possible flags
*
- * @return the translated String
+ * @return the translated {@code String}
*
* @throws IllegalArgumentException if the input string doesn't conform to RFC 3490 specification
*/
@@ -130,13 +130,13 @@ public final class IDN {
*
*
This convenience method works as if by invoking the * two-argument counterpart as follows: - *
+ *+ * * * @param input the string to be processed * - * @return the translated String + * @return the translated {@code String} * * @throws IllegalArgumentException if the input string doesn't conform to RFC 3490 specification */ @@ -161,7 +161,7 @@ public final class IDN { * @param input the string to be processed * @param flag process flag; can be 0 or any logical OR of possible flags * - * @return the translated String + * @return the translated {@code String} */ public static String toUnicode(String input, int flag) { int p = 0, q = 0; @@ -184,13 +184,13 @@ public final class IDN { * ** {@link #toASCII(String, int) toASCII}(input, 0); - *
This convenience method works as if by invoking the * two-argument counterpart as follows: - *
+ *+ * * * @param input the string to be processed * - * @return the translated String + * @return the translated {@code String} */ public static String toUnicode(String input) { return toUnicode(input, 0); diff --git a/src/share/classes/java/net/Inet4Address.java b/src/share/classes/java/net/Inet4Address.java index 6c59a692f825933df8d0390a39fc0b050e5dc560..528b27674651f4f7c8d9d6d06346b566f6e5b76d 100644 --- a/src/share/classes/java/net/Inet4Address.java +++ b/src/share/classes/java/net/Inet4Address.java @@ -42,10 +42,10 @@ import java.io.ObjectStreamException; * takes one of the following forms: * ** {@link #toUnicode(String, int) toUnicode}(input, 0); - *
* *- *
- * d.d.d.d - * d.d.d - * d.d + * d + * {@code d.d.d.d} + * {@code d.d.d} + * {@code d.d} * {@code d}
When four parts are specified, each is interpreted as a byte of
@@ -153,7 +153,7 @@ class Inet4Address extends InetAddress {
* Utility routine to check if the InetAddress is an
* IP multicast address. IP multicast address is a Class D
* address i.e first four bits of the address are 1110.
- * @return a boolean indicating if the InetAddress is
+ * @return a {@code boolean} indicating if the InetAddress is
* an IP multicast address
* @since JDK1.1
*/
@@ -163,7 +163,7 @@ class Inet4Address extends InetAddress {
/**
* Utility routine to check if the InetAddress in a wildcard address.
- * @return a boolean indicating if the Inetaddress is
+ * @return a {@code boolean} indicating if the Inetaddress is
* a wildcard address.
* @since 1.4
*/
@@ -174,7 +174,7 @@ class Inet4Address extends InetAddress {
/**
* Utility routine to check if the InetAddress is a loopback address.
*
- * @return a boolean indicating if the InetAddress is
+ * @return a {@code boolean} indicating if the InetAddress is
* a loopback address; or false otherwise.
* @since 1.4
*/
@@ -187,7 +187,7 @@ class Inet4Address extends InetAddress {
/**
* Utility routine to check if the InetAddress is an link local address.
*
- * @return a boolean indicating if the InetAddress is
+ * @return a {@code boolean} indicating if the InetAddress is
* a link local address; or false if address is not a link local unicast address.
* @since 1.4
*/
@@ -204,7 +204,7 @@ class Inet4Address extends InetAddress {
/**
* Utility routine to check if the InetAddress is a site local address.
*
- * @return a boolean indicating if the InetAddress is
+ * @return a {@code boolean} indicating if the InetAddress is
* a site local address; or false if address is not a site local unicast address.
* @since 1.4
*/
@@ -224,7 +224,7 @@ class Inet4Address extends InetAddress {
/**
* Utility routine to check if the multicast address has global scope.
*
- * @return a boolean indicating if the address has
+ * @return a {@code boolean} indicating if the address has
* is a multicast address of global scope, false if it is not
* of global scope or it is not a multicast address
* @since 1.4
@@ -240,7 +240,7 @@ class Inet4Address extends InetAddress {
/**
* Utility routine to check if the multicast address has node scope.
*
- * @return a boolean indicating if the address has
+ * @return a {@code boolean} indicating if the address has
* is a multicast address of node-local scope, false if it is not
* of node-local scope or it is not a multicast address
* @since 1.4
@@ -253,7 +253,7 @@ class Inet4Address extends InetAddress {
/**
* Utility routine to check if the multicast address has link scope.
*
- * @return a boolean indicating if the address has
+ * @return a {@code boolean} indicating if the address has
* is a multicast address of link-local scope, false if it is not
* of link-local scope or it is not a multicast address
* @since 1.4
@@ -269,7 +269,7 @@ class Inet4Address extends InetAddress {
/**
* Utility routine to check if the multicast address has site scope.
*
- * @return a boolean indicating if the address has
+ * @return a {@code boolean} indicating if the address has
* is a multicast address of site-local scope, false if it is not
* of site-local scope or it is not a multicast address
* @since 1.4
@@ -284,7 +284,7 @@ class Inet4Address extends InetAddress {
/**
* Utility routine to check if the multicast address has organization scope.
*
- * @return a boolean indicating if the address has
+ * @return a {@code boolean} indicating if the address has
* is a multicast address of organization-local scope,
* false if it is not of organization-local scope
* or it is not a multicast address
@@ -299,9 +299,9 @@ class Inet4Address extends InetAddress {
}
/**
- * Returns the raw IP address of this InetAddress
+ * Returns the raw IP address of this {@code InetAddress}
* object. The result is in network byte order: the highest order
- * byte of the address is in getAddress()[0].
+ * byte of the address is in {@code getAddress()[0]}.
*
* @return the raw IP address of this object.
*/
@@ -337,18 +337,18 @@ class Inet4Address extends InetAddress {
/**
* Compares this object against the specified object.
- * The result is true if and only if the argument is
- * not null and it represents the same IP address as
+ * The result is {@code true} if and only if the argument is
+ * not {@code null} and it represents the same IP address as
* this object.
*
- * Two instances of InetAddress represent the same IP
+ * Two instances of {@code InetAddress} represent the same IP
* address if the length of the byte arrays returned by
- * getAddress is the same for both, and each of the
+ * {@code getAddress} is the same for both, and each of the
* array components is the same for the byte arrays.
*
* @param obj the object to compare against.
- * @return true if the objects are the same;
- * false otherwise.
+ * @return {@code true} if the objects are the same;
+ * {@code false} otherwise.
* @see java.net.InetAddress#getAddress()
*/
public boolean equals(Object obj) {
diff --git a/src/share/classes/java/net/Inet6Address.java b/src/share/classes/java/net/Inet6Address.java
index 169a180de11b311a12999649fc0ee1a79cd052fa..7b10db96c08b8e6ad68698a0db9b4b025887107a 100644
--- a/src/share/classes/java/net/Inet6Address.java
+++ b/src/share/classes/java/net/Inet6Address.java
@@ -47,7 +47,7 @@ import java.util.Enumeration;
* address. This is the full form. For example,
*
*
* *- *
+ * 1080:0:0:0:8:800:200C:417A * {@code 1080:0:0:0:8:800:200C:417A}
Note that it is not necessary to write the leading zeros in @@ -64,7 +64,7 @@ import java.util.Enumeration; * zeros in an address. For example, * *
* *- *
+ * 1080::8:800:200C:417A * {@code 1080::8:800:200C:417A}
An alternative form that is sometimes more convenient @@ -75,8 +75,8 @@ import java.util.Enumeration; * standard IPv4 representation address, for example, * *
* *- *
- * ::FFFF:129.144.52.38 + * ::129.144.52.38 + * {@code ::FFFF:129.144.52.38} * {@code ::129.144.52.38}
where "::FFFF:d.d.d.d" and "::d.d.d.d" are, respectively, the @@ -85,23 +85,23 @@ import java.util.Enumeration; * in the "d.d.d.d" form. The following forms are invalid: * *
* *- *
- * ::FFFF:d.d.d - * ::FFFF:d.d - * ::d.d.d + * ::d.d + * {@code ::FFFF:d.d.d} + * {@code ::FFFF:d.d} + * {@code ::d.d.d} * {@code ::d.d}
The following form: * *
* *- *
+ * ::FFFF:d * {@code ::FFFF:d}
is valid, however it is an unconventional representation of * the IPv4-compatible IPv6 address, * *
* *- *
+ * ::255.255.0.d * {@code ::255.255.0.d}
while "::d" corresponds to the general IPv6 address
@@ -258,7 +258,7 @@ class Inet6Address extends InetAddress {
* Create an Inet6Address in the exact manner of {@link
* InetAddress#getByAddress(String,byte[])} except that the IPv6 scope_id is
* set to the value corresponding to the given interface for the address
- * type specified in addr. The call will fail with an
+ * type specified in {@code addr}. The call will fail with an
* UnknownHostException if the given interface does not have a numeric
* scope_id assigned for the given address type (eg. link-local or site-local).
* See here for a description of IPv6
diff --git a/src/share/classes/java/net/InetAddress.java b/src/share/classes/java/net/InetAddress.java
index aa5ef16705de5e5cea3df04ab96bfb6deacac5cb..48178497827808821e9bacadbc96e4f7b2e4372b 100644
--- a/src/share/classes/java/net/InetAddress.java
+++ b/src/share/classes/java/net/InetAddress.java
@@ -296,7 +296,7 @@ class InetAddress implements java.io.Serializable {
/**
* Utility routine to check if the InetAddress is an
* IP multicast address.
- * @return a boolean indicating if the InetAddress is
+ * @return a {@code boolean} indicating if the InetAddress is
* an IP multicast address
* @since JDK1.1
*/
@@ -306,7 +306,7 @@ class InetAddress implements java.io.Serializable {
/**
* Utility routine to check if the InetAddress in a wildcard address.
- * @return a boolean indicating if the Inetaddress is
+ * @return a {@code boolean} indicating if the Inetaddress is
* a wildcard address.
* @since 1.4
*/
@@ -317,7 +317,7 @@ class InetAddress implements java.io.Serializable {
/**
* Utility routine to check if the InetAddress is a loopback address.
*
- * @return a boolean indicating if the InetAddress is
+ * @return a {@code boolean} indicating if the InetAddress is
* a loopback address; or false otherwise.
* @since 1.4
*/
@@ -328,7 +328,7 @@ class InetAddress implements java.io.Serializable {
/**
* Utility routine to check if the InetAddress is an link local address.
*
- * @return a boolean indicating if the InetAddress is
+ * @return a {@code boolean} indicating if the InetAddress is
* a link local address; or false if address is not a link local unicast address.
* @since 1.4
*/
@@ -339,7 +339,7 @@ class InetAddress implements java.io.Serializable {
/**
* Utility routine to check if the InetAddress is a site local address.
*
- * @return a boolean indicating if the InetAddress is
+ * @return a {@code boolean} indicating if the InetAddress is
* a site local address; or false if address is not a site local unicast address.
* @since 1.4
*/
@@ -350,7 +350,7 @@ class InetAddress implements java.io.Serializable {
/**
* Utility routine to check if the multicast address has global scope.
*
- * @return a boolean indicating if the address has
+ * @return a {@code boolean} indicating if the address has
* is a multicast address of global scope, false if it is not
* of global scope or it is not a multicast address
* @since 1.4
@@ -362,7 +362,7 @@ class InetAddress implements java.io.Serializable {
/**
* Utility routine to check if the multicast address has node scope.
*
- * @return a boolean indicating if the address has
+ * @return a {@code boolean} indicating if the address has
* is a multicast address of node-local scope, false if it is not
* of node-local scope or it is not a multicast address
* @since 1.4
@@ -374,7 +374,7 @@ class InetAddress implements java.io.Serializable {
/**
* Utility routine to check if the multicast address has link scope.
*
- * @return a boolean indicating if the address has
+ * @return a {@code boolean} indicating if the address has
* is a multicast address of link-local scope, false if it is not
* of link-local scope or it is not a multicast address
* @since 1.4
@@ -386,7 +386,7 @@ class InetAddress implements java.io.Serializable {
/**
* Utility routine to check if the multicast address has site scope.
*
- * @return a boolean indicating if the address has
+ * @return a {@code boolean} indicating if the address has
* is a multicast address of site-local scope, false if it is not
* of site-local scope or it is not a multicast address
* @since 1.4
@@ -398,7 +398,7 @@ class InetAddress implements java.io.Serializable {
/**
* Utility routine to check if the multicast address has organization scope.
*
- * @return a boolean indicating if the address has
+ * @return a {@code boolean} indicating if the address has
* is a multicast address of organization-local scope,
* false if it is not of organization-local scope
* or it is not a multicast address
@@ -424,9 +424,9 @@ class InetAddress implements java.io.Serializable {
* in an IllegalArgumentException being thrown.
*
* @param timeout the time, in milliseconds, before the call aborts
- * @return a boolean indicating if the address is reachable.
+ * @return a {@code boolean} indicating if the address is reachable.
* @throws IOException if a network error occurs
- * @throws IllegalArgumentException if timeout is negative.
+ * @throws IllegalArgumentException if {@code timeout} is negative.
* @since 1.5
*/
public boolean isReachable(int timeout) throws IOException {
@@ -442,10 +442,10 @@ class InetAddress implements java.io.Serializable {
* privilege can be obtained, otherwise it will try to establish
* a TCP connection on port 7 (Echo) of the destination host.
*
- * The network interface and ttl parameters
+ * The {@code network interface} and {@code ttl} parameters
* let the caller specify which network interface the test will go through
* and the maximum number of hops the packets should go through.
- * A negative value for the ttl will result in an
+ * A negative value for the {@code ttl} will result in an
* IllegalArgumentException being thrown.
*
* The timeout value, in milliseconds, indicates the maximum amount of time
@@ -458,9 +458,9 @@ class InetAddress implements java.io.Serializable {
* @param ttl the maximum numbers of hops to try or 0 for the
* default
* @param timeout the time, in milliseconds, before the call aborts
- * @throws IllegalArgumentException if either timeout
- * or ttl are negative.
- * @return a booleanindicating if the address is reachable.
+ * @throws IllegalArgumentException if either {@code timeout}
+ * or {@code ttl} are negative.
+ * @return a {@code boolean}indicating if the address is reachable.
* @throws IOException if a network error occurs
* @since 1.5
*/
@@ -486,8 +486,8 @@ class InetAddress implements java.io.Serializable {
* {@link #getCanonicalHostName() getCanonicalHostName}.
*
*
If there is a security manager, its
- * checkConnect method is first called
- * with the hostname and -1
+ * {@code checkConnect} method is first called
+ * with the hostname and {@code -1}
* as its arguments to see if the operation is allowed.
* If the operation is not allowed, it will return
* the textual representation of the IP address.
@@ -511,8 +511,8 @@ class InetAddress implements java.io.Serializable {
* here without a security check.
*
*
If there is a security manager, this method first
- * calls its checkConnect method
- * with the hostname and -1
+ * calls its {@code checkConnect} method
+ * with the hostname and {@code -1}
* as its arguments to see if the calling code is allowed to know
* the hostname for this IP address, i.e., to connect to the host.
* If the operation is not allowed, it will return
@@ -539,8 +539,8 @@ class InetAddress implements java.io.Serializable {
* the FQDN depending on the underlying system configuration.
*
*
If there is a security manager, this method first
- * calls its checkConnect method
- * with the hostname and -1
+ * calls its {@code checkConnect} method
+ * with the hostname and {@code -1}
* as its arguments to see if the calling code is allowed to know
* the hostname for this IP address, i.e., to connect to the host.
* If the operation is not allowed, it will return
@@ -566,8 +566,8 @@ class InetAddress implements java.io.Serializable {
* Returns the hostname for this address.
*
*
If there is a security manager, this method first
- * calls its checkConnect method
- * with the hostname and -1
+ * calls its {@code checkConnect} method
+ * with the hostname and {@code -1}
* as its arguments to see if the calling code is allowed to know
* the hostname for this IP address, i.e., to connect to the host.
* If the operation is not allowed, it will return
@@ -633,9 +633,9 @@ class InetAddress implements java.io.Serializable {
}
/**
- * Returns the raw IP address of this InetAddress
+ * Returns the raw IP address of this {@code InetAddress}
* object. The result is in network byte order: the highest order
- * byte of the address is in getAddress()[0].
+ * byte of the address is in {@code getAddress()[0]}.
*
* @return the raw IP address of this object.
*/
@@ -664,18 +664,18 @@ class InetAddress implements java.io.Serializable {
/**
* Compares this object against the specified object.
- * The result is true if and only if the argument is
- * not null and it represents the same IP address as
+ * The result is {@code true} if and only if the argument is
+ * not {@code null} and it represents the same IP address as
* this object.
*
- * Two instances of InetAddress represent the same IP
+ * Two instances of {@code InetAddress} represent the same IP
* address if the length of the byte arrays returned by
- * getAddress is the same for both, and each of the
+ * {@code getAddress} is the same for both, and each of the
* array components is the same for the byte arrays.
*
* @param obj the object to compare against.
- * @return true if the objects are the same;
- * false otherwise.
+ * @return {@code true} if the objects are the same;
+ * {@code false} otherwise.
* @see java.net.InetAddress#getAddress()
*/
public boolean equals(Object obj) {
@@ -683,7 +683,7 @@ class InetAddress implements java.io.Serializable {
}
/**
- * Converts this IP address to a String. The
+ * Converts this IP address to a {@code String}. The
* string returned is of the form: hostname / literal IP
* address.
*
@@ -974,7 +974,7 @@ class InetAddress implements java.io.Serializable {
* No name service is checked for the validity of the address.
*
*
The host name can either be a machine name, such as
- * "java.sun.com", or a textual representation of its IP
+ * "{@code java.sun.com}", or a textual representation of its IP
* address.
*
No validity checking is done on the host name either. * @@ -1019,26 +1019,26 @@ class InetAddress implements java.io.Serializable { * Determines the IP address of a host, given the host's name. * *
The host name can either be a machine name, such as
- * "java.sun.com", or a textual representation of its
+ * "{@code java.sun.com}", or a textual representation of its
* IP address. If a literal IP address is supplied, only the
* validity of the address format is checked.
*
- *
For host specified in literal IPv6 address,
+ *
For {@code host} specified in literal IPv6 address, * either the form defined in RFC 2732 or the literal IPv6 address * format defined in RFC 2373 is accepted. IPv6 scoped addresses are also * supported. See here for a description of IPv6 * scoped addresses. * - *
If the host is null then an InetAddress + *
If the host is {@code null} then an {@code InetAddress} * representing an address of the loopback interface is returned. * See RFC 3330 * section 2 and RFC 2373 * section 2.5.3.
* - * @param host the specified host, ornull.
+ * @param host the specified host, or {@code null}.
* @return an IP address for the given host name.
* @exception UnknownHostException if no IP address for the
- * host could be found, or if a scope_id was specified
+ * {@code host} could be found, or if a scope_id was specified
* for a global IPv6 address.
* @exception SecurityException if a security manager exists
* and its checkConnect method doesn't allow the operation
@@ -1059,37 +1059,37 @@ class InetAddress implements java.io.Serializable {
* based on the configured name service on the system.
*
* The host name can either be a machine name, such as
- * "java.sun.com", or a textual representation of its IP
+ * "{@code java.sun.com}", or a textual representation of its IP
* address. If a literal IP address is supplied, only the
* validity of the address format is checked.
*
- *
For host specified in literal IPv6 address,
+ *
For {@code host} specified in literal IPv6 address, * either the form defined in RFC 2732 or the literal IPv6 address * format defined in RFC 2373 is accepted. A literal IPv6 address may * also be qualified by appending a scoped zone identifier or scope_id. * The syntax and usage of scope_ids is described * here. - *
If the host is null then an InetAddress + *
If the host is {@code null} then an {@code InetAddress} * representing an address of the loopback interface is returned. * See RFC 3330 * section 2 and RFC 2373 * section 2.5.3.
* - * If there is a security manager and host is not
- * null and host.length() is not equal to zero, the
+ *
If there is a security manager and {@code host} is not
+ * null and {@code host.length() } is not equal to zero, the
* security manager's
- * checkConnect method is called
- * with the hostname and -1
+ * {@code checkConnect} method is called
+ * with the hostname and {@code -1}
* as its arguments to see if the operation is allowed.
*
- * @param host the name of the host, or null.
+ * @param host the name of the host, or {@code null}.
* @return an array of all the IP addresses for a given host name.
*
* @exception UnknownHostException if no IP address for the
- * host could be found, or if a scope_id was specified
+ * {@code host} could be found, or if a scope_id was specified
* for a global IPv6 address.
* @exception SecurityException if a security manager exists and its
- * checkConnect method doesn't allow the operation.
+ * {@code checkConnect} method doesn't allow the operation.
*
* @see SecurityManager#checkConnect
*/
@@ -1389,9 +1389,9 @@ class InetAddress implements java.io.Serializable {
}
/**
- * Returns an InetAddress object given the raw IP address .
+ * Returns an {@code InetAddress} object given the raw IP address .
* The argument is in network byte order: the highest order
- * byte of the address is in getAddress()[0].
+ * byte of the address is in {@code getAddress()[0]}.
*
*
This method doesn't block, i.e. no reverse name service lookup
* is performed.
@@ -1417,14 +1417,14 @@ class InetAddress implements java.io.Serializable {
/**
* Returns the address of the local host. This is achieved by retrieving
* the name of the host from the system, then resolving that name into
- * an InetAddress.
+ * an {@code InetAddress}.
*
*
Note: The resolved address may be cached for a short period of time. *
* *If there is a security manager, its
- * checkConnect method is called
- * with the local host name and -1
+ * {@code checkConnect} method is called
+ * with the local host name and {@code -1}
* as its arguments to see if the operation is allowed.
* If the operation is not allowed, an InetAddress representing
* the loopback address is returned.
@@ -1601,7 +1601,6 @@ class InetAddress implements java.io.Serializable {
pf.put("address", holder().getAddress());
pf.put("family", holder().getFamily());
s.writeFields();
- s.flush();
}
}
diff --git a/src/share/classes/java/net/InetSocketAddress.java b/src/share/classes/java/net/InetSocketAddress.java
index 44604c664aa42f2c8ac3f2984aa119756c7f8126..6792979312b093cc1eda1c4b7abaec0a35ddc7eb 100644
--- a/src/share/classes/java/net/InetSocketAddress.java
+++ b/src/share/classes/java/net/InetSocketAddress.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2000, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -43,7 +43,7 @@ import java.io.ObjectStreamField;
* as returned values.
*
* The wildcard is a special local IP address. It usually means "any"
- * and can only be used for bind operations.
+ * and can only be used for {@code bind} operations.
*
* @see java.net.Socket
* @see java.net.ServerSocket
@@ -155,8 +155,8 @@ public class InetSocketAddress
* and the port number a specified value.
*
* A valid port value is between 0 and 65535.
- * A port number of zero will let the system pick up an
- * ephemeral port in a bind operation.
+ * A port number of {@code zero} will let the system pick up an
+ * ephemeral port in a {@code bind} operation.
*
* @param port The port number * @throws IllegalArgumentException if the port parameter is outside the specified @@ -171,10 +171,10 @@ public class InetSocketAddress * Creates a socket address from an IP address and a port number. *
* A valid port value is between 0 and 65535.
- * A port number of zero will let the system pick up an
- * ephemeral port in a bind operation.
+ * A port number of {@code zero} will let the system pick up an
+ * ephemeral port in a {@code bind} operation.
*
- * A null address will assign the wildcard address.
+ * A {@code null} address will assign the wildcard address.
*
* @param addr The IP address * @param port The port number @@ -195,13 +195,13 @@ public class InetSocketAddress * An attempt will be made to resolve the hostname into an InetAddress. * If that attempt fails, the address will be flagged as unresolved. *
- * If there is a security manager, its checkConnect method
+ * If there is a security manager, its {@code checkConnect} method
* is called with the host name as its argument to check the permissiom
* to resolve it. This could result in a SecurityException.
*
* A valid port value is between 0 and 65535.
- * A port number of zero will let the system pick up an
- * ephemeral port in a bind operation.
+ * A port number of {@code zero} will let the system pick up an
+ * ephemeral port in a {@code bind} operation.
*
* @param hostname the Host name * @param port The port number @@ -237,8 +237,8 @@ public class InetSocketAddress * The address will be flagged as unresolved. *
* A valid port value is between 0 and 65535.
- * A port number of zero will let the system pick up an
- * ephemeral port in a bind operation.
+ * A port number of {@code zero} will let the system pick up an
+ * ephemeral port in a {@code bind} operation.
*
* @param host the Host name
* @param port The port number
@@ -246,7 +246,7 @@ public class InetSocketAddress
* the range of valid port values, or if the hostname
* parameter is null.
* @see #isUnresolved()
- * @return a InetSocketAddress representing the unresolved
+ * @return a {@code InetSocketAddress} representing the unresolved
* socket address
* @since 1.5
*/
@@ -326,16 +326,16 @@ public class InetSocketAddress
/**
*
- * Gets the InetAddress.
+ * Gets the {@code InetAddress}.
*
- * @return the InetAdress or null if it is unresolved.
+ * @return the InetAdress or {@code null} if it is unresolved.
*/
public final InetAddress getAddress() {
return holder.getAddress();
}
/**
- * Gets the hostname.
+ * Gets the {@code hostname}.
* Note: This method may trigger a name service reverse lookup if the
* address was created with a literal IP address.
*
@@ -360,8 +360,8 @@ public class InetSocketAddress
/**
* Checks whether the address has been resolved or not.
*
- * @return true if the hostname couldn't be resolved into
- * an InetAddress.
+ * @return {@code true} if the hostname couldn't be resolved into
+ * an {@code InetAddress}.
*/
public final boolean isUnresolved() {
return holder.isUnresolved();
@@ -382,11 +382,11 @@ public class InetSocketAddress
/**
* Compares this object against the specified object.
- * The result is true if and only if the argument is
- * not null and it represents the same address as
+ * The result is {@code true} if and only if the argument is
+ * not {@code null} and it represents the same address as
* this object.
*
- * Two instances of InetSocketAddress represent the same
+ * Two instances of {@code InetSocketAddress} represent the same
* address if both the InetAddresses (or hostnames if it is unresolved) and port
* numbers are equal.
* If both addresses are unresolved, then the hostname and the port number
@@ -396,8 +396,8 @@ public class InetSocketAddress
* considered equal.
*
* @param obj the object to compare against.
- * @return true if the objects are the same;
- * false otherwise.
+ * @return {@code true} if the objects are the same;
+ * {@code false} otherwise.
* @see java.net.InetAddress#equals(java.lang.Object)
*/
@Override
diff --git a/src/share/classes/java/net/InterfaceAddress.java b/src/share/classes/java/net/InterfaceAddress.java
index 1fb18ae0f6c8875b3cd1cdc36f736a260e1138fa..704e1fae9d5d222ab37c5685a8de0ae7ef59f6e6 100644
--- a/src/share/classes/java/net/InterfaceAddress.java
+++ b/src/share/classes/java/net/InterfaceAddress.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2005, 2008, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -47,23 +47,23 @@ public class InterfaceAddress {
}
/**
- * Returns an InetAddress for this address.
+ * Returns an {@code InetAddress} for this address.
*
- * @return the InetAddress for this address.
+ * @return the {@code InetAddress} for this address.
*/
public InetAddress getAddress() {
return address;
}
/**
- * Returns an InetAddress for the brodcast address
+ * Returns an {@code InetAddress} for the brodcast address
* for this InterfaceAddress.
*
* Only IPv4 networks have broadcast address therefore, in the case
- * of an IPv6 network, null will be returned.
+ * of an IPv6 network, {@code null} will be returned.
*
- * @return the InetAddress representing the broadcast
- * address or null if there is no broadcast address.
+ * @return the {@code InetAddress} representing the broadcast
+ * address or {@code null} if there is no broadcast address.
*/
public InetAddress getBroadcast() {
return broadcast;
@@ -76,7 +76,7 @@ public class InterfaceAddress {
* or 24 (255.255.255.0).
* Typical IPv6 values would be 128 (::1/128) or 10 (fe80::203:baff:fe27:1243/10)
*
- * @return a short representing the prefix length for the
+ * @return a {@code short} representing the prefix length for the
* subnet of that address.
*/
public short getNetworkPrefixLength() {
@@ -85,17 +85,17 @@ public class InterfaceAddress {
/**
* Compares this object against the specified object.
- * The result is true if and only if the argument is
- * not null and it represents the same interface address as
+ * The result is {@code true} if and only if the argument is
+ * not {@code null} and it represents the same interface address as
* this object.
*
- * Two instances of InterfaceAddress represent the same
+ * Two instances of {@code InterfaceAddress} represent the same
* address if the InetAddress, the prefix length and the broadcast are
* the same for both.
*
* @param obj the object to compare against.
- * @return true if the objects are the same;
- * false otherwise.
+ * @return {@code true} if the objects are the same;
+ * {@code false} otherwise.
* @see java.net.InterfaceAddress#hashCode()
*/
public boolean equals(Object obj) {
@@ -122,7 +122,7 @@ public class InterfaceAddress {
}
/**
- * Converts this Interface address to a String. The
+ * Converts this Interface address to a {@code String}. The
* string returned is of the form: InetAddress / prefix length [ broadcast address ].
*
* @return a string representation of this Interface address.
diff --git a/src/share/classes/java/net/JarURLConnection.java b/src/share/classes/java/net/JarURLConnection.java
index 433be8cfdb930874edfc3eddfb210ffadd6705c8..c6fd8cf94f7355530a55db9bc5910f54f7783033 100644
--- a/src/share/classes/java/net/JarURLConnection.java
+++ b/src/share/classes/java/net/JarURLConnection.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 2006, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -45,18 +45,14 @@ import sun.net.www.ParseUtil;
*
*
for example: * - *
- * jar:http://www.foo.com/bar/baz.jar!/COM/foo/Quux.class
+ *
- *
{@code jar:http://www.foo.com/bar/baz.jar!/COM/foo/Quux.class} * *
Jar URLs should be used to refer to a JAR file or entries in
* a JAR file. The example above is a JAR URL which refers to a JAR
* entry. If the entry name is omitted, the URL refers to the whole
* JAR file:
*
- *
- * jar:http://www.foo.com/bar/baz.jar!/
- *
+ * {@code jar:http://www.foo.com/bar/baz.jar!/}
*
*
Users should cast the generic URLConnection to a * JarURLConnection when they know that the URL they created is a JAR @@ -76,19 +72,19 @@ import sun.net.www.ParseUtil; *
jar:http://www.foo.com/bar/baz.jar!/COM/foo/Quux.class
+ * jar:http://www.foo.com/bar/baz.jar!/
+ * jar:http://www.foo.com/bar/baz.jar!/COM/foo/
+ * !/ is refered to as the separator.
+ *
{@code !/} is refered to as the separator. * - *
When constructing a JAR url via new URL(context, spec),
+ *
When constructing a JAR url via {@code new URL(context, spec)}, * the following rules apply: * *
null
+ * reached. Otherwise, this method will return {@code null}
*
* @return the Certificate object for this connection if the URL
* for it points to a JAR file entry, null otherwise.
diff --git a/src/share/classes/java/net/MalformedURLException.java b/src/share/classes/java/net/MalformedURLException.java
index f6ed89219fa70ab15f51b84a41e5364c59308c5b..7aef75c78214d71c7f75dbfd61019c1d4f734f85 100644
--- a/src/share/classes/java/net/MalformedURLException.java
+++ b/src/share/classes/java/net/MalformedURLException.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 2008, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -39,13 +39,13 @@ public class MalformedURLException extends IOException {
private static final long serialVersionUID = -182787522200415866L;
/**
- * Constructs a MalformedURLException with no detail message.
+ * Constructs a {@code MalformedURLException} with no detail message.
*/
public MalformedURLException() {
}
/**
- * Constructs a MalformedURLException with the
+ * Constructs a {@code MalformedURLException} with the
* specified detail message.
*
* @param msg the detail message.
diff --git a/src/share/classes/java/net/MulticastSocket.java b/src/share/classes/java/net/MulticastSocket.java
index 0a4d7c1023d76438989e7c85fd1194818c9eaf38..9c5cb05acbb9427168bb927705c53140ff45e1bc 100644
--- a/src/share/classes/java/net/MulticastSocket.java
+++ b/src/share/classes/java/net/MulticastSocket.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -92,7 +92,7 @@ class MulticastSocket extends DatagramSocket {
* Create a multicast socket.
*
* If there is a security manager,
- * its checkListen method is first called
+ * its {@code checkListen} method is first called
* with 0 as its argument to ensure the operation is allowed.
* This could result in a SecurityException.
*
@@ -103,7 +103,7 @@ class MulticastSocket extends DatagramSocket {
* @exception IOException if an I/O exception occurs
* while creating the MulticastSocket
* @exception SecurityException if a security manager exists and its
- * checkListen method doesn't allow the operation.
+ * {@code checkListen} method doesn't allow the operation.
* @see SecurityManager#checkListen
* @see java.net.DatagramSocket#setReuseAddress(boolean)
*/
@@ -115,8 +115,8 @@ class MulticastSocket extends DatagramSocket {
* Create a multicast socket and bind it to a specific port.
*
*
If there is a security manager,
- * its checkListen method is first called
- * with the port argument
+ * its {@code checkListen} method is first called
+ * with the {@code port} argument
* as its argument to ensure the operation is allowed.
* This could result in a SecurityException.
*
@@ -128,7 +128,7 @@ class MulticastSocket extends DatagramSocket {
* @exception IOException if an I/O exception occurs
* while creating the MulticastSocket
* @exception SecurityException if a security manager exists and its
- * checkListen method doesn't allow the operation.
+ * {@code checkListen} method doesn't allow the operation.
* @see SecurityManager#checkListen
* @see java.net.DatagramSocket#setReuseAddress(boolean)
*/
@@ -139,10 +139,10 @@ class MulticastSocket extends DatagramSocket {
/**
* Create a MulticastSocket bound to the specified socket address.
*
- * Or, if the address is null, create an unbound socket.
+ * Or, if the address is {@code null}, create an unbound socket.
*
*
If there is a security manager,
- * its checkListen method is first called
+ * its {@code checkListen} method is first called
* with the SocketAddress port as its argument to ensure the operation is allowed.
* This could result in a SecurityException.
*
@@ -150,12 +150,12 @@ class MulticastSocket extends DatagramSocket {
* {@link DatagramSocket#setReuseAddress(boolean)} method is
* called to enable the SO_REUSEADDR socket option.
*
- * @param bindaddr Socket address to bind to, or null for
+ * @param bindaddr Socket address to bind to, or {@code null} for
* an unbound socket.
* @exception IOException if an I/O exception occurs
* while creating the MulticastSocket
* @exception SecurityException if a security manager exists and its
- * checkListen method doesn't allow the operation.
+ * {@code checkListen} method doesn't allow the operation.
* @see SecurityManager#checkListen
* @see java.net.DatagramSocket#setReuseAddress(boolean)
*
@@ -197,7 +197,7 @@ class MulticastSocket extends DatagramSocket {
/**
* Set the default time-to-live for multicast packets sent out
- * on this MulticastSocket in order to control the
+ * on this {@code MulticastSocket} in order to control the
* scope of the multicasts.
*
*
The ttl is an unsigned 8-bit quantity, and so must be
@@ -279,11 +279,11 @@ class MulticastSocket extends DatagramSocket {
/**
* Joins a multicast group. Its behavior may be affected by
- * setInterface or setNetworkInterface.
+ * {@code setInterface} or {@code setNetworkInterface}.
*
*
If there is a security manager, this method first
- * calls its checkMulticast method
- * with the mcastaddr argument
+ * calls its {@code checkMulticast} method
+ * with the {@code mcastaddr} argument
* as its argument.
*
* @param mcastaddr is the multicast address to join
@@ -291,7 +291,7 @@ class MulticastSocket extends DatagramSocket {
* @exception IOException if there is an error joining
* or when the address is not a multicast address.
* @exception SecurityException if a security manager exists and its
- * checkMulticast method doesn't allow the join.
+ * {@code checkMulticast} method doesn't allow the join.
*
* @see SecurityManager#checkMulticast(InetAddress)
*/
@@ -325,18 +325,18 @@ class MulticastSocket extends DatagramSocket {
/**
* Leave a multicast group. Its behavior may be affected by
- * setInterface or setNetworkInterface.
+ * {@code setInterface} or {@code setNetworkInterface}.
*
*
If there is a security manager, this method first
- * calls its checkMulticast method
- * with the mcastaddr argument
+ * calls its {@code checkMulticast} method
+ * with the {@code mcastaddr} argument
* as its argument.
*
* @param mcastaddr is the multicast address to leave
* @exception IOException if there is an error leaving
* or when the address is not a multicast address.
* @exception SecurityException if a security manager exists and its
- * checkMulticast method doesn't allow the operation.
+ * {@code checkMulticast} method doesn't allow the operation.
*
* @see SecurityManager#checkMulticast(InetAddress)
*/
@@ -362,8 +362,8 @@ class MulticastSocket extends DatagramSocket {
* Joins the specified multicast group at the specified interface.
*
*
If there is a security manager, this method first
- * calls its checkMulticast method
- * with the mcastaddr argument
+ * calls its {@code checkMulticast} method
+ * with the {@code mcastaddr} argument
* as its argument.
*
* @param mcastaddr is the multicast address to join
@@ -375,7 +375,7 @@ class MulticastSocket extends DatagramSocket {
* @exception IOException if there is an error joining
* or when the address is not a multicast address.
* @exception SecurityException if a security manager exists and its
- * checkMulticast method doesn't allow the join.
+ * {@code checkMulticast} method doesn't allow the join.
* @throws IllegalArgumentException if mcastaddr is null or is a
* SocketAddress subclass not supported by this socket
*
@@ -410,8 +410,8 @@ class MulticastSocket extends DatagramSocket {
* Leave a multicast group on a specified local interface.
*
*
If there is a security manager, this method first
- * calls its checkMulticast method
- * with the mcastaddr argument
+ * calls its {@code checkMulticast} method
+ * with the {@code mcastaddr} argument
* as its argument.
*
* @param mcastaddr is the multicast address to leave
@@ -422,7 +422,7 @@ class MulticastSocket extends DatagramSocket {
* @exception IOException if there is an error leaving
* or when the address is not a multicast address.
* @exception SecurityException if a security manager exists and its
- * checkMulticast method doesn't allow the operation.
+ * {@code checkMulticast} method doesn't allow the operation.
* @throws IllegalArgumentException if mcastaddr is null or is a
* SocketAddress subclass not supported by this socket
*
@@ -478,7 +478,7 @@ class MulticastSocket extends DatagramSocket {
* Retrieve the address of the network interface used for
* multicast packets.
*
- * @return An InetAddress representing
+ * @return An {@code InetAddress} representing
* the address of the network interface used for
* multicast packets.
*
@@ -562,7 +562,7 @@ class MulticastSocket extends DatagramSocket {
*
* @exception SocketException if there is an error in
* the underlying protocol, such as a TCP error.
- * @return the multicast NetworkInterface currently set
+ * @return the multicast {@code NetworkInterface} currently set
* @see #setNetworkInterface(NetworkInterface)
* @since 1.4
*/
@@ -587,7 +587,7 @@ class MulticastSocket extends DatagramSocket {
*
Because this option is a hint, applications that want to
* verify what loopback mode is set to should call
* {@link #getLoopbackMode()}
- * @param disable true to disable the LoopbackMode
+ * @param disable {@code true} to disable the LoopbackMode
* @throws SocketException if an error occurs while setting the value
* @since 1.4
* @see #getLoopbackMode
@@ -615,18 +615,18 @@ class MulticastSocket extends DatagramSocket {
* otherwise it is preferable to set a TTL once on the socket, and
* use that default TTL for all packets. This method does not
* alter the default TTL for the socket. Its behavior may be
- * affected by setInterface.
+ * affected by {@code setInterface}.
*
*
If there is a security manager, this method first performs some
- * security checks. First, if p.getAddress().isMulticastAddress()
+ * security checks. First, if {@code p.getAddress().isMulticastAddress()}
* is true, this method calls the
- * security manager's checkMulticast method
- * with p.getAddress() and ttl as its arguments.
+ * security manager's {@code checkMulticast} method
+ * with {@code p.getAddress()} and {@code ttl} as its arguments.
* If the evaluation of that expression is false,
* this method instead calls the security manager's
- * checkConnect method with arguments
- * p.getAddress().getHostAddress() and
- * p.getPort(). Each call to a security manager method
+ * {@code checkConnect} method with arguments
+ * {@code p.getAddress().getHostAddress()} and
+ * {@code p.getPort()}. Each call to a security manager method
* could result in a SecurityException if the operation is not allowed.
*
* @param p is the packet to be sent. The packet should contain
@@ -639,7 +639,7 @@ class MulticastSocket extends DatagramSocket {
* @exception IOException is raised if an error occurs i.e
* error while setting ttl.
* @exception SecurityException if a security manager exists and its
- * checkMulticast or checkConnect
+ * {@code checkMulticast} or {@code checkConnect}
* method doesn't allow the send.
*
* @deprecated Use the following code or its equivalent instead:
diff --git a/src/share/classes/java/net/NetPermission.java b/src/share/classes/java/net/NetPermission.java
index f11337e5b9ef76fa92474384e02a54239cdcb63c..cf7cbd2af67db617a19fb11a6b768f9186ced3f8 100644
--- a/src/share/classes/java/net/NetPermission.java
+++ b/src/share/classes/java/net/NetPermission.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -177,8 +177,8 @@ public final class NetPermission extends BasicPermission {
*
* @param name the name of the NetPermission.
*
- * @throws NullPointerException if name is null.
- * @throws IllegalArgumentException if name is empty.
+ * @throws NullPointerException if {@code name} is {@code null}.
+ * @throws IllegalArgumentException if {@code name} is empty.
*/
public NetPermission(String name)
@@ -194,8 +194,8 @@ public final class NetPermission extends BasicPermission {
* @param name the name of the NetPermission.
* @param actions should be null.
*
- * @throws NullPointerException if name is null.
- * @throws IllegalArgumentException if name is empty.
+ * @throws NullPointerException if {@code name} is {@code null}.
+ * @throws IllegalArgumentException if {@code name} is empty.
*/
public NetPermission(String name, String actions)
diff --git a/src/share/classes/java/net/NetworkInterface.java b/src/share/classes/java/net/NetworkInterface.java
index c1644dea2bc5f8124cf11eb50d194df8979c2323..411d8df14b9d14e9b28eb09f1b172600758417aa 100644
--- a/src/share/classes/java/net/NetworkInterface.java
+++ b/src/share/classes/java/net/NetworkInterface.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2000, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -98,9 +98,9 @@ public final class NetworkInterface {
* Convenience method to return an Enumeration with all or a
* subset of the InetAddresses bound to this network interface.
*
- * If there is a security manager, its checkConnect
+ * If there is a security manager, its {@code checkConnect}
* method is called for each InetAddress. Only InetAddresses where
- * the checkConnect doesn't throw a SecurityException
+ * the {@code checkConnect} doesn't throw a SecurityException
* will be returned in the Enumeration. However, if the caller has the
* {@link NetPermission}("getNetworkInformation") permission, then all
* InetAddresses are returned.
@@ -154,15 +154,15 @@ public final class NetworkInterface {
}
/**
- * Get a List of all or a subset of the InterfaceAddresses
+ * Get a List of all or a subset of the {@code InterfaceAddresses}
* of this network interface.
*
- * If there is a security manager, its checkConnect
+ * If there is a security manager, its {@code checkConnect}
* method is called with the InetAddress for each InterfaceAddress.
- * Only InterfaceAddresses where the checkConnect doesn't throw
+ * Only InterfaceAddresses where the {@code checkConnect} doesn't throw
* a SecurityException will be returned in the List.
*
- * @return a List object with all or a subset of the
+ * @return a {@code List} object with all or a subset of the
* InterfaceAddresss of this network interface
* @since 1.6
*/
@@ -216,10 +216,10 @@ public final class NetworkInterface {
/**
* Returns the parent NetworkInterface of this interface if this is
- * a subinterface, or null if it is a physical
+ * a subinterface, or {@code null} if it is a physical
* (non virtual) interface or has no parent.
*
- * @return The NetworkInterface this interface is attached to.
+ * @return The {@code NetworkInterface} this interface is attached to.
* @since 1.6
*/
public NetworkInterface getParent() {
@@ -260,15 +260,15 @@ public final class NetworkInterface {
* @param name
* The name of the network interface.
*
- * @return A NetworkInterface with the specified name,
- * or null if there is no network interface
+ * @return A {@code NetworkInterface} with the specified name,
+ * or {@code null} if there is no network interface
* with the specified name.
*
* @throws SocketException
* If an I/O error occurs.
*
* @throws NullPointerException
- * If the specified name is null.
+ * If the specified name is {@code null}.
*/
public static NetworkInterface getByName(String name) throws SocketException {
if (name == null)
@@ -303,17 +303,17 @@ public final class NetworkInterface {
* returned.
*
* @param addr
- * The InetAddress to search with.
+ * The {@code InetAddress} to search with.
*
- * @return A NetworkInterface
- * or null if there is no network interface
+ * @return A {@code NetworkInterface}
+ * or {@code null} if there is no network interface
* with the specified IP address.
*
* @throws SocketException
* If an I/O error occurs.
*
* @throws NullPointerException
- * If the specified address is null.
+ * If the specified address is {@code null}.
*/
public static NetworkInterface getByInetAddress(InetAddress addr) throws SocketException {
if (addr == null) {
@@ -378,7 +378,7 @@ public final class NetworkInterface {
/**
* Returns whether a network interface is up and running.
*
- * @return true if the interface is up and running.
+ * @return {@code true} if the interface is up and running.
* @exception SocketException if an I/O error occurs.
* @since 1.6
*/
@@ -390,7 +390,7 @@ public final class NetworkInterface {
/**
* Returns whether a network interface is a loopback interface.
*
- * @return true if the interface is a loopback interface.
+ * @return {@code true} if the interface is a loopback interface.
* @exception SocketException if an I/O error occurs.
* @since 1.6
*/
@@ -404,7 +404,7 @@ public final class NetworkInterface {
* A typical point to point interface would be a PPP connection through
* a modem.
*
- * @return true if the interface is a point to point
+ * @return {@code true} if the interface is a point to point
* interface.
* @exception SocketException if an I/O error occurs.
* @since 1.6
@@ -417,7 +417,7 @@ public final class NetworkInterface {
/**
* Returns whether a network interface supports multicasting or not.
*
- * @return true if the interface supports Multicasting.
+ * @return {@code true} if the interface supports Multicasting.
* @exception SocketException if an I/O error occurs.
* @since 1.6
*/
@@ -432,7 +432,7 @@ public final class NetworkInterface {
* If a security manager is set, then the caller must have
* the permission {@link NetPermission}("getNetworkInformation").
*
- * @return a byte array containing the address, or null if
+ * @return a byte array containing the address, or {@code null} if
* the address doesn't exist, is not accessible or a security
* manager is set and the caller does not have the permission
* NetPermission("getNetworkInformation")
@@ -481,7 +481,7 @@ public final class NetworkInterface {
* can be several virtual interfaces attached to a single physical
* interface.
*
- * @return true if this interface is a virtual interface.
+ * @return {@code true} if this interface is a virtual interface.
* @since 1.6
*/
public boolean isVirtual() {
@@ -497,16 +497,16 @@ public final class NetworkInterface {
/**
* Compares this object against the specified object.
- * The result is true if and only if the argument is
- * not null and it represents the same NetworkInterface
+ * The result is {@code true} if and only if the argument is
+ * not {@code null} and it represents the same NetworkInterface
* as this object.
*
- * Two instances of NetworkInterface represent the same
+ * Two instances of {@code NetworkInterface} represent the same
* NetworkInterface if both name and addrs are the same for both.
*
* @param obj the object to compare against.
- * @return true if the objects are the same;
- * false otherwise.
+ * @return {@code true} if the objects are the same;
+ * {@code false} otherwise.
* @see java.net.InetAddress#getAddress()
*/
public boolean equals(Object obj) {
diff --git a/src/share/classes/java/net/PasswordAuthentication.java b/src/share/classes/java/net/PasswordAuthentication.java
index ee2280fc730af5c3df35de6bee90af8441f18edb..5529568f3a314835216bcef381bde9fa8e0879f9 100644
--- a/src/share/classes/java/net/PasswordAuthentication.java
+++ b/src/share/classes/java/net/PasswordAuthentication.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 2001, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -43,11 +43,11 @@ public final class PasswordAuthentication {
private char[] password;
/**
- * Creates a new PasswordAuthentication object from the given
+ * Creates a new {@code PasswordAuthentication} object from the given
* user name and password.
*
*
Note that the given user password is cloned before it is stored in
- * the new PasswordAuthentication object.
+ * the new {@code PasswordAuthentication} object.
*
* @param userName the user name
* @param password the user's password
diff --git a/src/share/classes/java/net/PortUnreachableException.java b/src/share/classes/java/net/PortUnreachableException.java
index c21345fb7d9951f002cba8db9152dcbb9c783ed9..8d1f21b0e87957848222bb68bec2b805c7157620 100644
--- a/src/share/classes/java/net/PortUnreachableException.java
+++ b/src/share/classes/java/net/PortUnreachableException.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2001, 2008, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -36,7 +36,7 @@ public class PortUnreachableException extends SocketException {
private static final long serialVersionUID = 8462541992376507323L;
/**
- * Constructs a new PortUnreachableException with a
+ * Constructs a new {@code PortUnreachableException} with a
* detail message.
* @param msg the detail message
*/
@@ -45,7 +45,7 @@ public class PortUnreachableException extends SocketException {
}
/**
- * Construct a new PortUnreachableException with no
+ * Construct a new {@code PortUnreachableException} with no
* detailed message.
*/
public PortUnreachableException() {}
diff --git a/src/share/classes/java/net/ProtocolException.java b/src/share/classes/java/net/ProtocolException.java
index 74ff4f1322e932586ab8a3dbef14fca56f812b0e..ebb94eb16ca3c0e743dcef8eb7cc572f7dcdbf12 100644
--- a/src/share/classes/java/net/ProtocolException.java
+++ b/src/share/classes/java/net/ProtocolException.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 2008, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -39,7 +39,7 @@ class ProtocolException extends IOException {
private static final long serialVersionUID = -6098449442062388080L;
/**
- * Constructs a new ProtocolException with the
+ * Constructs a new {@code ProtocolException} with the
* specified detail message.
*
* @param host the detail message.
@@ -49,7 +49,7 @@ class ProtocolException extends IOException {
}
/**
- * Constructs a new ProtocolException with no detail message.
+ * Constructs a new {@code ProtocolException} with no detail message.
*/
public ProtocolException() {
}
diff --git a/src/share/classes/java/net/Proxy.java b/src/share/classes/java/net/Proxy.java
index 4b8b6f148d57eb2c6794290700ab82b5b6d5e14b..fe481fadfa2523ec9420eeba8a8ce32f0ef9121a 100644
--- a/src/share/classes/java/net/Proxy.java
+++ b/src/share/classes/java/net/Proxy.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2003, 2011, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -28,7 +28,7 @@ package java.net;
/**
* This class represents a proxy setting, typically a type (http, socks) and
* a socket address.
- * A Proxy is an immutable object.
+ * A {@code Proxy} is an immutable object.
*
* @see java.net.ProxySelector
* @author Yingxian Wang
@@ -61,17 +61,17 @@ public class Proxy {
private SocketAddress sa;
/**
- * A proxy setting that represents a DIRECT connection,
+ * A proxy setting that represents a {@code DIRECT} connection,
* basically telling the protocol handler not to use any proxying.
* Used, for instance, to create sockets bypassing any other global
* proxy settings (like SOCKS):
*
- * Socket s = new Socket(Proxy.NO_PROXY);
+ * {@code Socket s = new Socket(Proxy.NO_PROXY);}
*
*/
public final static Proxy NO_PROXY = new Proxy();
- // Creates the proxy that represents a DIRECT connection.
+ // Creates the proxy that represents a {@code DIRECT} connection.
private Proxy() {
type = Type.DIRECT;
sa = null;
@@ -82,11 +82,11 @@ public class Proxy {
* Certain combinations are illegal. For instance, for types Http, and
* Socks, a SocketAddress must be provided.
*
- * Use the Proxy.NO_PROXY constant
+ * Use the {@code Proxy.NO_PROXY} constant
* for representing a direct connection.
*
- * @param type the Type of the proxy
- * @param sa the SocketAddress for that proxy
+ * @param type the {@code Type} of the proxy
+ * @param sa the {@code SocketAddress} for that proxy
* @throws IllegalArgumentException when the type and the address are
* incompatible
*/
@@ -108,9 +108,9 @@ public class Proxy {
/**
* Returns the socket address of the proxy, or
- * null if its a direct connection.
+ * {@code null} if its a direct connection.
*
- * @return a SocketAddress representing the socket end
+ * @return a {@code SocketAddress} representing the socket end
* point of the proxy
*/
public SocketAddress address() {
@@ -121,7 +121,7 @@ public class Proxy {
* Constructs a string representation of this Proxy.
* This String is constructed by calling toString() on its type
* and concatenating " @ " and the toString() result from its address
- * if its type is not DIRECT.
+ * if its type is not {@code DIRECT}.
*
* @return a string representation of this object.
*/
@@ -133,16 +133,16 @@ public class Proxy {
/**
* Compares this object against the specified object.
- * The result is true if and only if the argument is
- * not null and it represents the same proxy as
+ * The result is {@code true} if and only if the argument is
+ * not {@code null} and it represents the same proxy as
* this object.
*
- * Two instances of Proxy represent the same
+ * Two instances of {@code Proxy} represent the same
* address if both the SocketAddresses and type are equal.
*
* @param obj the object to compare against.
- * @return true if the objects are the same;
- * false otherwise.
+ * @return {@code true} if the objects are the same;
+ * {@code false} otherwise.
* @see java.net.InetSocketAddress#equals(java.lang.Object)
*/
public final boolean equals(Object obj) {
diff --git a/src/share/classes/java/net/ProxySelector.java b/src/share/classes/java/net/ProxySelector.java
index 6aa01ffd2e3fc4d37df165de5919afd99326f648..d6bb53656fdb8bcc0e52bd3058e26601aa1047b9 100644
--- a/src/share/classes/java/net/ProxySelector.java
+++ b/src/share/classes/java/net/ProxySelector.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -83,9 +83,9 @@ public abstract class ProxySelector {
*
* @throws SecurityException
* If a security manager has been installed and it denies
- * {@link NetPermission}("getProxySelector")
+ * {@link NetPermission}{@code ("getProxySelector")}
* @see #setDefault(ProxySelector)
- * @return the system-wide ProxySelector
+ * @return the system-wide {@code ProxySelector}
* @since 1.5
*/
public static ProxySelector getDefault() {
@@ -102,11 +102,11 @@ public abstract class ProxySelector {
* Note: non-standard protocol handlers may ignore this setting.
*
* @param ps The HTTP proxy selector, or
- * null to unset the proxy selector.
+ * {@code null} to unset the proxy selector.
*
* @throws SecurityException
* If a security manager has been installed and it denies
- * {@link NetPermission}("setProxySelector")
+ * {@link NetPermission}{@code ("setProxySelector")}
*
* @see #getDefault()
* @since 1.5
@@ -127,7 +127,7 @@ public abstract class ProxySelector {
*
socket://host:portResponseCache
+ * @return the system-wide {@code ResponseCache}
* @since 1.5
*/
public synchronized static ResponseCache getDefault() {
@@ -94,11 +94,11 @@ public abstract class ResponseCache {
* Note: non-standard procotol handlers may ignore this setting.
*
* @param responseCache The response cache, or
- * null to unset the cache.
+ * {@code null} to unset the cache.
*
* @throws SecurityException
* If a security manager has been installed and it denies
- * {@link NetPermission}("setResponseCache")
+ * {@link NetPermission}{@code ("setResponseCache")}
*
* @see #getDefault()
* @since 1.5
@@ -118,14 +118,14 @@ public abstract class ResponseCache {
* to get the network resource. If a cached response is returned,
* that resource is used instead.
*
- * @param uri a URI used to reference the requested
+ * @param uri a {@code URI} used to reference the requested
* network resource
- * @param rqstMethod a String representing the request
+ * @param rqstMethod a {@code String} representing the request
* method
* @param rqstHeaders - a Map from request header
* field names to lists of field values representing
* the current request headers
- * @return a CacheResponse instance if available
+ * @return a {@code CacheResponse} instance if available
* from cache, or null otherwise
* @throws IOException if an I/O error occurs
* @throws IllegalArgumentException if any one of the arguments is null
@@ -148,11 +148,11 @@ public abstract class ResponseCache {
* use to write the resource into the cache. If the resource is
* not to be cached, then put must return null.
*
- * @param uri a URI used to reference the requested
+ * @param uri a {@code URI} used to reference the requested
* network resource
* @param conn - a URLConnection instance that is used to fetch
* the response to be cached
- * @return a CacheRequest for recording the
+ * @return a {@code CacheRequest} for recording the
* response to be cached. Null return indicates that
* the caller does not intend to cache the response.
* @throws IOException if an I/O error occurs
diff --git a/src/share/classes/java/net/ServerSocket.java b/src/share/classes/java/net/ServerSocket.java
index 0b69ad6a266c4ae29ac90cd451966d73c3bf8d08..bcc77ae42f37ee79051a2b9432980e4c3701cf85 100644
--- a/src/share/classes/java/net/ServerSocket.java
+++ b/src/share/classes/java/net/ServerSocket.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 2011, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -37,7 +37,7 @@ import java.security.PrivilegedExceptionAction;
* based on that request, and then possibly returns a result to the requester.
*
* The actual work of the server socket is performed by an instance
- * of the SocketImpl class. An application can
+ * of the {@code SocketImpl} class. An application can
* change the socket factory that creates the socket
* implementation to configure itself to create sockets
* appropriate to the local firewall.
@@ -89,31 +89,31 @@ class ServerSocket implements java.io.Closeable {
/**
* Creates a server socket, bound to the specified port. A port number
- * of 0 means that the port number is automatically
+ * of {@code 0} means that the port number is automatically
* allocated, typically from an ephemeral port range. This port
* number can then be retrieved by calling {@link #getLocalPort getLocalPort}.
*
* The maximum queue length for incoming connection indications (a
- * request to connect) is set to 50. If a connection
+ * request to connect) is set to {@code 50}. If a connection
* indication arrives when the queue is full, the connection is refused.
*
* If the application has specified a server socket factory, that
- * factory's createSocketImpl method is called to create
+ * factory's {@code createSocketImpl} method is called to create
* the actual socket implementation. Otherwise a "plain" socket is created.
*
* If there is a security manager,
- * its checkListen method is called
- * with the port argument
+ * its {@code checkListen} method is called
+ * with the {@code port} argument
* as its argument to ensure the operation is allowed.
* This could result in a SecurityException.
*
*
- * @param port the port number, or 0 to use a port
+ * @param port the port number, or {@code 0} to use a port
* number that is automatically allocated.
*
* @exception IOException if an I/O error occurs when opening the socket.
* @exception SecurityException
- * if a security manager exists and its checkListen
+ * if a security manager exists and its {@code checkListen}
* method doesn't allow the operation.
* @exception IllegalArgumentException if the port parameter is outside
* the specified range of valid port values, which is between
@@ -131,42 +131,42 @@ class ServerSocket implements java.io.Closeable {
/**
* Creates a server socket and binds it to the specified local port
* number, with the specified backlog.
- * A port number of 0 means that the port number is
+ * A port number of {@code 0} means that the port number is
* automatically allocated, typically from an ephemeral port range.
* This port number can then be retrieved by calling
* {@link #getLocalPort getLocalPort}.
*
* The maximum queue length for incoming connection indications (a
- * request to connect) is set to the backlog parameter. If
+ * request to connect) is set to the {@code backlog} parameter. If
* a connection indication arrives when the queue is full, the
* connection is refused.
*
* If the application has specified a server socket factory, that
- * factory's createSocketImpl method is called to create
+ * factory's {@code createSocketImpl} method is called to create
* the actual socket implementation. Otherwise a "plain" socket is created.
*
* If there is a security manager,
- * its checkListen method is called
- * with the port argument
+ * its {@code checkListen} method is called
+ * with the {@code port} argument
* as its argument to ensure the operation is allowed.
* This could result in a SecurityException.
*
- * The backlog argument is the requested maximum number of
+ * The {@code backlog} argument is the requested maximum number of
* pending connections on the socket. Its exact semantics are implementation
* specific. In particular, an implementation may impose a maximum length
* or may choose to ignore the parameter altogther. The value provided
- * should be greater than 0. If it is less than or equal to
- * 0, then an implementation specific default will be used.
+ * should be greater than {@code 0}. If it is less than or equal to
+ * {@code 0}, then an implementation specific default will be used.
*
*
- * @param port the port number, or 0 to use a port
+ * @param port the port number, or {@code 0} to use a port
* number that is automatically allocated.
* @param backlog requested maximum length of the queue of incoming
* connections.
*
* @exception IOException if an I/O error occurs when opening the socket.
* @exception SecurityException
- * if a security manager exists and its checkListen
+ * if a security manager exists and its {@code checkListen}
* method doesn't allow the operation.
* @exception IllegalArgumentException if the port parameter is outside
* the specified range of valid port values, which is between
@@ -189,32 +189,32 @@ class ServerSocket implements java.io.Closeable {
* If bindAddr is null, it will default accepting
* connections on any/all local addresses.
* The port must be between 0 and 65535, inclusive.
- * A port number of 0 means that the port number is
+ * A port number of {@code 0} means that the port number is
* automatically allocated, typically from an ephemeral port range.
* This port number can then be retrieved by calling
* {@link #getLocalPort getLocalPort}.
*
*
If there is a security manager, this method
- * calls its checkListen method
- * with the port argument
+ * calls its {@code checkListen} method
+ * with the {@code port} argument
* as its argument to ensure the operation is allowed.
* This could result in a SecurityException.
*
- * The backlog argument is the requested maximum number of
+ * The {@code backlog} argument is the requested maximum number of
* pending connections on the socket. Its exact semantics are implementation
* specific. In particular, an implementation may impose a maximum length
* or may choose to ignore the parameter altogther. The value provided
- * should be greater than 0. If it is less than or equal to
- * 0, then an implementation specific default will be used.
+ * should be greater than {@code 0}. If it is less than or equal to
+ * {@code 0}, then an implementation specific default will be used.
*
- * @param port the port number, or 0 to use a port
+ * @param port the port number, or {@code 0} to use a port
* number that is automatically allocated.
* @param backlog requested maximum length of the queue of incoming
* connections.
* @param bindAddr the local InetAddress the server will bind to
*
* @throws SecurityException if a security manager exists and
- * its checkListen method doesn't allow the operation.
+ * its {@code checkListen} method doesn't allow the operation.
*
* @throws IOException if an I/O error occurs when opening the socket.
* @exception IllegalArgumentException if the port parameter is outside
@@ -245,10 +245,10 @@ class ServerSocket implements java.io.Closeable {
}
/**
- * Get the SocketImpl attached to this socket, creating
+ * Get the {@code SocketImpl} attached to this socket, creating
* it if necessary.
*
- * @return the SocketImpl attached to that ServerSocket.
+ * @return the {@code SocketImpl} attached to that ServerSocket.
* @throws SocketException if creation fails.
* @since 1.4
*/
@@ -310,17 +310,17 @@ class ServerSocket implements java.io.Closeable {
/**
*
- * Binds the ServerSocket to a specific address
+ * Binds the {@code ServerSocket} to a specific address
* (IP address and port number).
*
- * If the address is null, then the system will pick up
+ * If the address is {@code null}, then the system will pick up
* an ephemeral port and a valid local address to bind the socket.
*
* @param endpoint The IP address and port number to bind to.
* @throws IOException if the bind operation fails, or if the socket
* is already bound.
- * @throws SecurityException if a SecurityManager is present and
- * its checkListen method doesn't allow the operation.
+ * @throws SecurityException if a {@code SecurityManager} is present and
+ * its {@code checkListen} method doesn't allow the operation.
* @throws IllegalArgumentException if endpoint is a
* SocketAddress subclass not supported by this socket
* @since 1.4
@@ -331,25 +331,25 @@ class ServerSocket implements java.io.Closeable {
/**
*
- * Binds the ServerSocket to a specific address
+ * Binds the {@code ServerSocket} to a specific address
* (IP address and port number).
*
- * If the address is null, then the system will pick up
+ * If the address is {@code null}, then the system will pick up
* an ephemeral port and a valid local address to bind the socket.
*
- * The backlog argument is the requested maximum number of
+ * The {@code backlog} argument is the requested maximum number of
* pending connections on the socket. Its exact semantics are implementation
* specific. In particular, an implementation may impose a maximum length
* or may choose to ignore the parameter altogther. The value provided
- * should be greater than 0. If it is less than or equal to
- * 0, then an implementation specific default will be used.
+ * should be greater than {@code 0}. If it is less than or equal to
+ * {@code 0}, then an implementation specific default will be used.
* @param endpoint The IP address and port number to bind to.
* @param backlog requested maximum length of the queue of
* incoming connections.
* @throws IOException if the bind operation fails, or if the socket
* is already bound.
- * @throws SecurityException if a SecurityManager is present and
- * its checkListen method doesn't allow the operation.
+ * @throws SecurityException if a {@code SecurityManager} is present and
+ * its {@code checkListen} method doesn't allow the operation.
* @throws IllegalArgumentException if endpoint is a
* SocketAddress subclass not supported by this socket
* @since 1.4
@@ -480,18 +480,18 @@ class ServerSocket implements java.io.Closeable {
* Listens for a connection to be made to this socket and accepts
* it. The method blocks until a connection is made.
*
- *
A new Socket s is created and, if there
+ *
A new Socket {@code s} is created and, if there
* is a security manager,
- * the security manager's checkAccept method is called
- * with s.getInetAddress().getHostAddress() and
- * s.getPort()
+ * the security manager's {@code checkAccept} method is called
+ * with {@code s.getInetAddress().getHostAddress()} and
+ * {@code s.getPort()}
* as its arguments to ensure the operation is allowed.
* This could result in a SecurityException.
*
* @exception IOException if an I/O error occurs when waiting for a
* connection.
* @exception SecurityException if a security manager exists and its
- * checkAccept method doesn't allow the operation.
+ * {@code checkAccept} method doesn't allow the operation.
* @exception SocketTimeoutException if a timeout was previously set with setSoTimeout and
* the timeout has been reached.
* @exception java.nio.channels.IllegalBlockingModeException
@@ -597,7 +597,7 @@ class ServerSocket implements java.io.Closeable {
* method.
*
* @return the server-socket channel associated with this socket,
- * or null if this socket was not created
+ * or {@code null} if this socket was not created
* for a channel
*
* @since 1.4
@@ -678,18 +678,18 @@ class ServerSocket implements java.io.Closeable {
*
* When a TCP connection is closed the connection may remain * in a timeout state for a period of time after the connection - * is closed (typically known as the TIME_WAIT state - * or 2MSL wait state). + * is closed (typically known as the {@code TIME_WAIT} state + * or {@code 2MSL} wait state). * For applications using a well known socket address or port * it may not be possible to bind a socket to the required - * SocketAddress if there is a connection in the + * {@code SocketAddress} if there is a connection in the * timeout state involving the socket address or port. *
* Enabling {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} prior to * binding the socket using {@link #bind(SocketAddress)} allows the socket * to be bound even though a previous connection is in a timeout state. *
- * When a ServerSocket is created the initial setting
+ * When a {@code ServerSocket} is created the initial setting
* of {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} is not defined.
* Applications can use {@link #getReuseAddress()} to determine the initial
* setting of {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR}.
@@ -717,7 +717,7 @@ class ServerSocket implements java.io.Closeable {
/**
* Tests if {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} is enabled.
*
- * @return a boolean indicating whether or not
+ * @return a {@code boolean} indicating whether or not
* {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} is enabled.
* @exception SocketException if there is an error
* in the underlying protocol, such as a TCP error.
@@ -732,7 +732,7 @@ class ServerSocket implements java.io.Closeable {
/**
* Returns the implementation address and implementation port of
- * this socket as a String.
+ * this socket as a {@code String}.
*
* If there is a security manager set, its {@code checkConnect} method is * called with the local address and {@code -1} as its arguments to see @@ -773,14 +773,14 @@ class ServerSocket implements java.io.Closeable { * application. The factory can be specified only once. *
* When an application creates a new server socket, the socket
- * implementation factory's createSocketImpl method is
+ * implementation factory's {@code createSocketImpl} method is
* called to create the actual socket implementation.
*
- * Passing null to the method is a no-op unless the factory
+ * Passing {@code null} to the method is a no-op unless the factory
* was already set.
*
* If there is a security manager, this method first calls
- * the security manager's checkSetFactory method
+ * the security manager's {@code checkSetFactory} method
* to ensure the operation is allowed.
* This could result in a SecurityException.
*
@@ -789,7 +789,7 @@ class ServerSocket implements java.io.Closeable {
* socket factory.
* @exception SocketException if the factory has already been defined.
* @exception SecurityException if a security manager exists and its
- * checkSetFactory method doesn't allow the operation.
+ * {@code checkSetFactory} method doesn't allow the operation.
* @see java.net.SocketImplFactory#createSocketImpl()
* @see SecurityManager#checkSetFactory
*/
@@ -807,7 +807,7 @@ class ServerSocket implements java.io.Closeable {
/**
* Sets a default proposed value for the
* {@link SocketOptions#SO_RCVBUF SO_RCVBUF} option for sockets
- * accepted from this ServerSocket. The value actually set
+ * accepted from this {@code ServerSocket}. The value actually set
* in the accepted socket must be determined by calling
* {@link Socket#getReceiveBufferSize()} after the socket
* is returned by {@link #accept()}.
@@ -851,13 +851,13 @@ class ServerSocket implements java.io.Closeable {
/**
* Gets the value of the {@link SocketOptions#SO_RCVBUF SO_RCVBUF} option
- * for this ServerSocket, that is the proposed buffer size that
- * will be used for Sockets accepted from this ServerSocket.
+ * for this {@code ServerSocket}, that is the proposed buffer size that
+ * will be used for Sockets accepted from this {@code ServerSocket}.
*
*
Note, the value actually set in the accepted socket is determined by * calling {@link Socket#getReceiveBufferSize()}. * @return the value of the {@link SocketOptions#SO_RCVBUF SO_RCVBUF} - * option for this Socket. + * option for this {@code Socket}. * @exception SocketException if there is an error * in the underlying protocol, such as a TCP error. * @see #setReceiveBufferSize(int) @@ -891,24 +891,24 @@ class ServerSocket implements java.io.Closeable { * compared, with larger values indicating stronger preferences. If the * application prefers short connection time over both low latency and high * bandwidth, for example, then it could invoke this method with the values - * (1, 0, 0). If the application prefers high bandwidth above low + * {@code (1, 0, 0)}. If the application prefers high bandwidth above low * latency, and low latency above short connection time, then it could - * invoke this method with the values (0, 1, 2). + * invoke this method with the values {@code (0, 1, 2)}. * *
Invoking this method after this socket has been bound * will have no effect. This implies that in order to use this capability * requires the socket to be created with the no-argument constructor. * * @param connectionTime - * An int expressing the relative importance of a short + * An {@code int} expressing the relative importance of a short * connection time * * @param latency - * An int expressing the relative importance of low + * An {@code int} expressing the relative importance of low * latency * * @param bandwidth - * An int expressing the relative importance of high + * An {@code int} expressing the relative importance of high * bandwidth * * @since 1.5 diff --git a/src/share/classes/java/net/Socket.java b/src/share/classes/java/net/Socket.java index 8ab5e866ee25abdd2ec195be896e9c5ae1145505..361260351f581bb42a2d5b3c6d0629c34e2c4d60 100644 --- a/src/share/classes/java/net/Socket.java +++ b/src/share/classes/java/net/Socket.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -39,7 +39,7 @@ import java.security.PrivilegedAction; * between two machines. *
* The actual work of the socket is performed by an instance of the
- * SocketImpl class. An application, by changing
+ * {@code SocketImpl} class. An application, by changing
* the socket factory that creates the socket implementation,
* can configure itself to create sockets appropriate to the local
* firewall.
@@ -88,14 +88,14 @@ class Socket implements java.io.Closeable {
* Creates an unconnected socket, specifying the type of proxy, if any,
* that should be used regardless of any other settings.
*
- * If there is a security manager, its checkConnect method
+ * If there is a security manager, its {@code checkConnect} method
* is called with the proxy host address and port number
* as its arguments. This could result in a SecurityException.
*
* Examples: - *
Socket s = new Socket(Proxy.NO_PROXY); will create
+ * Socket s = new Socket(new Proxy(Proxy.Type.SOCKS, new InetSocketAddress("socks.mydom.com", 1080)));
+ * null.
+ * or {@code null}.
* @throws SecurityException if a security manager is present and
* permission to connect to the proxy is
* denied.
@@ -173,21 +173,22 @@ class Socket implements java.io.Closeable {
* Creates a stream socket and connects it to the specified port
* number on the named host.
* - * If the specified host is null it is the equivalent of - * specifying the address as {@link java.net.InetAddress#getByName InetAddress.getByName}(null). + * If the specified host is {@code null} it is the equivalent of + * specifying the address as + * {@link java.net.InetAddress#getByName InetAddress.getByName}{@code (null)}. * In other words, it is equivalent to specifying an address of the * loopback interface.
*
* If the application has specified a server socket factory, that
- * factory's createSocketImpl method is called to create
+ * factory's {@code createSocketImpl} method is called to create
* the actual socket implementation. Otherwise a "plain" socket is created.
*
* If there is a security manager, its
- * checkConnect method is called
- * with the host address and port
+ * {@code checkConnect} method is called
+ * with the host address and {@code port}
* as its arguments. This could result in a SecurityException.
*
- * @param host the host name, or null for the loopback address.
+ * @param host the host name, or {@code null} for the loopback address.
* @param port the port number.
*
* @exception UnknownHostException if the IP address of
@@ -195,7 +196,7 @@ class Socket implements java.io.Closeable {
*
* @exception IOException if an I/O error occurs when creating the socket.
* @exception SecurityException if a security manager exists and its
- * checkConnect method doesn't allow the operation.
+ * {@code checkConnect} method doesn't allow the operation.
* @exception IllegalArgumentException if the port parameter is outside
* the specified range of valid port values, which is between
* 0 and 65535, inclusive.
@@ -217,23 +218,23 @@ class Socket implements java.io.Closeable {
* number at the specified IP address.
*
* If the application has specified a socket factory, that factory's
- * createSocketImpl method is called to create the
+ * {@code createSocketImpl} method is called to create the
* actual socket implementation. Otherwise a "plain" socket is created.
*
* If there is a security manager, its
- * checkConnect method is called
- * with the host address and port
+ * {@code checkConnect} method is called
+ * with the host address and {@code port}
* as its arguments. This could result in a SecurityException.
*
* @param address the IP address.
* @param port the port number.
* @exception IOException if an I/O error occurs when creating the socket.
* @exception SecurityException if a security manager exists and its
- * checkConnect method doesn't allow the operation.
+ * {@code checkConnect} method doesn't allow the operation.
* @exception IllegalArgumentException if the port parameter is outside
* the specified range of valid port values, which is between
* 0 and 65535, inclusive.
- * @exception NullPointerException if address is null.
+ * @exception NullPointerException if {@code address} is null.
* @see java.net.Socket#setSocketImplFactory(java.net.SocketImplFactory)
* @see java.net.SocketImpl
* @see java.net.SocketImplFactory#createSocketImpl()
@@ -249,28 +250,29 @@ class Socket implements java.io.Closeable {
* the specified remote port. The Socket will also bind() to the local
* address and port supplied.
*
- * If the specified host is null it is the equivalent of - * specifying the address as {@link java.net.InetAddress#getByName InetAddress.getByName}(null). + * If the specified host is {@code null} it is the equivalent of + * specifying the address as + * {@link java.net.InetAddress#getByName InetAddress.getByName}{@code (null)}. * In other words, it is equivalent to specifying an address of the * loopback interface.
*
- * A local port number of zero will let the system pick up a
- * free port in the bind operation.
* If there is a security manager, its
- * checkConnect method is called
- * with the host address and port
+ * {@code checkConnect} method is called
+ * with the host address and {@code port}
* as its arguments. This could result in a SecurityException.
*
- * @param host the name of the remote host, or null for the loopback address.
+ * @param host the name of the remote host, or {@code null} for the loopback address.
* @param port the remote port
* @param localAddr the local address the socket is bound to, or
- * null for the anyLocal address.
+ * {@code null} for the {@code anyLocal} address.
* @param localPort the local port the socket is bound to, or
- * zero for a system selected free port.
+ * {@code zero} for a system selected free port.
* @exception IOException if an I/O error occurs when creating the socket.
* @exception SecurityException if a security manager exists and its
- * checkConnect method doesn't allow the operation.
+ * {@code checkConnect} method doesn't allow the operation.
* @exception IllegalArgumentException if the port parameter or localPort
* parameter is outside the specified range of valid port values,
* which is between 0 and 65535, inclusive.
@@ -289,30 +291,31 @@ class Socket implements java.io.Closeable {
* the specified remote port. The Socket will also bind() to the local
* address and port supplied.
*
- * If the specified local address is null it is the equivalent of - * specifying the address as the AnyLocal address (see {@link java.net.InetAddress#isAnyLocalAddress InetAddress.isAnyLocalAddress}()). + * If the specified local address is {@code null} it is the equivalent of + * specifying the address as the AnyLocal address + * (see {@link java.net.InetAddress#isAnyLocalAddress InetAddress.isAnyLocalAddress}{@code ()}). *
- * A local port number of zero will let the system pick up a
- * free port in the bind operation.
* If there is a security manager, its
- * checkConnect method is called
- * with the host address and port
+ * {@code checkConnect} method is called
+ * with the host address and {@code port}
* as its arguments. This could result in a SecurityException.
*
* @param address the remote address
* @param port the remote port
* @param localAddr the local address the socket is bound to, or
- * null for the anyLocal address.
+ * {@code null} for the {@code anyLocal} address.
* @param localPort the local port the socket is bound to or
- * zero for a system selected free port.
+ * {@code zero} for a system selected free port.
* @exception IOException if an I/O error occurs when creating the socket.
* @exception SecurityException if a security manager exists and its
- * checkConnect method doesn't allow the operation.
+ * {@code checkConnect} method doesn't allow the operation.
* @exception IllegalArgumentException if the port parameter or localPort
* parameter is outside the specified range of valid port values,
* which is between 0 and 65535, inclusive.
- * @exception NullPointerException if address is null.
+ * @exception NullPointerException if {@code address} is null.
* @see SecurityManager#checkConnect
* @since JDK1.1
*/
@@ -326,33 +329,34 @@ class Socket implements java.io.Closeable {
* Creates a stream socket and connects it to the specified port
* number on the named host.
*
- * If the specified host is null it is the equivalent of - * specifying the address as {@link java.net.InetAddress#getByName InetAddress.getByName}(null). + * If the specified host is {@code null} it is the equivalent of + * specifying the address as + * {@link java.net.InetAddress#getByName InetAddress.getByName}{@code (null)}. * In other words, it is equivalent to specifying an address of the * loopback interface.
*
- * If the stream argument is true, this creates a
- * stream socket. If the stream argument is false, it
+ * If the stream argument is {@code true}, this creates a
+ * stream socket. If the stream argument is {@code false}, it
* creates a datagram socket.
*
* If the application has specified a server socket factory, that
- * factory's createSocketImpl method is called to create
+ * factory's {@code createSocketImpl} method is called to create
* the actual socket implementation. Otherwise a "plain" socket is created.
*
* If there is a security manager, its
- * checkConnect method is called
- * with the host address and port
+ * {@code checkConnect} method is called
+ * with the host address and {@code port}
* as its arguments. This could result in a SecurityException.
*
* If a UDP socket is used, TCP/IP related socket options will not apply.
*
- * @param host the host name, or null for the loopback address.
+ * @param host the host name, or {@code null} for the loopback address.
* @param port the port number.
- * @param stream a boolean indicating whether this is
+ * @param stream a {@code boolean} indicating whether this is
* a stream socket or a datagram socket.
* @exception IOException if an I/O error occurs when creating the socket.
* @exception SecurityException if a security manager exists and its
- * checkConnect method doesn't allow the operation.
+ * {@code checkConnect} method doesn't allow the operation.
* @exception IllegalArgumentException if the port parameter is outside
* the specified range of valid port values, which is between
* 0 and 65535, inclusive.
@@ -373,32 +377,32 @@ class Socket implements java.io.Closeable {
* Creates a socket and connects it to the specified port number at
* the specified IP address.
*
- * If the stream argument is true, this creates a
- * stream socket. If the stream argument is false, it
+ * If the stream argument is {@code true}, this creates a
+ * stream socket. If the stream argument is {@code false}, it
* creates a datagram socket.
*
* If the application has specified a server socket factory, that
- * factory's createSocketImpl method is called to create
+ * factory's {@code createSocketImpl} method is called to create
* the actual socket implementation. Otherwise a "plain" socket is created.
*
*
If there is a security manager, its
- * checkConnect method is called
- * with host.getHostAddress() and port
+ * {@code checkConnect} method is called
+ * with {@code host.getHostAddress()} and {@code port}
* as its arguments. This could result in a SecurityException.
*
* If UDP socket is used, TCP/IP related socket options will not apply.
*
* @param host the IP address.
* @param port the port number.
- * @param stream if true, create a stream socket;
+ * @param stream if {@code true}, create a stream socket;
* otherwise, create a datagram socket.
* @exception IOException if an I/O error occurs when creating the socket.
* @exception SecurityException if a security manager exists and its
- * checkConnect method doesn't allow the operation.
+ * {@code checkConnect} method doesn't allow the operation.
* @exception IllegalArgumentException if the port parameter is outside
* the specified range of valid port values, which is between
* 0 and 65535, inclusive.
- * @exception NullPointerException if host is null.
+ * @exception NullPointerException if {@code host} is null.
* @see java.net.Socket#setSocketImplFactory(java.net.SocketImplFactory)
* @see java.net.SocketImpl
* @see java.net.SocketImplFactory#createSocketImpl()
@@ -437,8 +441,8 @@ class Socket implements java.io.Closeable {
/**
* Creates the socket implementation.
*
- * @param stream a boolean value : true for a TCP socket,
- * false for UDP.
+ * @param stream a {@code boolean} value : {@code true} for a TCP socket,
+ * {@code false} for UDP.
* @throws IOException if creation fails
* @since 1.4
*/
@@ -500,10 +504,10 @@ class Socket implements java.io.Closeable {
/**
- * Get the SocketImpl attached to this socket, creating
+ * Get the {@code SocketImpl} attached to this socket, creating
* it if necessary.
*
- * @return the SocketImpl attached to that ServerSocket.
+ * @return the {@code SocketImpl} attached to that ServerSocket.
* @throws SocketException if creation fails
* @since 1.4
*/
@@ -516,7 +520,7 @@ class Socket implements java.io.Closeable {
/**
* Connects this socket to the server.
*
- * @param endpoint the SocketAddress
+ * @param endpoint the {@code SocketAddress}
* @throws IOException if an error occurs during the connection
* @throws java.nio.channels.IllegalBlockingModeException
* if this socket has an associated channel,
@@ -535,7 +539,7 @@ class Socket implements java.io.Closeable {
* A timeout of zero is interpreted as an infinite timeout. The connection
* will then block until established or an error occurs.
*
- * @param endpoint the SocketAddress
+ * @param endpoint the {@code SocketAddress}
* @param timeout the timeout value to be used in milliseconds.
* @throws IOException if an error occurs during the connection
* @throws SocketTimeoutException if timeout expires before connecting
@@ -597,10 +601,10 @@ class Socket implements java.io.Closeable {
/**
* Binds the socket to a local address.
*
- * If the address is null, then the system will pick up
+ * If the address is {@code null}, then the system will pick up
* an ephemeral port and a valid local address to bind the socket.
*
- * @param bindpoint the SocketAddress to bind to
+ * @param bindpoint the {@code SocketAddress} to bind to
* @throws IOException if the bind operation fails, or if the socket
* is already bound.
* @throws IllegalArgumentException if bindpoint is a
@@ -668,7 +672,7 @@ class Socket implements java.io.Closeable {
* after the socket is closed.
*
* @return the remote IP address to which this socket is connected,
- * or null if the socket is not connected.
+ * or {@code null} if the socket is not connected.
*/
public InetAddress getInetAddress() {
if (!isConnected())
@@ -760,15 +764,15 @@ class Socket implements java.io.Closeable {
/**
* Returns the address of the endpoint this socket is connected to, or
- * null if it is unconnected.
+ * {@code null} if it is unconnected.
*
* If the socket was connected prior to being {@link #close closed},
* then this method will continue to return the connected address
* after the socket is closed.
*
- * @return a SocketAddress representing the remote endpoint of this
- * socket, or null if it is not connected yet.
+ * @return a {@code SocketAddress} representing the remote endpoint of this
+ * socket, or {@code null} if it is not connected yet.
* @see #getInetAddress()
* @see #getPort()
* @see #connect(SocketAddress, int)
@@ -785,10 +789,10 @@ class Socket implements java.io.Closeable {
* Returns the address of the endpoint this socket is bound to.
*
* If a socket bound to an endpoint represented by an
- * InetSocketAddress is {@link #close closed},
- * then this method will continue to return an InetSocketAddress
+ * {@code InetSocketAddress } is {@link #close closed},
+ * then this method will continue to return an {@code InetSocketAddress}
* after the socket is closed. In that case the returned
- * InetSocketAddress's address is the
+ * {@code InetSocketAddress}'s address is the
* {@link InetAddress#isAnyLocalAddress wildcard} address
* and its port is the local port that it was bound to.
*
@@ -828,7 +832,7 @@ class Socket implements java.io.Closeable { * methods. * * @return the socket channel associated with this socket, - * or null if this socket was not created + * or {@code null} if this socket was not created * for a channel * * @since 1.4 @@ -843,7 +847,7 @@ class Socket implements java.io.Closeable { * *
If this socket has an associated channel then the resulting input * stream delegates all of its operations to the channel. If the channel - * is in non-blocking mode then the input stream's read operations + * is in non-blocking mode then the input stream's {@code read} operations * will throw an {@link java.nio.channels.IllegalBlockingModeException}. * *
Under abnormal conditions the underlying connection may be @@ -867,7 +871,7 @@ class Socket implements java.io.Closeable { *
If there are no bytes buffered on the socket, and the
* socket has not been closed using {@link #close close}, then
* {@link java.io.InputStream#available available} will
- * return 0.
+ * return {@code 0}.
*
*
If this socket has an associated channel then the resulting output
* stream delegates all of its operations to the channel. If the channel
- * is in non-blocking mode then the output stream's write
+ * is in non-blocking mode then the output stream's {@code write}
* operations will throw an {@link
* java.nio.channels.IllegalBlockingModeException}.
*
@@ -949,8 +953,8 @@ class Socket implements java.io.Closeable {
* Enable/disable {@link SocketOptions#TCP_NODELAY TCP_NODELAY}
* (disable/enable Nagle's algorithm).
*
- * @param on true to enable TCP_NODELAY,
- * false to disable.
+ * @param on {@code true} to enable TCP_NODELAY,
+ * {@code false} to disable.
*
* @exception SocketException if there is an error
* in the underlying protocol, such as a TCP error.
@@ -968,7 +972,7 @@ class Socket implements java.io.Closeable {
/**
* Tests if {@link SocketOptions#TCP_NODELAY TCP_NODELAY} is enabled.
*
- * @return a boolean indicating whether or not
+ * @return a {@code boolean} indicating whether or not
* {@link SocketOptions#TCP_NODELAY TCP_NODELAY} is enabled.
* @exception SocketException if there is an error
* in the underlying protocol, such as a TCP error.
@@ -1066,9 +1070,9 @@ class Socket implements java.io.Closeable {
* and there is no capability to distinguish between normal data and urgent
* data unless provided by a higher level protocol.
*
- * @param on true to enable
+ * @param on {@code true} to enable
* {@link SocketOptions#SO_OOBINLINE SO_OOBINLINE},
- * false to disable.
+ * {@code false} to disable.
*
* @exception SocketException if there is an error
* in the underlying protocol, such as a TCP error.
@@ -1086,7 +1090,7 @@ class Socket implements java.io.Closeable {
/**
* Tests if {@link SocketOptions#SO_OOBINLINE SO_OOBINLINE} is enabled.
*
- * @return a boolean indicating whether or not
+ * @return a {@code boolean} indicating whether or not
* {@link SocketOptions#SO_OOBINLINE SO_OOBINLINE}is enabled.
*
* @exception SocketException if there is an error
@@ -1151,7 +1155,7 @@ class Socket implements java.io.Closeable {
/**
* Sets the {@link SocketOptions#SO_SNDBUF SO_SNDBUF} option to the
- * specified value for this Socket.
+ * specified value for this {@code Socket}.
* The {@link SocketOptions#SO_SNDBUF SO_SNDBUF} option is used by the
* platform's networking code as a hint for the size to set the underlying
* network I/O buffers.
@@ -1184,10 +1188,10 @@ class Socket implements java.io.Closeable {
/**
* Get value of the {@link SocketOptions#SO_SNDBUF SO_SNDBUF} option
- * for this Socket, that is the buffer size used by the platform
- * for output on this Socket.
+ * for this {@code Socket}, that is the buffer size used by the platform
+ * for output on this {@code Socket}.
* @return the value of the {@link SocketOptions#SO_SNDBUF SO_SNDBUF}
- * option for this Socket.
+ * option for this {@code Socket}.
*
* @exception SocketException if there is an error
* in the underlying protocol, such as a TCP error.
@@ -1208,7 +1212,7 @@ class Socket implements java.io.Closeable {
/**
* Sets the {@link SocketOptions#SO_RCVBUF SO_RCVBUF} option to the
- * specified value for this Socket. The
+ * specified value for this {@code Socket}. The
* {@link SocketOptions#SO_RCVBUF SO_RCVBUF} option is
* used by the platform's networking code as a hint for the size to set
* the underlying network I/O buffers.
@@ -1258,11 +1262,11 @@ class Socket implements java.io.Closeable {
/**
* Gets the value of the {@link SocketOptions#SO_RCVBUF SO_RCVBUF} option
- * for this Socket, that is the buffer size used by the platform
- * for input on this Socket.
+ * for this {@code Socket}, that is the buffer size used by the platform
+ * for input on this {@code Socket}.
*
* @return the value of the {@link SocketOptions#SO_RCVBUF SO_RCVBUF}
- * option for this Socket.
+ * option for this {@code Socket}.
* @exception SocketException if there is an error
* in the underlying protocol, such as a TCP error.
* @see #setReceiveBufferSize(int)
@@ -1298,7 +1302,7 @@ class Socket implements java.io.Closeable {
/**
* Tests if {@link SocketOptions#SO_KEEPALIVE SO_KEEPALIVE} is enabled.
*
- * @return a boolean indicating whether or not
+ * @return a {@code boolean} indicating whether or not
* {@link SocketOptions#SO_KEEPALIVE SO_KEEPALIVE} is enabled.
* @exception SocketException if there is an error
* in the underlying protocol, such as a TCP error.
@@ -1321,7 +1325,7 @@ class Socket implements java.io.Closeable {
* 255} or an IllegalArgumentException will be thrown.
*
Notes: *
For Internet Protocol v4 the value consists of an
- * integer, the least significant 8 bits of which
+ * {@code integer}, the least significant 8 bits of which
* represent the value of the TOS octet in IP packets sent by
* the socket.
* RFC 1349 defines the TOS values as follows:
@@ -1347,10 +1351,10 @@ class Socket implements java.io.Closeable {
* in the underlying platform. Applications should not assume that
* they can change the TOS field after the connection.
*
- * For Internet Protocol v6 tc is the value that
+ * For Internet Protocol v6 {@code tc} is the value that
* would be placed into the sin6_flowinfo field of the IP header.
*
- * @param tc an int value for the bitset.
+ * @param tc an {@code int} value for the bitset.
* @throws SocketException if there is an error setting the
* traffic class or type-of-service
* @since 1.4
@@ -1392,11 +1396,11 @@ class Socket implements java.io.Closeable {
*
* When a TCP connection is closed the connection may remain * in a timeout state for a period of time after the connection - * is closed (typically known as the TIME_WAIT state - * or 2MSL wait state). + * is closed (typically known as the {@code TIME_WAIT} state + * or {@code 2MSL} wait state). * For applications using a well known socket address or port * it may not be possible to bind a socket to the required - * SocketAddress if there is a connection in the + * {@code SocketAddress} if there is a connection in the * timeout state involving the socket address or port. *
* Enabling {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} @@ -1404,7 +1408,7 @@ class Socket implements java.io.Closeable { * the socket to be bound even though a previous connection is in a timeout * state. *
- * When a Socket is created the initial setting + * When a {@code Socket} is created the initial setting * of {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} is disabled. *
* The behaviour when {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} is
@@ -1430,7 +1434,7 @@ class Socket implements java.io.Closeable {
/**
* Tests if {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} is enabled.
*
- * @return a boolean indicating whether or not
+ * @return a {@code boolean} indicating whether or not
* {@link SocketOptions#SO_REUSEADDR SO_REUSEADDR} is enabled.
* @exception SocketException if there is an error
* in the underlying protocol, such as a TCP error.
@@ -1536,7 +1540,7 @@ class Socket implements java.io.Closeable {
}
/**
- * Converts this socket to a String.
+ * Converts this socket to a {@code String}.
*
* @return a string representation of this socket.
*/
@@ -1555,7 +1559,7 @@ class Socket implements java.io.Closeable {
* Returns the connection state of the socket.
*
* Note: Closing a socket doesn't clear its connection state, which means
- * this method will return true for a closed socket
+ * this method will return {@code true} for a closed socket
* (see {@link #isClosed()}) if it was successfuly connected prior
* to being closed.
*
@@ -1571,7 +1575,7 @@ class Socket implements java.io.Closeable {
* Returns the binding state of the socket.
*
* Note: Closing a socket doesn't clear its binding state, which means
- * this method will return true for a closed socket
+ * this method will return {@code true} for a closed socket
* (see {@link #isClosed()}) if it was successfuly bound prior
* to being closed.
*
@@ -1629,13 +1633,13 @@ class Socket implements java.io.Closeable {
* application. The factory can be specified only once.
*
* When an application creates a new client socket, the socket
- * implementation factory's createSocketImpl method is
+ * implementation factory's {@code createSocketImpl} method is
* called to create the actual socket implementation.
*
- * Passing null to the method is a no-op unless the factory
+ * Passing {@code null} to the method is a no-op unless the factory
* was already set.
*
If there is a security manager, this method first calls
- * the security manager's checkSetFactory method
+ * the security manager's {@code checkSetFactory} method
* to ensure the operation is allowed.
* This could result in a SecurityException.
*
@@ -1644,7 +1648,7 @@ class Socket implements java.io.Closeable {
* socket factory.
* @exception SocketException if the factory is already defined.
* @exception SecurityException if a security manager exists and its
- * checkSetFactory method doesn't allow the operation.
+ * {@code checkSetFactory} method doesn't allow the operation.
* @see java.net.SocketImplFactory#createSocketImpl()
* @see SecurityManager#checkSetFactory
*/
@@ -1678,23 +1682,23 @@ class Socket implements java.io.Closeable {
* values represent a lower priority than positive values. If the
* application prefers short connection time over both low latency and high
* bandwidth, for example, then it could invoke this method with the values
- * (1, 0, 0). If the application prefers high bandwidth above low
+ * {@code (1, 0, 0)}. If the application prefers high bandwidth above low
* latency, and low latency above short connection time, then it could
- * invoke this method with the values (0, 1, 2).
+ * invoke this method with the values {@code (0, 1, 2)}.
*
*
Invoking this method after this socket has been connected
* will have no effect.
*
* @param connectionTime
- * An int expressing the relative importance of a short
+ * An {@code int} expressing the relative importance of a short
* connection time
*
* @param latency
- * An int expressing the relative importance of low
+ * An {@code int} expressing the relative importance of low
* latency
*
* @param bandwidth
- * An int expressing the relative importance of high
+ * An {@code int} expressing the relative importance of high
* bandwidth
*
* @since 1.5
diff --git a/src/share/classes/java/net/SocketAddress.java b/src/share/classes/java/net/SocketAddress.java
index 5cdd4a519cbd62aba350d55c42405236692e7fa7..a3ee4ee52f5e34ebfb668b04a81a221b6c8474c7 100644
--- a/src/share/classes/java/net/SocketAddress.java
+++ b/src/share/classes/java/net/SocketAddress.java
@@ -39,4 +39,7 @@ package java.net;
* @since 1.4
*/
public abstract class SocketAddress implements java.io.Serializable {
+
+ static final long serialVersionUID = 5215720748342549866L;
+
}
diff --git a/src/share/classes/java/net/SocketException.java b/src/share/classes/java/net/SocketException.java
index eae84d92bab26ea49c5be94bdb0b68d5ceb600cd..690fc4f55bd1533d854452dc867fbc5d038c52ce 100644
--- a/src/share/classes/java/net/SocketException.java
+++ b/src/share/classes/java/net/SocketException.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 2008, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -38,7 +38,7 @@ class SocketException extends IOException {
private static final long serialVersionUID = -5935874303556886934L;
/**
- * Constructs a new SocketException with the
+ * Constructs a new {@code SocketException} with the
* specified detail message.
*
* @param msg the detail message.
@@ -48,7 +48,7 @@ class SocketException extends IOException {
}
/**
- * Constructs a new SocketException with no detail message.
+ * Constructs a new {@code SocketException} with no detail message.
*/
public SocketException() {
}
diff --git a/src/share/classes/java/net/SocketImpl.java b/src/share/classes/java/net/SocketImpl.java
index 3dbb7b355ed09ab5180555ff2e6107f5b9238763..67286a1cd608c609628717ba12cb2408f839950e 100644
--- a/src/share/classes/java/net/SocketImpl.java
+++ b/src/share/classes/java/net/SocketImpl.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 2011, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -31,7 +31,7 @@ import java.io.OutputStream;
import java.io.FileDescriptor;
/**
- * The abstract class SocketImpl is a common superclass
+ * The abstract class {@code SocketImpl} is a common superclass
* of all classes that actually implement sockets. It is used to
* create both client and server sockets.
*
@@ -71,7 +71,7 @@ public abstract class SocketImpl implements SocketOptions {
/**
* Creates either a stream or a datagram socket.
*
- * @param stream if true, create a stream socket;
+ * @param stream if {@code true}, create a stream socket;
* otherwise, create a datagram socket.
* @exception IOException if an I/O error occurs while creating the
* socket.
@@ -122,7 +122,7 @@ public abstract class SocketImpl implements SocketOptions {
/**
* Sets the maximum queue length for incoming connection indications
- * (a request to connect) to the count argument. If a
+ * (a request to connect) to the {@code count} argument. If a
* connection indication arrives when the queue is full, the
* connection is refused.
*
@@ -217,9 +217,9 @@ public abstract class SocketImpl implements SocketOptions {
}
/**
- * Returns the value of this socket's fd field.
+ * Returns the value of this socket's {@code fd} field.
*
- * @return the value of this socket's fd field.
+ * @return the value of this socket's {@code fd} field.
* @see java.net.SocketImpl#fd
*/
protected FileDescriptor getFileDescriptor() {
@@ -227,9 +227,9 @@ public abstract class SocketImpl implements SocketOptions {
}
/**
- * Returns the value of this socket's address field.
+ * Returns the value of this socket's {@code address} field.
*
- * @return the value of this socket's address field.
+ * @return the value of this socket's {@code address} field.
* @see java.net.SocketImpl#address
*/
protected InetAddress getInetAddress() {
@@ -237,9 +237,9 @@ public abstract class SocketImpl implements SocketOptions {
}
/**
- * Returns the value of this socket's port field.
+ * Returns the value of this socket's {@code port} field.
*
- * @return the value of this socket's port field.
+ * @return the value of this socket's {@code port} field.
* @see java.net.SocketImpl#port
*/
protected int getPort() {
@@ -270,9 +270,9 @@ public abstract class SocketImpl implements SocketOptions {
protected abstract void sendUrgentData (int data) throws IOException;
/**
- * Returns the value of this socket's localport field.
+ * Returns the value of this socket's {@code localport} field.
*
- * @return the value of this socket's localport field.
+ * @return the value of this socket's {@code localport} field.
* @see java.net.SocketImpl#localport
*/
protected int getLocalPort() {
@@ -296,7 +296,7 @@ public abstract class SocketImpl implements SocketOptions {
}
/**
- * Returns the address and port of this socket as a String.
+ * Returns the address and port of this socket as a {@code String}.
*
* @return a string representation of this socket.
*/
@@ -328,23 +328,23 @@ public abstract class SocketImpl implements SocketOptions {
* values represent a lower priority than positive values. If the
* application prefers short connection time over both low latency and high
* bandwidth, for example, then it could invoke this method with the values
- * (1, 0, 0). If the application prefers high bandwidth above low
+ * {@code (1, 0, 0)}. If the application prefers high bandwidth above low
* latency, and low latency above short connection time, then it could
- * invoke this method with the values (0, 1, 2).
+ * invoke this method with the values {@code (0, 1, 2)}.
*
* By default, this method does nothing, unless it is overridden in a
* a sub-class.
*
* @param connectionTime
- * An int expressing the relative importance of a short
+ * An {@code int} expressing the relative importance of a short
* connection time
*
* @param latency
- * An int expressing the relative importance of low
+ * An {@code int} expressing the relative importance of low
* latency
*
* @param bandwidth
- * An int expressing the relative importance of high
+ * An {@code int} expressing the relative importance of high
* bandwidth
*
* @since 1.5
diff --git a/src/share/classes/java/net/SocketImplFactory.java b/src/share/classes/java/net/SocketImplFactory.java
index 52ab3277aac93f3d3a0ee7e6f40d2842503e0c09..7aa6363b4fd4b679cdf75560e51d36dc6a3f3a45 100644
--- a/src/share/classes/java/net/SocketImplFactory.java
+++ b/src/share/classes/java/net/SocketImplFactory.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 1999, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -27,8 +27,8 @@ package java.net;
/**
* This interface defines a factory for socket implementations. It
- * is used by the classes Socket and
- * ServerSocket to create actual socket
+ * is used by the classes {@code Socket} and
+ * {@code ServerSocket} to create actual socket
* implementations.
*
* @author Arthur van Hoff
@@ -39,9 +39,9 @@ package java.net;
public
interface SocketImplFactory {
/**
- * Creates a new SocketImpl instance.
+ * Creates a new {@code SocketImpl} instance.
*
- * @return a new instance of SocketImpl.
+ * @return a new instance of {@code SocketImpl}.
* @see java.net.SocketImpl
*/
SocketImpl createSocketImpl();
diff --git a/src/share/classes/java/net/SocketInputStream.java b/src/share/classes/java/net/SocketInputStream.java
index b708436a783054cf47c85cf9160f807f203581f0..224051ff6085c63014d1fd7bef50cce058e2d61b 100644
--- a/src/share/classes/java/net/SocketInputStream.java
+++ b/src/share/classes/java/net/SocketInputStream.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -67,8 +67,8 @@ class SocketInputStream extends FileInputStream
* Returns the unique {@link java.nio.channels.FileChannel FileChannel}
* object associated with this file input stream.
getChannel method of SocketInputStream
- * returns null since it is a socket based stream.
+ * The {@code getChannel} method of {@code SocketInputStream}
+ * returns {@code null} since it is a socket based stream.
*
* @return the file channel associated with this file input stream
*
diff --git a/src/share/classes/java/net/SocketOptions.java b/src/share/classes/java/net/SocketOptions.java
index 44dd1b9b40df3fd3ab1742e7d1f29d4d7b07da4b..b9508dbb2664c96e5d31a5d27e8018af2ea0b80e 100644
--- a/src/share/classes/java/net/SocketOptions.java
+++ b/src/share/classes/java/net/SocketOptions.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1996, 2006, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -115,7 +115,7 @@ public interface SocketOptions {
* }
*
*
- * @param optID an int identifying the option to fetch
+ * @param optID an {@code int} identifying the option to fetch
* @return the value of the option
* @throws SocketException if the socket is closed
* @throws SocketException if optID is unknown along the
diff --git a/src/share/classes/java/net/SocketOutputStream.java b/src/share/classes/java/net/SocketOutputStream.java
index 06e234efc4a307bae29014bb91a036e7b5df6973..2404e9583f438a500da26e85a260126925324308 100644
--- a/src/share/classes/java/net/SocketOutputStream.java
+++ b/src/share/classes/java/net/SocketOutputStream.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1995, 2007, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -64,8 +64,8 @@ class SocketOutputStream extends FileOutputStream
* Returns the unique {@link java.nio.channels.FileChannel FileChannel}
* object associated with this file output stream.
*
- * The getChannel method of SocketOutputStream
- * returns null since it is a socket based stream.
+ * The {@code getChannel} method of {@code SocketOutputStream}
+ * returns {@code null} since it is a socket based stream.
*
* @return the file channel associated with this file output stream
*
diff --git a/src/share/classes/java/net/SocketPermission.java b/src/share/classes/java/net/SocketPermission.java
index 43650068ae212365322f4721b9229f8468e7fcaa..e90856eac8ef93150e4e8698d268971b422b9774 100644
--- a/src/share/classes/java/net/SocketPermission.java
+++ b/src/share/classes/java/net/SocketPermission.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -110,7 +110,7 @@ import sun.security.util.Debug;
*
*
* is granted to some code, it allows that code to connect to port 7777 on
- * puffin.eng.sun.com, and to accept connections on that port.
+ * {@code puffin.eng.sun.com}, and to accept connections on that port.
*
* Similarly, if the following permission: * @@ -788,7 +788,7 @@ public final class SocketPermission extends Permission * port range is ignored when p only contains the action, 'resolve'.
*
implies checks each of the following, in order,
+ * Then {@code implies} checks each of the following, in order,
* and for each returns true if the stated condition is true:*
*
implies returns false.
+ * If none of the above are true, {@code implies} returns false.
* @param p the permission to check against.
*
* @return true if the specified permission is implied by this object,
@@ -1131,7 +1131,7 @@ public final class SocketPermission extends Permission
*
* SocketPermission objects must be stored in a manner that allows them
* to be inserted into the collection in any order, but that also enables the
- * PermissionCollection implies
+ * PermissionCollection {@code implies}
* method to be implemented in an efficient (and consistent) manner.
*
* @return a new PermissionCollection object suitable for storing SocketPermissions.
diff --git a/src/share/classes/java/net/SocksSocketImpl.java b/src/share/classes/java/net/SocksSocketImpl.java
index 16155d2f1158b51213f1e14538a0cd03b3c974c5..3e4fb5fe74a47980eff4cf4d634c0305dde29874 100644
--- a/src/share/classes/java/net/SocksSocketImpl.java
+++ b/src/share/classes/java/net/SocksSocketImpl.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2000, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -315,7 +315,7 @@ class SocksSocketImpl extends PlainSocketImpl implements SocksConsts {
* grants the connections, then the connect is successful and all
* further traffic will go to the "real" endpoint.
*
- * @param endpoint the SocketAddress to connect to.
+ * @param endpoint the {@code SocketAddress} to connect to.
* @param timeout the timeout value in milliseconds
* @throws IOException if the connection can't be established.
* @throws SecurityException if there is a security manager and it
@@ -1032,9 +1032,9 @@ class SocksSocketImpl extends PlainSocketImpl implements SocksConsts {
/**
- * Returns the value of this socket's address field.
+ * Returns the value of this socket's {@code address} field.
*
- * @return the value of this socket's address field.
+ * @return the value of this socket's {@code address} field.
* @see java.net.SocketImpl#address
*/
@Override
@@ -1046,9 +1046,9 @@ class SocksSocketImpl extends PlainSocketImpl implements SocksConsts {
}
/**
- * Returns the value of this socket's port field.
+ * Returns the value of this socket's {@code port} field.
*
- * @return the value of this socket's port field.
+ * @return the value of this socket's {@code port} field.
* @see java.net.SocketImpl#port
*/
@Override
diff --git a/src/share/classes/java/net/URI.java b/src/share/classes/java/net/URI.java
index 24e1a979f6e134bb9cefecfc17923e614c6fc59d..77c2f7a178f4abe7ed14e0880543ee4e7e5208f6 100644
--- a/src/share/classes/java/net/URI.java
+++ b/src/share/classes/java/net/URI.java
@@ -67,24 +67,24 @@ import java.lang.NullPointerException; // for javadoc
* form has the syntax
*
*
- * [scheme:]scheme-specific-part[#fragment] + * [scheme{@code :}]scheme-specific-part[{@code #}fragment] ** * where square brackets [...] delineate optional components and the characters - * : and # stand for themselves. + * {@code :} and {@code #} stand for themselves. * *
An absolute URI specifies a scheme; a URI that is not absolute is * said to be relative. URIs are also classified according to whether * they are opaque or hierarchical. * *
An opaque URI is an absolute URI whose scheme-specific part does - * not begin with a slash character ('/'). Opaque URIs are not + * not begin with a slash character ({@code '/'}). Opaque URIs are not * subject to further parsing. Some examples of opaque URIs are: * *
* *- *
- * mailto:java-net@java.sun.com - * news:comp.lang.java + * urn:isbn:096139210x + * {@code mailto:java-net@java.sun.com} + * {@code news:comp.lang.java} * {@code urn:isbn:096139210x}
A hierarchical URI is either an absolute URI whose @@ -93,20 +93,20 @@ import java.lang.NullPointerException; // for javadoc * URIs are: * *
- * http://java.sun.com/j2se/1.3/* *
- * docs/guide/collections/designfaq.html#28
- * ../../../demo/jfc/SwingSet2/src/SwingSet2.java
- * file:///~/calendar + * {@code http://java.sun.com/j2se/1.3/}
+ * {@code docs/guide/collections/designfaq.html#28}
+ * {@code ../../../demo/jfc/SwingSet2/src/SwingSet2.java}
+ * {@code file:///~/calendar} *
A hierarchical URI is subject to further parsing according to the syntax * *
- * [scheme:][//authority][path][?query][#fragment] + * [scheme{@code :}][{@code //}authority][path][{@code ?}query][{@code #}fragment] ** - * where the characters :, /, - * ?, and # stand for themselves. The + * where the characters {@code :}, {@code /}, + * {@code ?}, and {@code #} stand for themselves. The * scheme-specific part of a hierarchical URI consists of the characters * between the scheme and fragment components. * @@ -115,16 +115,16 @@ import java.lang.NullPointerException; // for javadoc * parses according to the familiar syntax * *
- * [user-info@]host[:port] + * [user-info{@code @}]host[{@code :}port] ** - * where the characters @ and : stand for + * where the characters {@code @} and {@code :} stand for * themselves. Nearly all URI schemes currently in use are server-based. An * authority component that does not parse in this way is considered to be * registry-based. * *
The path component of a hierarchical URI is itself said to be absolute - * if it begins with a slash character ('/'); otherwise it is + * if it begins with a slash character ({@code '/'}); otherwise it is * relative. The path of a hierarchical URI that is either absolute or * specifies an authority is always absolute. * @@ -132,21 +132,21 @@ import java.lang.NullPointerException; // for javadoc * *
* * In a given instance any particular component is either undefined or * defined with a distinct value. Undefined string components are - * represented by null, while undefined integer components are - * represented by -1. A string component may be defined to have the + * represented by {@code null}, while undefined integer components are + * represented by {@code -1}. A string component may be defined to have the * empty string as its value; this is not equivalent to that component being * undefined. * @@ -165,10 +165,10 @@ import java.lang.NullPointerException; // for javadoc * The key operations supported by this class are those of * normalization, resolution, and relativization. * - **
- * Component Type - * scheme String - * scheme-specific-part String - * authority String - * user-info String - * host String - * port int - * path String - * query String + * fragment String + * scheme {@code String} + * scheme-specific-part {@code String} + * authority {@code String} + * user-info {@code String} + * host {@code String} + * port {@code int} + * path {@code String} + * query {@code String} * fragment {@code String}
Normalization is the process of removing unnecessary "." - * and ".." segments from the path component of a hierarchical URI. - * Each "." segment is simply removed. A ".." segment is - * removed only if it is preceded by a non-".." segment. + *
Normalization is the process of removing unnecessary {@code "."} + * and {@code ".."} segments from the path component of a hierarchical URI. + * Each {@code "."} segment is simply removed. A {@code ".."} segment is + * removed only if it is preceded by a non-{@code ".."} segment. * Normalization has no effect upon opaque URIs. * *
Resolution is the process of resolving one URI against another, @@ -179,45 +179,47 @@ import java.lang.NullPointerException; // for javadoc * normalized. The result, for example, of resolving * *
- * docs/guide/collections/designfaq.html#28 (1) + * {@code docs/guide/collections/designfaq.html#28} + * + * (1) ** - * against the base URI http://java.sun.com/j2se/1.3/ is the result + * against the base URI {@code http://java.sun.com/j2se/1.3/} is the result * URI * *
- * http://java.sun.com/j2se/1.3/docs/guide/collections/designfaq.html#28 + * {@code http://java.sun.com/j2se/1.3/docs/guide/collections/designfaq.html#28} ** * Resolving the relative URI * *
- * ../../../demo/jfc/SwingSet2/src/SwingSet2.java (2) + * {@code ../../../demo/jfc/SwingSet2/src/SwingSet2.java} (2) ** * against this result yields, in turn, * *
- * http://java.sun.com/j2se/1.3/demo/jfc/SwingSet2/src/SwingSet2.java + * {@code http://java.sun.com/j2se/1.3/demo/jfc/SwingSet2/src/SwingSet2.java} ** * Resolution of both absolute and relative URIs, and of both absolute and * relative paths in the case of hierarchical URIs, is supported. Resolving - * the URI file:///~calendar against any other URI simply yields the + * the URI {@code file:///~calendar} against any other URI simply yields the * original URI, since it is absolute. Resolving the relative URI (2) above * against the relative base URI (1) yields the normalized, but still relative, * URI * *
- * demo/jfc/SwingSet2/src/SwingSet2.java + * {@code demo/jfc/SwingSet2/src/SwingSet2.java} ** *
Relativization, finally, is the inverse of resolution: For any * two normalized URIs u and v, * *
- * u.relativize(u.resolve(v)).equals(v) and* * This operation is often useful when constructing a document containing URIs @@ -225,16 +227,16 @@ import java.lang.NullPointerException; // for javadoc * possible. For example, relativizing the URI * *
- * u.resolve(u.relativize(v)).equals(v) .
+ * u{@code .relativize(}u{@code .resolve(}v{@code )).equals(}v{@code )} and
+ * u{@code .resolve(}u{@code .relativize(}v{@code )).equals(}v{@code )} .
*
- * http://java.sun.com/j2se/1.3/docs/guide/index.html + * {@code http://java.sun.com/j2se/1.3/docs/guide/index.html} ** * against the base URI * *
- * http://java.sun.com/j2se/1.3 + * {@code http://java.sun.com/j2se/1.3} ** - * yields the relative URI docs/guide/index.html. + * yields the relative URI {@code docs/guide/index.html}. * * *