Home
last modified time | relevance | path

Searched refs:thunk (Results 1 – 14 of 14) sorted by relevance

/libcore/ojluni/src/main/java/sun/misc/
DCleaner.java111 private final Runnable thunk; field in Cleaner
113 private Cleaner(Object referent, Runnable thunk) { in Cleaner() argument
115 this.thunk = thunk; in Cleaner()
142 return thunk; in getThunk()
157 public static Cleaner create(Object ob, Runnable thunk) { in create() argument
158 if (thunk == null) in create()
160 return add(new Cleaner(ob, thunk)); in create()
170 thunk.run(); in clean()
/libcore/ojluni/src/main/java/jdk/internal/ref/
DCleaner.java112 private final Runnable thunk; field in Cleaner
114 private Cleaner(Object referent, Runnable thunk) { in Cleaner() argument
116 this.thunk = thunk; in Cleaner()
130 public static Cleaner create(Object ob, Runnable thunk) { in create() argument
131 if (thunk == null) in create()
133 return add(new Cleaner(ob, thunk)); in create()
143 thunk.run(); in clean()
/libcore/ojluni/annotations/hiddenapi/sun/misc/
DCleaner.java33 private Cleaner(java.lang.Object referent, java.lang.Runnable thunk) { in Cleaner() argument
47 public static sun.misc.Cleaner create(java.lang.Object ob, java.lang.Runnable thunk) { in create() argument
68 private final java.lang.Runnable thunk; field in Cleaner
71 thunk = null;
/libcore/luni/src/main/java/libcore/util/
DNativeAllocationRegistry.java267 CleanerThunk thunk; in registerNativeAllocation() local
270 thunk = new CleanerThunk(); in registerNativeAllocation()
271 Cleaner cleaner = Cleaner.create(referent, thunk); in registerNativeAllocation()
279 thunk.setNativePtr(nativePtr); in registerNativeAllocation()
/libcore/ojluni/src/test/java/nio/Buffer/
DBasicInt.java565 private static void catchNullArgument(Buffer b, Runnable thunk) { in catchNullArgument() argument
566 tryCatch(b, NullPointerException.class, thunk); in catchNullArgument()
569 private static void catchIllegalArgument(Buffer b, Runnable thunk) { in catchIllegalArgument() argument
570 tryCatch(b, IllegalArgumentException.class, thunk); in catchIllegalArgument()
573 private static void catchReadOnlyBuffer(Buffer b, Runnable thunk) { in catchReadOnlyBuffer() argument
574 tryCatch(b, ReadOnlyBufferException.class, thunk); in catchReadOnlyBuffer()
577 private static void catchIndexOutOfBounds(Buffer b, Runnable thunk) { in catchIndexOutOfBounds() argument
578 tryCatch(b, IndexOutOfBoundsException.class, thunk); in catchIndexOutOfBounds()
581 private static void catchIndexOutOfBounds(int[] t, Runnable thunk) { in catchIndexOutOfBounds() argument
582 tryCatch(t, IndexOutOfBoundsException.class, thunk); in catchIndexOutOfBounds()
[all …]
DBasicShort.java565 private static void catchNullArgument(Buffer b, Runnable thunk) { in catchNullArgument() argument
566 tryCatch(b, NullPointerException.class, thunk); in catchNullArgument()
569 private static void catchIllegalArgument(Buffer b, Runnable thunk) { in catchIllegalArgument() argument
570 tryCatch(b, IllegalArgumentException.class, thunk); in catchIllegalArgument()
573 private static void catchReadOnlyBuffer(Buffer b, Runnable thunk) { in catchReadOnlyBuffer() argument
574 tryCatch(b, ReadOnlyBufferException.class, thunk); in catchReadOnlyBuffer()
577 private static void catchIndexOutOfBounds(Buffer b, Runnable thunk) { in catchIndexOutOfBounds() argument
578 tryCatch(b, IndexOutOfBoundsException.class, thunk); in catchIndexOutOfBounds()
581 private static void catchIndexOutOfBounds(short[] t, Runnable thunk) { in catchIndexOutOfBounds() argument
582 tryCatch(t, IndexOutOfBoundsException.class, thunk); in catchIndexOutOfBounds()
[all …]
DBasicLong.java565 private static void catchNullArgument(Buffer b, Runnable thunk) { in catchNullArgument() argument
566 tryCatch(b, NullPointerException.class, thunk); in catchNullArgument()
569 private static void catchIllegalArgument(Buffer b, Runnable thunk) { in catchIllegalArgument() argument
570 tryCatch(b, IllegalArgumentException.class, thunk); in catchIllegalArgument()
573 private static void catchReadOnlyBuffer(Buffer b, Runnable thunk) { in catchReadOnlyBuffer() argument
574 tryCatch(b, ReadOnlyBufferException.class, thunk); in catchReadOnlyBuffer()
577 private static void catchIndexOutOfBounds(Buffer b, Runnable thunk) { in catchIndexOutOfBounds() argument
578 tryCatch(b, IndexOutOfBoundsException.class, thunk); in catchIndexOutOfBounds()
581 private static void catchIndexOutOfBounds(long[] t, Runnable thunk) { in catchIndexOutOfBounds() argument
582 tryCatch(t, IndexOutOfBoundsException.class, thunk); in catchIndexOutOfBounds()
[all …]
DBasicFloat.java565 private static void catchNullArgument(Buffer b, Runnable thunk) { in catchNullArgument() argument
566 tryCatch(b, NullPointerException.class, thunk); in catchNullArgument()
569 private static void catchIllegalArgument(Buffer b, Runnable thunk) { in catchIllegalArgument() argument
570 tryCatch(b, IllegalArgumentException.class, thunk); in catchIllegalArgument()
573 private static void catchReadOnlyBuffer(Buffer b, Runnable thunk) { in catchReadOnlyBuffer() argument
574 tryCatch(b, ReadOnlyBufferException.class, thunk); in catchReadOnlyBuffer()
577 private static void catchIndexOutOfBounds(Buffer b, Runnable thunk) { in catchIndexOutOfBounds() argument
578 tryCatch(b, IndexOutOfBoundsException.class, thunk); in catchIndexOutOfBounds()
581 private static void catchIndexOutOfBounds(float[] t, Runnable thunk) { in catchIndexOutOfBounds() argument
582 tryCatch(t, IndexOutOfBoundsException.class, thunk); in catchIndexOutOfBounds()
[all …]
DBasicDouble.java565 private static void catchNullArgument(Buffer b, Runnable thunk) { in catchNullArgument() argument
566 tryCatch(b, NullPointerException.class, thunk); in catchNullArgument()
569 private static void catchIllegalArgument(Buffer b, Runnable thunk) { in catchIllegalArgument() argument
570 tryCatch(b, IllegalArgumentException.class, thunk); in catchIllegalArgument()
573 private static void catchReadOnlyBuffer(Buffer b, Runnable thunk) { in catchReadOnlyBuffer() argument
574 tryCatch(b, ReadOnlyBufferException.class, thunk); in catchReadOnlyBuffer()
577 private static void catchIndexOutOfBounds(Buffer b, Runnable thunk) { in catchIndexOutOfBounds() argument
578 tryCatch(b, IndexOutOfBoundsException.class, thunk); in catchIndexOutOfBounds()
581 private static void catchIndexOutOfBounds(double[] t, Runnable thunk) { in catchIndexOutOfBounds() argument
582 tryCatch(t, IndexOutOfBoundsException.class, thunk); in catchIndexOutOfBounds()
[all …]
DBasicChar.java565 private static void catchNullArgument(Buffer b, Runnable thunk) { in catchNullArgument() argument
566 tryCatch(b, NullPointerException.class, thunk); in catchNullArgument()
569 private static void catchIllegalArgument(Buffer b, Runnable thunk) { in catchIllegalArgument() argument
570 tryCatch(b, IllegalArgumentException.class, thunk); in catchIllegalArgument()
573 private static void catchReadOnlyBuffer(Buffer b, Runnable thunk) { in catchReadOnlyBuffer() argument
574 tryCatch(b, ReadOnlyBufferException.class, thunk); in catchReadOnlyBuffer()
577 private static void catchIndexOutOfBounds(Buffer b, Runnable thunk) { in catchIndexOutOfBounds() argument
578 tryCatch(b, IndexOutOfBoundsException.class, thunk); in catchIndexOutOfBounds()
581 private static void catchIndexOutOfBounds(char[] t, Runnable thunk) { in catchIndexOutOfBounds() argument
582 tryCatch(t, IndexOutOfBoundsException.class, thunk); in catchIndexOutOfBounds()
[all …]
DBasicByte.java565 private static void catchNullArgument(Buffer b, Runnable thunk) { in catchNullArgument() argument
566 tryCatch(b, NullPointerException.class, thunk); in catchNullArgument()
569 private static void catchIllegalArgument(Buffer b, Runnable thunk) { in catchIllegalArgument() argument
570 tryCatch(b, IllegalArgumentException.class, thunk); in catchIllegalArgument()
573 private static void catchReadOnlyBuffer(Buffer b, Runnable thunk) { in catchReadOnlyBuffer() argument
574 tryCatch(b, ReadOnlyBufferException.class, thunk); in catchReadOnlyBuffer()
577 private static void catchIndexOutOfBounds(Buffer b, Runnable thunk) { in catchIndexOutOfBounds() argument
578 tryCatch(b, IndexOutOfBoundsException.class, thunk); in catchIndexOutOfBounds()
581 private static void catchIndexOutOfBounds(byte[] t, Runnable thunk) { in catchIndexOutOfBounds() argument
582 tryCatch(t, IndexOutOfBoundsException.class, thunk); in catchIndexOutOfBounds()
[all …]
DBasic-X.java.template565 private static void catchNullArgument(Buffer b, Runnable thunk) {
566 tryCatch(b, NullPointerException.class, thunk);
569 private static void catchIllegalArgument(Buffer b, Runnable thunk) {
570 tryCatch(b, IllegalArgumentException.class, thunk);
573 private static void catchReadOnlyBuffer(Buffer b, Runnable thunk) {
574 tryCatch(b, ReadOnlyBufferException.class, thunk);
577 private static void catchIndexOutOfBounds(Buffer b, Runnable thunk) {
578 tryCatch(b, IndexOutOfBoundsException.class, thunk);
581 private static void catchIndexOutOfBounds($type$[] t, Runnable thunk) {
582 tryCatch(t, IndexOutOfBoundsException.class, thunk);
[all …]
/libcore/ojluni/annotations/mmodule/sun/misc/
DCleaner.annotated.java37 Cleaner(java.lang.Object referent, java.lang.Runnable thunk) { super(null, null); throw new Runtime… in Cleaner() argument
41 public static sun.misc.Cleaner create(java.lang.Object ob, java.lang.Runnable thunk) { throw new Ru… in create() argument
/libcore/ojluni/src/main/java/sun/nio/fs/
DPollingWatchService.java288 Runnable thunk = new Runnable() { public void run() { poll(); }};
290 .scheduleAtFixedRate(thunk, period, period, TimeUnit.SECONDS);