File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed
src/java.base/share/classes/java/nio Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -258,6 +258,15 @@ import jdk.internal.util.ArraysSupport;
258258 * cb.put("text/").put(subtype).put("; charset=").put(enc);</pre></blockquote>
259259 *
260260#end[char]
261+ * <h2> Optional operations </h2>
262+ * Methods specified as
263+ * <i>{@linkplain Buffer##read-only-buffers-heading optional
264+ * operations}</i> throw a {@linkplain ReadOnlyBufferException} when invoked
265+ * on a {@linkplain java.nio.Buffer#isReadOnly read-only} $Type$Buffer. The
266+ * methods {@linkplain #array array} and {@linkplain #arrayOffset arrayOffset}
267+ * throw an {@linkplain UnsupportedOperationException} if the $Type$Buffer is
268+ * not backed by an {@linkplain Buffer#hasArray accessible $type$ array}
269+ * (irrespective of whether the $Type$Buffer is read-only).
261270 *
262271 *
263272 * @author Mark Reinhold
You can’t perform that action at this time.
0 commit comments