/libcore/luni/src/test/java/libcore/javax/net/ssl/ |
D | SSLParametersTest.java | 26 SSLParameters p = new SSLParameters(); in test_SSLParameters_emptyConstructor() local 27 assertNull(p.getCipherSuites()); in test_SSLParameters_emptyConstructor() 28 assertNull(p.getProtocols()); in test_SSLParameters_emptyConstructor() 29 assertFalse(p.getWantClientAuth()); in test_SSLParameters_emptyConstructor() 30 assertFalse(p.getNeedClientAuth()); in test_SSLParameters_emptyConstructor() 35 SSLParameters p = new SSLParameters(cipherSuites); in test_SSLParameters_cipherSuitesConstructor() local 36 assertNotNull(p.getCipherSuites()); in test_SSLParameters_cipherSuitesConstructor() 37 assertNotSame(cipherSuites, p.getCipherSuites()); in test_SSLParameters_cipherSuitesConstructor() 38 assertEquals(Arrays.asList(cipherSuites), Arrays.asList(p.getCipherSuites())); in test_SSLParameters_cipherSuitesConstructor() 39 assertNull(p.getProtocols()); in test_SSLParameters_cipherSuitesConstructor() [all …]
|
/libcore/luni/src/main/java/java/util/concurrent/ |
D | ConcurrentLinkedDeque.java | 330 for (Node<E> h = head, p = h, q;;) { in linkFirst() 331 if ((q = p.prev) != null && in linkFirst() 332 (q = (p = q).prev) != null) in linkFirst() 335 p = (h != (h = head)) ? h : q; in linkFirst() 336 else if (p.next == p) // PREV_TERMINATOR in linkFirst() 340 newNode.lazySetNext(p); // CAS piggyback in linkFirst() 341 if (p.casPrev(null, newNode)) { in linkFirst() 345 if (p != h) // hop two nodes at a time in linkFirst() 363 for (Node<E> t = tail, p = t, q;;) { in linkLast() 364 if ((q = p.next) != null && in linkLast() [all …]
|
D | ConcurrentLinkedQueue.java | 272 final void updateHead(Node<E> h, Node<E> p) { in updateHead() argument 273 if (h != p && casHead(h, p)) in updateHead() 282 final Node<E> succ(Node<E> p) { in succ() argument 283 Node<E> next = p.next; in succ() 284 return (p == next) ? head : next; in succ() 298 for (Node<E> t = tail, p = t;;) { in offer() 299 Node<E> q = p.next; in offer() 302 if (p.casNext(null, newNode)) { in offer() 306 if (p != t) // hop two nodes at a time in offer() 312 else if (p == q) in offer() [all …]
|
D | LinkedTransferQueue.java | 583 for (Node h = head, p = h; p != null;) { // find & match first node in xfer() 584 boolean isData = p.isData; in xfer() 585 Object item = p.item; in xfer() 586 if (item != p && (item != null) == isData) { // unmatched in xfer() 589 if (p.casItem(item, e)) { // match in xfer() 590 for (Node q = p; q != h;) { in xfer() 600 LockSupport.unpark(p.waiter); in xfer() 604 Node n = p.next; in xfer() 605 p = (p != n) ? n : (h = head); // Use head if p offlist in xfer() 631 for (Node t = tail, p = t;;) { // move p to last node and append in tryAppend() [all …]
|
D | LinkedBlockingQueue.java | 491 void unlink(Node<E> p, Node<E> trail) { in unlink() argument 495 p.item = null; in unlink() 496 trail.next = p.next; in unlink() 497 if (last == p) in unlink() 518 for (Node<E> trail = head, p = trail.next; in remove() 519 p != null; in remove() 520 trail = p, p = p.next) { in remove() 521 if (o.equals(p.item)) { in remove() 522 unlink(p, trail); in remove() 544 for (Node<E> p = head.next; p != null; p = p.next) in contains() [all …]
|
D | Exchanger.java | 336 Node p = participant.get(); in arenaExchange() local 337 for (int i = p.index;;) { // access slot at i in arenaExchange() 349 p.item = item; // offer in arenaExchange() 350 if (U.compareAndSwapObject(a, j, null, p)) { in arenaExchange() 353 for (int h = p.hash, spins = SPINS;;) { in arenaExchange() 354 Object v = p.match; in arenaExchange() 356 U.putOrderedObject(p, MATCH, null); in arenaExchange() 357 p.item = null; // clear for next use in arenaExchange() 358 p.hash = h; in arenaExchange() 369 else if (U.getObjectVolatile(a, j) != p) in arenaExchange() [all …]
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/regex/ |
D | Pattern2Test.java | 31 Pattern p = Pattern.compile("foo.*"); in testSimpleMatch() local 33 Matcher m1 = p.matcher("foo123"); in testSimpleMatch() 38 Matcher m2 = p.matcher("fox"); in testSimpleMatch() 52 Pattern p; in testCursors() local 56 p = Pattern.compile("foo"); in testCursors() 58 m = p.matcher("foobar"); in testCursors() 107 Pattern p; in testGroups() local 110 p = Pattern.compile("(p[0-9]*)#?(q[0-9]*)"); in testGroups() 112 m = p.matcher("p1#q3p2q42p5p71p63#q888"); in testGroups() 160 Pattern p; in testReplace() local [all …]
|
D | ModeTest.java | 31 Pattern p; in testCase() local 34 p = Pattern.compile("([a-z]+)[0-9]+"); in testCase() 35 m = p.matcher("cAT123#dog345"); in testCase() 40 p = Pattern.compile("([a-z]+)[0-9]+", Pattern.CASE_INSENSITIVE); in testCase() 41 m = p.matcher("cAt123#doG345"); in testCase() 48 p = Pattern.compile("(?i)([a-z]+)[0-9]+"); in testCase() 49 m = p.matcher("cAt123#doG345"); in testCase() 58 Pattern p; in testMultiline() local 61 p = Pattern.compile("^foo"); in testMultiline() 62 m = p.matcher("foobar"); in testMultiline() [all …]
|
D | SplitTest.java | 32 Pattern p = Pattern.compile("/"); in testSimple() local 33 String[] results = p.split("have/you/done/it/right"); in testSimple() 42 Pattern p = Pattern.compile(" "); in testSplit1() local 47 tokens = p.split(input, 1); in testSplit1() 50 tokens = p.split(input, 2); in testSplit1() 54 tokens = p.split(input, 5); in testSplit1() 58 tokens = p.split(input, -2); in testSplit1() 62 tokens = p.split(input, 0); in testSplit1() 66 tokens = p.split(input); in testSplit1() 71 p = Pattern.compile("d"); in testSplit1() [all …]
|
/libcore/luni/src/test/java/org/apache/harmony/regex/tests/java/util/regex/ |
D | Pattern2Test.java | 110 Pattern p = Pattern.compile(pat); in testCategory() local 119 "by pattern '"+pat, p.matcher(t).matches()); in testCategory() 124 "by pattern '"+pat, p.matcher(t).matches()); in testCategory() 132 Pattern p; in testCapturingGroups() local 136 p = Pattern.compile("(a+)b"); in testCapturingGroups() 137 m = p.matcher("aaaaaaaab"); in testCapturingGroups() 142 p = Pattern.compile("((an)+)((as)+)"); in testCapturingGroups() 143 m = p.matcher("ananas"); in testCapturingGroups() 153 p = Pattern.compile("(?:(?:an)+)(as)"); in testCapturingGroups() 154 m = p.matcher("ananas"); in testCapturingGroups() [all …]
|
D | ModeTest.java | 31 Pattern p; in testCase() local 34 p = Pattern.compile("([a-z]+)[0-9]+"); in testCase() 35 m = p.matcher("cAT123#dog345"); in testCase() 41 p = Pattern.compile("([a-z]+)[0-9]+", Pattern.CASE_INSENSITIVE); in testCase() 42 m = p.matcher("cAt123#doG345"); in testCase() 50 p = Pattern.compile("(?i)([a-z]+)[0-9]+"); in testCase() 51 m = p.matcher("cAt123#doG345"); in testCase() 59 Pattern p; in testMultiline() local 62 p = Pattern.compile("^foo"); in testMultiline() 63 m = p.matcher("foobar"); in testMultiline() [all …]
|
D | SplitTest.java | 12 Pattern p = Pattern.compile("/"); in testSimple() local 13 String[] results = p.split("have/you/done/it/right"); in testSimple() 64 Pattern p = Pattern.compile(" "); in testSplit1() local 69 tokens = p.split(input, 1); in testSplit1() 72 tokens = p.split(input, 2); in testSplit1() 76 tokens = p.split(input, 5); in testSplit1() 80 tokens = p.split(input, -2); in testSplit1() 84 tokens = p.split(input, 0); in testSplit1() 88 tokens = p.split(input); in testSplit1() 93 p = Pattern.compile("d"); in testSplit1() [all …]
|
/libcore/jsr166-tests/src/test/java/jsr166/ |
D | ThreadPoolExecutorTest.java | 60 final ThreadPoolExecutor p = in testExecute() local 70 p.execute(task); in testExecute() 73 joinPool(p); in testExecute() 82 final ThreadPoolExecutor p = in testGetActiveCount() local 89 assertEquals(0, p.getActiveCount()); in testGetActiveCount() 90 p.execute(new CheckedRunnable() { in testGetActiveCount() 93 assertEquals(1, p.getActiveCount()); in testGetActiveCount() 97 assertEquals(1, p.getActiveCount()); in testGetActiveCount() 100 joinPool(p); in testGetActiveCount() 108 final ThreadPoolExecutor p = in testPrestartCoreThread() local [all …]
|
D | ThreadPoolExecutorSubclassTest.java | 200 final ThreadPoolExecutor p = in testExecute() local 210 p.execute(task); in testExecute() 213 joinPool(p); in testExecute() 222 final ThreadPoolExecutor p = in testGetActiveCount() local 229 assertEquals(0, p.getActiveCount()); in testGetActiveCount() 230 p.execute(new CheckedRunnable() { in testGetActiveCount() 233 assertEquals(1, p.getActiveCount()); in testGetActiveCount() 237 assertEquals(1, p.getActiveCount()); in testGetActiveCount() 240 joinPool(p); in testGetActiveCount() 248 …ThreadPoolExecutor p = new CustomTPE(2, 2, LONG_DELAY_MS, MILLISECONDS, new ArrayBlockingQueue<Run… in testPrestartCoreThread() local [all …]
|
D | ScheduledExecutorTest.java | 23 ScheduledThreadPoolExecutor p = new ScheduledThreadPoolExecutor(1); in testExecute() local 30 p.execute(task); in testExecute() 33 joinPool(p); in testExecute() 41 ScheduledThreadPoolExecutor p = new ScheduledThreadPoolExecutor(1); in testSchedule1() local 51 Future f = p.schedule(task, timeoutMillis(), MILLISECONDS); in testSchedule1() 56 joinPool(p); in testSchedule1() 64 ScheduledThreadPoolExecutor p = new ScheduledThreadPoolExecutor(1); in testSchedule3() local 73 Future f = p.schedule(task, timeoutMillis(), MILLISECONDS); in testSchedule3() 78 joinPool(p); in testSchedule3() 86 ScheduledThreadPoolExecutor p = new ScheduledThreadPoolExecutor(1); in testSchedule4() local [all …]
|
D | ScheduledExecutorSubclassTest.java | 75 CustomExecutor p = new CustomExecutor(1); in testExecute() local 82 p.execute(task); in testExecute() 85 joinPool(p); in testExecute() 93 CustomExecutor p = new CustomExecutor(1); in testSchedule1() local 103 Future f = p.schedule(task, timeoutMillis(), MILLISECONDS); in testSchedule1() 108 joinPool(p); in testSchedule1() 116 CustomExecutor p = new CustomExecutor(1); in testSchedule3() local 125 Future f = p.schedule(task, timeoutMillis(), MILLISECONDS); in testSchedule3() 130 joinPool(p); in testSchedule3() 138 CustomExecutor p = new CustomExecutor(1); in testSchedule4() local [all …]
|
D | ForkJoinPoolTest.java | 65 public FailingFJWSubclass(ForkJoinPool p) { super(p) ; } in FailingFJWSubclass() argument 72 public ForkJoinWorkerThread newThread(ForkJoinPool p) { in newThread() argument 74 return new FailingFJWSubclass(p); in newThread() 160 ForkJoinPool p = new ForkJoinPool(1); in testDefaultInitialState() local 163 p.getFactory()); in testDefaultInitialState() 164 assertFalse(p.getAsyncMode()); in testDefaultInitialState() 165 assertEquals(0, p.getActiveThreadCount()); in testDefaultInitialState() 166 assertEquals(0, p.getStealCount()); in testDefaultInitialState() 167 assertEquals(0, p.getQueuedTaskCount()); in testDefaultInitialState() 168 assertEquals(0, p.getQueuedSubmissionCount()); in testDefaultInitialState() [all …]
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/prefs/ |
D | AbstractPreferencesTest.java | 145 MockAbstractPreferences p = new MockAbstractPreferences(pref, "newNode"); in testProtectedFields() local 146 assertFalse(p.getNewNode()); in testProtectedFields() 147 assertSame(p.getLock().getClass(), Object.class); in testProtectedFields() 149 p = (MockAbstractPreferences) pref.node("child"); in testProtectedFields() 150 assertTrue(p.getNewNode()); in testProtectedFields() 152 p = (MockAbstractPreferences) ((MockAbstractPreferences) pref) in testProtectedFields() 154 assertTrue(p.getNewNode()); in testProtectedFields() 803 MockAbstractPreferences p = (MockAbstractPreferences) pref; in testSync() local 804 p.resetSyncTimes(); in testSync() 805 p.sync(); in testSync() [all …]
|
D | PreferencesTest.java | 71 Preferences p = Preferences.systemNodeForPackage(Object.class); in testSystemNodeForPackage() local 73 assertEquals("/java/lang", p.absolutePath()); in testSystemNodeForPackage() 74 assertTrue(p instanceof AbstractPreferences); in testSystemNodeForPackage() 77 assertSame(parent, p.parent()); in testSystemNodeForPackage() 78 assertFalse(p.isUserNode()); in testSystemNodeForPackage() 79 assertEquals("lang", p.name()); in testSystemNodeForPackage() 80 assertEquals("System Preference Node: " + p.absolutePath(), p in testSystemNodeForPackage() 83 assertEquals(0, p.childrenNames().length); in testSystemNodeForPackage() 84 assertEquals(0, p.keys().length); in testSystemNodeForPackage() 95 Preferences p = Preferences.systemRoot(); in testSystemRoot() local [all …]
|
/libcore/luni/src/main/java/java/security/spec/ |
D | ECFieldFp.java | 28 private final BigInteger p; field in ECFieldFp 39 public ECFieldFp(BigInteger p) { in ECFieldFp() argument 40 this.p = p; in ECFieldFp() 42 if (this.p == null) { in ECFieldFp() 45 if (this.p.signum() != 1) { in ECFieldFp() 56 return p.bitLength(); in getFieldSize() 65 return p; in getP() 82 return (this.p.equals(((ECFieldFp)obj).p)); in equals() 93 return p.hashCode(); in hashCode()
|
/libcore/luni/src/main/java/javax/crypto/spec/ |
D | PSource.java | 63 private final byte[] p; field in PSource.PSpecified 73 p = EmptyArray.BYTE; in PSpecified() 85 public PSpecified(byte[] p) { in PSpecified() argument 87 if (p == null) { in PSpecified() 92 this.p = new byte[p.length]; in PSpecified() 93 System.arraycopy(p, 0, this.p, 0, p.length); in PSpecified() 102 byte[] result = new byte[p.length]; in getValue() 103 System.arraycopy(p, 0, result, 0, p.length); in getValue()
|
/libcore/luni/src/test/java/libcore/java/util/regex/ |
D | OldAndroidRegexTest.java | 27 Pattern p = Pattern.compile("bcd"); in testMatches() local 28 Matcher m = p.matcher("bcd"); in testMatches() 32 p = Pattern.compile("bcd"); in testMatches() 33 m = p.matcher("abcdefg"); in testMatches() 37 m = p.matcher("bcdefg"); in testMatches() 41 m = p.matcher("abcd"); in testMatches() 45 p = Pattern.compile(".*"); in testMatches() 46 m = p.matcher("abc"); in testMatches() 51 p = Pattern.compile("."); in testMatches() 52 m = p.matcher("abc"); in testMatches() [all …]
|
/libcore/luni/src/test/java/org/apache/harmony/security/tests/java/security/ |
D | ProviderServiceTest.java | 44 Provider p = new MyProvider(); in testService() local 52 new Provider.Service(p, null, "algorithm", "className", null, null); in testService() 57 new Provider.Service(p, "type", null, "className", null, null); in testService() 62 new Provider.Service(p, "type", "algorithm", null, null, null); in testService() 67 Provider.Service s = new Provider.Service(p, "type", "algorithm", in testService() 76 if (s.getProvider() != p) { in testService() 88 Provider p = new MyProvider(); in testGetAttribute() local 89 Provider.Service s = new Provider.Service(p, "type", "algorithm", in testGetAttribute() 106 s = new Provider.Service(p, "type", "algorithm", "className", null, hm); in testGetAttribute() 119 Provider p = new MyProvider(); in testNewInstance() local [all …]
|
D | ProviderTest.java | 59 Provider p; field in ProviderTest 69 p = new MyProvider(); in setUp() 74 p.remove("MessageDigest.ASH-1"); in tearDown() 75 p.remove("MessageDigest.abc"); in tearDown() 76 p.remove("Alg.Alias.MessageDigest.ASH1"); in tearDown() 78 for (Provider p: Security.getProviders()) { in tearDown() 79 Security.removeProvider(p.getName()); in tearDown() 82 for (Provider p: storedProviders) { in tearDown() 83 Security.addProvider(p); in tearDown() 93 if (!p.getProperty("Provider.id name").equals( in testProvider() [all …]
|
D | SecurityTest.java | 49 Provider p = new MyProvider(); in test_insertProviderAtLjava_security_ProviderLI() local 57 assertEquals(initNum + 1, Security.insertProviderAt(p, -1)); in test_insertProviderAtLjava_security_ProviderLI() 58 assertSame(p, Security.getProviders()[initNum]); in test_insertProviderAtLjava_security_ProviderLI() 61 assertEquals(-1, Security.insertProviderAt(p, 1)); in test_insertProviderAtLjava_security_ProviderLI() 63 Security.removeProvider(p.getName()); in test_insertProviderAtLjava_security_ProviderLI() 66 assertEquals(initNum + 1, Security.insertProviderAt(p, in test_insertProviderAtLjava_security_ProviderLI() 68 assertSame(p, Security.getProviders()[initNum]); in test_insertProviderAtLjava_security_ProviderLI() 70 Security.removeProvider(p.getName()); in test_insertProviderAtLjava_security_ProviderLI() 73 assertEquals(1, Security.insertProviderAt(p, 1)); in test_insertProviderAtLjava_security_ProviderLI() 74 assertSame(p, Security.getProviders()[0]); in test_insertProviderAtLjava_security_ProviderLI() [all …]
|