1 /* 2 * Copyright (C) 2014 The Android Open Source Project 3 * Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved. 4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 5 * 6 * This code is free software; you can redistribute it and/or modify it 7 * under the terms of the GNU General Public License version 2 only, as 8 * published by the Free Software Foundation. Oracle designates this 9 * particular file as subject to the "Classpath" exception as provided 10 * by Oracle in the LICENSE file that accompanied this code. 11 * 12 * This code is distributed in the hope that it will be useful, but WITHOUT 13 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 14 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 15 * version 2 for more details (a copy is included in the LICENSE file that 16 * accompanied this code). 17 * 18 * You should have received a copy of the GNU General Public License version 19 * 2 along with this work; if not, write to the Free Software Foundation, 20 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 21 * 22 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 23 * or visit www.oracle.com if you need additional information or have any 24 * questions. 25 */ 26 27 package java.nio; 28 29 import android.compat.annotation.UnsupportedAppUsage; 30 31 @SuppressWarnings({"unchecked", "deprecation", "all"}) 32 public class DirectByteBuffer extends java.nio.MappedByteBuffer implements sun.nio.ch.DirectBuffer { 33 DirectByteBuffer(int capacity, java.nio.DirectByteBuffer.MemoryRef memoryRef)34 DirectByteBuffer(int capacity, java.nio.DirectByteBuffer.MemoryRef memoryRef) { 35 super(0, 0, 0, 0); 36 throw new RuntimeException("Stub!"); 37 } 38 39 @UnsupportedAppUsage(maxTargetSdk = 30, trackingBug = 170729553) DirectByteBuffer(long addr, int cap)40 private DirectByteBuffer(long addr, int cap) { 41 super(0, 0, 0, 0); 42 throw new RuntimeException("Stub!"); 43 } 44 DirectByteBuffer( int cap, long addr, java.io.FileDescriptor fd, java.lang.Runnable unmapper, boolean isReadOnly)45 public DirectByteBuffer( 46 int cap, 47 long addr, 48 java.io.FileDescriptor fd, 49 java.lang.Runnable unmapper, 50 boolean isReadOnly) { 51 super(0, 0, 0, 0); 52 throw new RuntimeException("Stub!"); 53 } 54 DirectByteBuffer( java.nio.DirectByteBuffer.MemoryRef memoryRef, int mark, int pos, int lim, int cap, int off)55 DirectByteBuffer( 56 java.nio.DirectByteBuffer.MemoryRef memoryRef, 57 int mark, 58 int pos, 59 int lim, 60 int cap, 61 int off) { 62 super(0, 0, 0, 0); 63 throw new RuntimeException("Stub!"); 64 } 65 DirectByteBuffer( java.nio.DirectByteBuffer.MemoryRef memoryRef, int mark, int pos, int lim, int cap, int off, boolean isReadOnly)66 DirectByteBuffer( 67 java.nio.DirectByteBuffer.MemoryRef memoryRef, 68 int mark, 69 int pos, 70 int lim, 71 int cap, 72 int off, 73 boolean isReadOnly) { 74 super(0, 0, 0, 0); 75 throw new RuntimeException("Stub!"); 76 } 77 attachment()78 public final java.lang.Object attachment() { 79 throw new RuntimeException("Stub!"); 80 } 81 82 @UnsupportedAppUsage cleaner()83 public final sun.misc.Cleaner cleaner() { 84 throw new RuntimeException("Stub!"); 85 } 86 slice()87 public final java.nio.ByteBuffer slice() { 88 throw new RuntimeException("Stub!"); 89 } 90 duplicate()91 public final java.nio.ByteBuffer duplicate() { 92 throw new RuntimeException("Stub!"); 93 } 94 asReadOnlyBuffer()95 public final java.nio.ByteBuffer asReadOnlyBuffer() { 96 throw new RuntimeException("Stub!"); 97 } 98 address()99 public final long address() { 100 throw new RuntimeException("Stub!"); 101 } 102 ix(int i)103 private long ix(int i) { 104 throw new RuntimeException("Stub!"); 105 } 106 get(long a)107 private byte get(long a) { 108 throw new RuntimeException("Stub!"); 109 } 110 get()111 public final byte get() { 112 throw new RuntimeException("Stub!"); 113 } 114 get(int i)115 public final byte get(int i) { 116 throw new RuntimeException("Stub!"); 117 } 118 get(byte[] dst, int dstOffset, int length)119 public java.nio.ByteBuffer get(byte[] dst, int dstOffset, int length) { 120 throw new RuntimeException("Stub!"); 121 } 122 put(long a, byte x)123 private java.nio.ByteBuffer put(long a, byte x) { 124 throw new RuntimeException("Stub!"); 125 } 126 put(java.nio.ByteBuffer src)127 public java.nio.ByteBuffer put(java.nio.ByteBuffer src) { 128 throw new RuntimeException("Stub!"); 129 } 130 put(byte x)131 public final java.nio.ByteBuffer put(byte x) { 132 throw new RuntimeException("Stub!"); 133 } 134 put(int i, byte x)135 public final java.nio.ByteBuffer put(int i, byte x) { 136 throw new RuntimeException("Stub!"); 137 } 138 put(byte[] src, int srcOffset, int length)139 public java.nio.ByteBuffer put(byte[] src, int srcOffset, int length) { 140 throw new RuntimeException("Stub!"); 141 } 142 compact()143 public final java.nio.ByteBuffer compact() { 144 throw new RuntimeException("Stub!"); 145 } 146 isDirect()147 public final boolean isDirect() { 148 throw new RuntimeException("Stub!"); 149 } 150 isReadOnly()151 public final boolean isReadOnly() { 152 throw new RuntimeException("Stub!"); 153 } 154 _get(int i)155 final byte _get(int i) { 156 throw new RuntimeException("Stub!"); 157 } 158 _put(int i, byte b)159 final void _put(int i, byte b) { 160 throw new RuntimeException("Stub!"); 161 } 162 getChar()163 public final char getChar() { 164 throw new RuntimeException("Stub!"); 165 } 166 getChar(int i)167 public final char getChar(int i) { 168 throw new RuntimeException("Stub!"); 169 } 170 getCharUnchecked(int i)171 char getCharUnchecked(int i) { 172 throw new RuntimeException("Stub!"); 173 } 174 getUnchecked(int pos, char[] dst, int dstOffset, int length)175 void getUnchecked(int pos, char[] dst, int dstOffset, int length) { 176 throw new RuntimeException("Stub!"); 177 } 178 putChar(long a, char x)179 private java.nio.ByteBuffer putChar(long a, char x) { 180 throw new RuntimeException("Stub!"); 181 } 182 putChar(char x)183 public final java.nio.ByteBuffer putChar(char x) { 184 throw new RuntimeException("Stub!"); 185 } 186 putChar(int i, char x)187 public final java.nio.ByteBuffer putChar(int i, char x) { 188 throw new RuntimeException("Stub!"); 189 } 190 putCharUnchecked(int i, char x)191 void putCharUnchecked(int i, char x) { 192 throw new RuntimeException("Stub!"); 193 } 194 putUnchecked(int pos, char[] src, int srcOffset, int length)195 void putUnchecked(int pos, char[] src, int srcOffset, int length) { 196 throw new RuntimeException("Stub!"); 197 } 198 asCharBuffer()199 public final java.nio.CharBuffer asCharBuffer() { 200 throw new RuntimeException("Stub!"); 201 } 202 getShort(long a)203 private short getShort(long a) { 204 throw new RuntimeException("Stub!"); 205 } 206 getShort()207 public final short getShort() { 208 throw new RuntimeException("Stub!"); 209 } 210 getShort(int i)211 public final short getShort(int i) { 212 throw new RuntimeException("Stub!"); 213 } 214 getShortUnchecked(int i)215 short getShortUnchecked(int i) { 216 throw new RuntimeException("Stub!"); 217 } 218 getUnchecked(int pos, short[] dst, int dstOffset, int length)219 void getUnchecked(int pos, short[] dst, int dstOffset, int length) { 220 throw new RuntimeException("Stub!"); 221 } 222 putShort(long a, short x)223 private java.nio.ByteBuffer putShort(long a, short x) { 224 throw new RuntimeException("Stub!"); 225 } 226 putShort(short x)227 public final java.nio.ByteBuffer putShort(short x) { 228 throw new RuntimeException("Stub!"); 229 } 230 putShort(int i, short x)231 public final java.nio.ByteBuffer putShort(int i, short x) { 232 throw new RuntimeException("Stub!"); 233 } 234 putShortUnchecked(int i, short x)235 void putShortUnchecked(int i, short x) { 236 throw new RuntimeException("Stub!"); 237 } 238 putUnchecked(int pos, short[] src, int srcOffset, int length)239 void putUnchecked(int pos, short[] src, int srcOffset, int length) { 240 throw new RuntimeException("Stub!"); 241 } 242 asShortBuffer()243 public final java.nio.ShortBuffer asShortBuffer() { 244 throw new RuntimeException("Stub!"); 245 } 246 getInt(long a)247 private int getInt(long a) { 248 throw new RuntimeException("Stub!"); 249 } 250 getInt()251 public int getInt() { 252 throw new RuntimeException("Stub!"); 253 } 254 getInt(int i)255 public int getInt(int i) { 256 throw new RuntimeException("Stub!"); 257 } 258 getIntUnchecked(int i)259 final int getIntUnchecked(int i) { 260 throw new RuntimeException("Stub!"); 261 } 262 getUnchecked(int pos, int[] dst, int dstOffset, int length)263 final void getUnchecked(int pos, int[] dst, int dstOffset, int length) { 264 throw new RuntimeException("Stub!"); 265 } 266 putInt(long a, int x)267 private java.nio.ByteBuffer putInt(long a, int x) { 268 throw new RuntimeException("Stub!"); 269 } 270 putInt(int x)271 public final java.nio.ByteBuffer putInt(int x) { 272 throw new RuntimeException("Stub!"); 273 } 274 putInt(int i, int x)275 public final java.nio.ByteBuffer putInt(int i, int x) { 276 throw new RuntimeException("Stub!"); 277 } 278 putIntUnchecked(int i, int x)279 final void putIntUnchecked(int i, int x) { 280 throw new RuntimeException("Stub!"); 281 } 282 putUnchecked(int pos, int[] src, int srcOffset, int length)283 final void putUnchecked(int pos, int[] src, int srcOffset, int length) { 284 throw new RuntimeException("Stub!"); 285 } 286 asIntBuffer()287 public final java.nio.IntBuffer asIntBuffer() { 288 throw new RuntimeException("Stub!"); 289 } 290 getLong(long a)291 private long getLong(long a) { 292 throw new RuntimeException("Stub!"); 293 } 294 getLong()295 public final long getLong() { 296 throw new RuntimeException("Stub!"); 297 } 298 getLong(int i)299 public final long getLong(int i) { 300 throw new RuntimeException("Stub!"); 301 } 302 getLongUnchecked(int i)303 final long getLongUnchecked(int i) { 304 throw new RuntimeException("Stub!"); 305 } 306 getUnchecked(int pos, long[] dst, int dstOffset, int length)307 final void getUnchecked(int pos, long[] dst, int dstOffset, int length) { 308 throw new RuntimeException("Stub!"); 309 } 310 putLong(long a, long x)311 private java.nio.ByteBuffer putLong(long a, long x) { 312 throw new RuntimeException("Stub!"); 313 } 314 putLong(long x)315 public final java.nio.ByteBuffer putLong(long x) { 316 throw new RuntimeException("Stub!"); 317 } 318 putLong(int i, long x)319 public final java.nio.ByteBuffer putLong(int i, long x) { 320 throw new RuntimeException("Stub!"); 321 } 322 putLongUnchecked(int i, long x)323 final void putLongUnchecked(int i, long x) { 324 throw new RuntimeException("Stub!"); 325 } 326 putUnchecked(int pos, long[] src, int srcOffset, int length)327 final void putUnchecked(int pos, long[] src, int srcOffset, int length) { 328 throw new RuntimeException("Stub!"); 329 } 330 asLongBuffer()331 public final java.nio.LongBuffer asLongBuffer() { 332 throw new RuntimeException("Stub!"); 333 } 334 getFloat(long a)335 private float getFloat(long a) { 336 throw new RuntimeException("Stub!"); 337 } 338 getFloat()339 public final float getFloat() { 340 throw new RuntimeException("Stub!"); 341 } 342 getFloat(int i)343 public final float getFloat(int i) { 344 throw new RuntimeException("Stub!"); 345 } 346 getFloatUnchecked(int i)347 final float getFloatUnchecked(int i) { 348 throw new RuntimeException("Stub!"); 349 } 350 getUnchecked(int pos, float[] dst, int dstOffset, int length)351 final void getUnchecked(int pos, float[] dst, int dstOffset, int length) { 352 throw new RuntimeException("Stub!"); 353 } 354 putFloat(long a, float x)355 private java.nio.ByteBuffer putFloat(long a, float x) { 356 throw new RuntimeException("Stub!"); 357 } 358 putFloat(float x)359 public final java.nio.ByteBuffer putFloat(float x) { 360 throw new RuntimeException("Stub!"); 361 } 362 putFloat(int i, float x)363 public final java.nio.ByteBuffer putFloat(int i, float x) { 364 throw new RuntimeException("Stub!"); 365 } 366 putFloatUnchecked(int i, float x)367 final void putFloatUnchecked(int i, float x) { 368 throw new RuntimeException("Stub!"); 369 } 370 putUnchecked(int pos, float[] src, int srcOffset, int length)371 final void putUnchecked(int pos, float[] src, int srcOffset, int length) { 372 throw new RuntimeException("Stub!"); 373 } 374 asFloatBuffer()375 public final java.nio.FloatBuffer asFloatBuffer() { 376 throw new RuntimeException("Stub!"); 377 } 378 getDouble(long a)379 private double getDouble(long a) { 380 throw new RuntimeException("Stub!"); 381 } 382 getDouble()383 public final double getDouble() { 384 throw new RuntimeException("Stub!"); 385 } 386 getDouble(int i)387 public final double getDouble(int i) { 388 throw new RuntimeException("Stub!"); 389 } 390 getDoubleUnchecked(int i)391 final double getDoubleUnchecked(int i) { 392 throw new RuntimeException("Stub!"); 393 } 394 getUnchecked(int pos, double[] dst, int dstOffset, int length)395 final void getUnchecked(int pos, double[] dst, int dstOffset, int length) { 396 throw new RuntimeException("Stub!"); 397 } 398 putDouble(long a, double x)399 private java.nio.ByteBuffer putDouble(long a, double x) { 400 throw new RuntimeException("Stub!"); 401 } 402 putDouble(double x)403 public final java.nio.ByteBuffer putDouble(double x) { 404 throw new RuntimeException("Stub!"); 405 } 406 putDouble(int i, double x)407 public final java.nio.ByteBuffer putDouble(int i, double x) { 408 throw new RuntimeException("Stub!"); 409 } 410 putDoubleUnchecked(int i, double x)411 final void putDoubleUnchecked(int i, double x) { 412 throw new RuntimeException("Stub!"); 413 } 414 putUnchecked(int pos, double[] src, int srcOffset, int length)415 final void putUnchecked(int pos, double[] src, int srcOffset, int length) { 416 throw new RuntimeException("Stub!"); 417 } 418 asDoubleBuffer()419 public final java.nio.DoubleBuffer asDoubleBuffer() { 420 throw new RuntimeException("Stub!"); 421 } 422 isAccessible()423 public final boolean isAccessible() { 424 throw new RuntimeException("Stub!"); 425 } 426 setAccessible(boolean value)427 public final void setAccessible(boolean value) { 428 throw new RuntimeException("Stub!"); 429 } 430 431 final sun.misc.Cleaner cleaner; 432 433 { 434 cleaner = null; 435 } 436 437 final java.nio.DirectByteBuffer.MemoryRef memoryRef; 438 439 { 440 memoryRef = null; 441 } 442 443 @SuppressWarnings({"unchecked", "deprecation", "all"}) 444 static final class MemoryRef { 445 MemoryRef(int capacity)446 MemoryRef(int capacity) { 447 throw new RuntimeException("Stub!"); 448 } 449 MemoryRef(long allocatedAddress, java.lang.Object originalBufferObject)450 MemoryRef(long allocatedAddress, java.lang.Object originalBufferObject) { 451 throw new RuntimeException("Stub!"); 452 } 453 free()454 void free() { 455 throw new RuntimeException("Stub!"); 456 } 457 458 long allocatedAddress; 459 460 byte[] buffer; 461 462 boolean isAccessible; 463 464 boolean isFreed; 465 466 final int offset; 467 468 { 469 offset = 0; 470 } 471 472 final java.lang.Object originalBufferObject; 473 474 { 475 originalBufferObject = null; 476 } 477 } 478 } 479