Home
last modified time | relevance | path

Searched refs:first (Results 1 – 25 of 93) sorted by relevance

1234

/libcore/ojluni/src/main/java/sun/misc/
DCleaner.java72 static private Cleaner first = null; field in Cleaner
79 if (first != null) { in add()
80 cl.next = first; in add()
81 first.prev = cl; in add()
83 first = cl; in add()
94 if (first == cl) { in remove()
96 first = cl.next; in remove()
98 first = cl.prev; in remove()
/libcore/ojluni/src/main/java/java/util/concurrent/
DDelayQueue.java193 E first = q.peek(); in poll() local
194 return (first == null || first.getDelay(NANOSECONDS) > 0) in poll()
214 E first = q.peek(); in take() local
215 if (first == null) in take()
218 long delay = first.getDelay(NANOSECONDS); in take()
221 first = null; // don't retain ref while waiting in take()
259 E first = q.peek(); in poll() local
260 if (first == null) { in poll()
266 long delay = first.getDelay(NANOSECONDS); in poll()
271 first = null; // don't retain ref while waiting in poll()
[all …]
DScheduledThreadPoolExecutor.java1104 RunnableScheduledFuture<?> first = queue[0]; in poll() local
1105 return (first == null || first.getDelay(NANOSECONDS) > 0) in poll()
1107 : finishPoll(first); in poll()
1118 RunnableScheduledFuture<?> first = queue[0]; in take() local
1119 if (first == null) in take()
1122 long delay = first.getDelay(NANOSECONDS); in take()
1124 return finishPoll(first); in take()
1125 first = null; // don't retain ref while waiting in take()
1154 RunnableScheduledFuture<?> first = queue[0]; in poll() local
1155 if (first == null) { in poll()
[all …]
DLinkedBlockingDeque.java142 transient Node<E> first; field in LinkedBlockingDeque
221 Node<E> f = first; in linkFirst()
223 first = node; in linkFirst()
243 if (first == null) in linkLast()
244 first = node; in linkLast()
257 Node<E> f = first; in unlinkFirst()
264 first = n; in unlinkFirst()
288 first = null; in unlinkLast()
570 return (first == null) ? null : first.item; in peekFirst()
591 for (Node<E> p = first; p != null; p = p.next) { in removeFirstOccurrence()
[all …]
DConcurrentLinkedDeque.java528 private void unlinkFirst(Node<E> first, Node<E> next) { in unlinkFirst() argument
534 if (o != null && p.prev != p && first.casNext(next, p)) { in unlinkFirst()
536 if (first.prev == null && in unlinkFirst()
538 p.prev == first) { in unlinkFirst()
723 return (p == q) ? first() : q; in succ()
742 Node<E> first() { in first() method in ConcurrentLinkedDeque
903 for (Node<E> p = first(); p != null; p = succ(p)) { in peekFirst()
935 for (Node<E> p = first(); p != null; p = succ(p)) { in pollFirst()
1032 for (Node<E> p = first(); p != null; p = succ(p)) { in removeFirstOccurrence()
1076 for (Node<E> p = first(); p != null; p = succ(p)) { in contains()
[all …]
DConcurrentLinkedQueue.java389 Node<E> first() { in first() method in ConcurrentLinkedQueue
412 return first() == null; in isEmpty()
434 for (Node<E> p = first(); p != null;) { in size()
455 for (Node<E> p = first(); p != null; p = succ(p)) { in contains()
478 for (Node<E> p = first(); p != null; pred = p, p = next) { in remove()
566 for (Node<E> p = first(); p != null;) { in toString()
592 for (Node<E> p = first(); p != null;) { in toArrayInternal()
775 for (Node<E> p = first(); p != null; p = succ(p)) { in writeObject()
831 ((p = current) != null || (p = q.first()) != null) && in trySplit()
839 p = q.first(); in trySplit()
[all …]
/libcore/ojluni/src/main/java/java/util/jar/
DJarInputStream.java48 private JarEntry first; field in JarInputStream
86 first = checkManifest(e); in JarInputStream()
141 if (first == null) { in getNextEntry()
148 e = first; in getNextEntry()
149 if (first.getName().equalsIgnoreCase(JarIndex.INDEX_NAME)) in getNextEntry()
151 first = null; in getNextEntry()
206 if (first == null) { in read()
/libcore/ojluni/src/main/java/java/util/stream/
DStreams.java334 T first; field in Streams.StreamBuilderImpl
351 first = t; in StreamBuilderImpl()
360 first = t; in accept()
366 buffer.accept(first); in accept()
405 action.accept(first); in tryAdvance()
419 action.accept(first); in forEachRemaining()
430 int first; field in Streams.IntStreamBuilderImpl
447 first = t; in IntStreamBuilderImpl()
456 first = t; in accept()
462 buffer.accept(first); in accept()
[all …]
/libcore/ojluni/src/main/java/java/util/
DLinkedList.java94 transient Node<E> first; field in LinkedList
126 final Node<E> f = first; in linkFirst()
128 first = newNode; in linkFirst()
145 first = newNode; in linkLast()
161 first = newNode; in linkBefore()
177 first = next; in unlinkFirst()
198 first = null; in unlinkLast()
216 first = next; in unlink()
242 final Node<E> f = first; in getFirst()
268 final Node<E> f = first; in removeFirst()
[all …]
DArrayPrefixHelpers.java199 int first; in compute() local
202 first = org + 1; in compute()
206 first = l; in compute()
208 for (int i = first; i < h; ++i) // cumulate in compute()
351 int first; in compute() local
354 first = org + 1; in compute()
358 first = l; in compute()
360 for (int i = first; i < h; ++i) // cumulate in compute()
501 int first; in compute() local
504 first = org + 1; in compute()
[all …]
DEnumSet.java175 E first = i.next(); in copyOf() local
176 EnumSet<E> result = EnumSet.of(first); in copyOf()
336 public static <E extends Enum<E>> EnumSet<E> of(E first, E... rest) { in of() argument
337 EnumSet<E> result = noneOf(first.getDeclaringClass()); in of()
338 result.add(first); in of()
DHashMap.java567 Node<K,V>[] tab; Node<K,V> first, e; int n; K k; in getNode() local
569 (first = tab[(n - 1) & hash]) != null) { in getNode()
570 if (first.hash == hash && // always check first node in getNode()
571 ((k = first.key) == key || (key != null && key.equals(k)))) in getNode()
572 return first; in getNode()
573 if ((e = first.next) != null) { in getNode()
574 if (first instanceof TreeNode) in getNode()
575 return ((TreeNode<K,V>)first).getTreeNode(hash, key); in getNode()
1102 Node<K,V>[] tab; Node<K,V> first; int n, i; in computeIfAbsent() local
1109 if ((first = tab[i = (n - 1) & hash]) != null) { in computeIfAbsent()
[all …]
/libcore/ojluni/src/main/java/sun/security/util/
DObjectIdentifier.java150 int first = 0, second; in ObjectIdentifier() local
170 first = bignum.intValue(); in ObjectIdentifier()
173 checkSecondComponent(first, bignum); in ObjectIdentifier()
174 bignum = bignum.add(BigInteger.valueOf(40*first)); in ObjectIdentifier()
184 first = num; in ObjectIdentifier()
187 checkSecondComponent(first, num); in ObjectIdentifier()
188 num += 40 * first; in ObjectIdentifier()
623 private static void checkFirstComponent(int first) throws IOException { in checkFirstComponent() argument
624 if (first < 0 || first > 2) { in checkFirstComponent()
629 private static void checkFirstComponent(BigInteger first) throws IOException { in checkFirstComponent() argument
[all …]
/libcore/support/src/test/java/tests/util/
DPair.java31 private Pair(F first, S second) { in Pair() argument
32 mFirst = first; in Pair()
42 public static <F, S> Pair<F, S> of(F first, S second) { in of() argument
43 return new Pair<F, S>(first, second); in of()
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/io/
DFileWriterTest.java62 String first = "The first string for testing. "; in test_ConstructorLjava_io_FileZ() local
63 fileWriter.write(first); in test_ConstructorLjava_io_FileZ()
72 char[] out = new char[first.length() + second.length() + 10]; in test_ConstructorLjava_io_FileZ()
75 assertEquals(first + second, new String(out, 0, length)); in test_ConstructorLjava_io_FileZ()
78 first = "The first string for testing. "; in test_ConstructorLjava_io_FileZ()
79 fileWriter.write(first); in test_ConstructorLjava_io_FileZ()
88 out = new char[first.length() + second.length() + 10]; in test_ConstructorLjava_io_FileZ()
/libcore/luni/src/main/java/libcore/icu/
DICU.java79 final int first = string.indexOf('_'); in parseLangScriptRegionAndVariants() local
80 final int second = string.indexOf('_', first + 1); in parseLangScriptRegionAndVariants()
83 if (first == -1) { in parseLangScriptRegionAndVariants()
90 outputArray[IDX_LANGUAGE] = string.substring(0, first); in parseLangScriptRegionAndVariants()
91 final String secondString = string.substring(first + 1); in parseLangScriptRegionAndVariants()
111 outputArray[IDX_LANGUAGE] = string.substring(0, first); in parseLangScriptRegionAndVariants()
112 final String secondString = string.substring(first + 1, second); in parseLangScriptRegionAndVariants()
134 outputArray[IDX_VARIANT] = string.substring(first + 1); in parseLangScriptRegionAndVariants()
141 outputArray[IDX_LANGUAGE] = string.substring(0, first); in parseLangScriptRegionAndVariants()
142 final String secondString = string.substring(first + 1, second); in parseLangScriptRegionAndVariants()
/libcore/ojluni/src/test/java/time/test/java/time/chrono/
DTestExampleCode.java105 ChronoLocalDate first = now1 in test_chronoPackageExample() local
108 ChronoLocalDate last = first in test_chronoPackageExample()
112 first, last); in test_chronoPackageExample()
158 ThaiBuddhistDate first = now1 in test_calendarPackageExample() local
161 ThaiBuddhistDate last = first in test_calendarPackageExample()
165 first, last); in test_calendarPackageExample()
/libcore/ojluni/src/main/java/java/nio/file/
DPaths.java83 public static Path get(String first, String... more) { in get() argument
84 return FileSystems.getDefault().getPath(first, more); in get()
/libcore/ojluni/src/main/java/java/util/concurrent/locks/
DAbstractQueuedLongSynchronizer.java1426 private void doSignal(Node first) { in doSignal() argument
1428 if ( (firstWaiter = first.nextWaiter) == null) in doSignal()
1430 first.nextWaiter = null; in doSignal()
1431 } while (!transferForSignal(first) && in doSignal()
1432 (first = firstWaiter) != null); in doSignal()
1439 private void doSignalAll(Node first) { in doSignalAll() argument
1442 Node next = first.nextWaiter; in doSignalAll()
1443 first.nextWaiter = null; in doSignalAll()
1444 transferForSignal(first); in doSignalAll()
1445 first = next; in doSignalAll()
[all …]
DAbstractQueuedSynchronizer.java1890 private void doSignal(Node first) { in doSignal() argument
1892 if ( (firstWaiter = first.nextWaiter) == null) in doSignal()
1894 first.nextWaiter = null; in doSignal()
1895 } while (!transferForSignal(first) && in doSignal()
1896 (first = firstWaiter) != null); in doSignal()
1903 private void doSignalAll(Node first) { in doSignalAll() argument
1906 Node next = first.nextWaiter; in doSignalAll()
1907 first.nextWaiter = null; in doSignalAll()
1908 transferForSignal(first); in doSignalAll()
1909 first = next; in doSignalAll()
[all …]
/libcore/luni/src/test/java/libcore/util/
DZoneInfoDBTest.java217 ZoneInfo first = data.makeTimeZone(tzId); in testMakeTimeZone_timeZoneMutability() local
219 assertNotSame(first, second); in testMakeTimeZone_timeZoneMutability()
221 assertTrue(first.hasSameRules(second)); in testMakeTimeZone_timeZoneMutability()
223 first.setID("Not Europe/London"); in testMakeTimeZone_timeZoneMutability()
225 assertFalse(first.getID().equals(second.getID())); in testMakeTimeZone_timeZoneMutability()
227 first.setRawOffset(3600); in testMakeTimeZone_timeZoneMutability()
228 assertFalse(first.getRawOffset() == second.getRawOffset()); in testMakeTimeZone_timeZoneMutability()
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/text/
DAttributedCharacterIteratorTest.java53 assertEquals("Wrong first1", 'T', it.first()); in test_first()
55 assertEquals("Wrong first2", 'T', it.first()); in test_first()
57 assertEquals("Wrong first3", 's', it.first()); in test_first()
59 assertTrue("Wrong first4", it.first() == CharacterIterator.DONE); in test_first()
/libcore/luni/src/test/java/libcore/java/util/
DTimSortTest.java30 public int compare(Integer first, Integer second) {
31 return first.compareTo(second);
/libcore/ojluni/src/main/java/sun/nio/fs/
DUnixUriUtils.java160 private static long lowMask(char first, char last) { in lowMask() argument
162 int f = Math.max(Math.min(first, 63), 0); in lowMask()
171 private static long highMask(char first, char last) { in highMask() argument
173 int f = Math.max(Math.min(first, 127), 64) - 64; in highMask()
/libcore/ojluni/src/main/java/java/text/
DIcuIteratorWrapper.java271 public int first() { in first() method in IcuIteratorWrapper
272 return wrapped.first(); in first()

1234