Home
last modified time | relevance | path

Searched refs:sm (Results 1 – 25 of 81) sorted by relevance

1234

/libcore/luni/src/test/java/libcore/java/lang/
DSecurityManagerTest.java78 private TestSecurityManager sm = new TestSecurityManager(); field in SecurityManagerTest
86 System.setSecurityManager(sm); in testSystemSecurityManager()
96 sm.checkAccept(SAMPLE_HOST, SAMPLE_PORT); in testCheckAccept()
101 sm.checkAccess(Thread.currentThread()); in testCheckAccess()
106 sm.checkAccess(sm.getThreadGroup()); in testCheckAccessThreadGroup()
111 sm.checkAwtEventQueueAccess(); in testCheckAwtEventQueueAccess()
116 sm.checkConnect(SAMPLE_HOST, SAMPLE_PORT); in testCheckConnect()
121 sm.checkConnect(SAMPLE_HOST, SAMPLE_PORT, null); in testCheckConnectWithObject()
126 sm.checkCreateClassLoader(); in testCheckCreateClassLoader()
131 sm.checkDelete(null); in testCheckDelete()
[all …]
/libcore/ojluni/src/test/java/util/concurrent/tck/
DTreeSubSetTest.java526 SortedSet sm = set.subSet(two, four); in testSubSetContents() local
527 assertEquals(two, sm.first()); in testSubSetContents()
528 assertEquals(three, sm.last()); in testSubSetContents()
529 assertEquals(2, sm.size()); in testSubSetContents()
530 assertFalse(sm.contains(one)); in testSubSetContents()
531 assertTrue(sm.contains(two)); in testSubSetContents()
532 assertTrue(sm.contains(three)); in testSubSetContents()
533 assertFalse(sm.contains(four)); in testSubSetContents()
534 assertFalse(sm.contains(five)); in testSubSetContents()
535 Iterator i = sm.iterator(); in testSubSetContents()
[all …]
DConcurrentSkipListSubSetTest.java529 SortedSet sm = set.subSet(two, four); in testSubSetContents() local
530 assertEquals(two, sm.first()); in testSubSetContents()
531 assertEquals(three, sm.last()); in testSubSetContents()
532 assertEquals(2, sm.size()); in testSubSetContents()
533 assertFalse(sm.contains(one)); in testSubSetContents()
534 assertTrue(sm.contains(two)); in testSubSetContents()
535 assertTrue(sm.contains(three)); in testSubSetContents()
536 assertFalse(sm.contains(four)); in testSubSetContents()
537 assertFalse(sm.contains(five)); in testSubSetContents()
538 Iterator i = sm.iterator(); in testSubSetContents()
[all …]
DTreeSubMapTest.java482 SortedMap sm = map.subMap(two, four);
483 assertEquals(two, sm.firstKey());
484 assertEquals(three, sm.lastKey());
485 assertEquals(2, sm.size());
486 assertFalse(sm.containsKey(one));
487 assertTrue(sm.containsKey(two));
488 assertTrue(sm.containsKey(three));
489 assertFalse(sm.containsKey(four));
490 assertFalse(sm.containsKey(five));
491 Iterator i = sm.keySet().iterator();
[all …]
DConcurrentSkipListSubMapTest.java647 SortedMap sm = map.subMap(two, four);
648 assertEquals(two, sm.firstKey());
649 assertEquals(three, sm.lastKey());
650 assertEquals(2, sm.size());
651 assertFalse(sm.containsKey(one));
652 assertTrue(sm.containsKey(two));
653 assertTrue(sm.containsKey(three));
654 assertFalse(sm.containsKey(four));
655 assertFalse(sm.containsKey(five));
656 Iterator i = sm.keySet().iterator();
[all …]
DTreeSetTest.java575 SortedSet sm = set.subSet(two, four); in testSubSetContents() local
576 assertEquals(two, sm.first()); in testSubSetContents()
577 assertEquals(three, sm.last()); in testSubSetContents()
578 assertEquals(2, sm.size()); in testSubSetContents()
579 assertFalse(sm.contains(one)); in testSubSetContents()
580 assertTrue(sm.contains(two)); in testSubSetContents()
581 assertTrue(sm.contains(three)); in testSubSetContents()
582 assertFalse(sm.contains(four)); in testSubSetContents()
583 assertFalse(sm.contains(five)); in testSubSetContents()
584 Iterator i = sm.iterator(); in testSubSetContents()
[all …]
DConcurrentSkipListSetTest.java579 SortedSet sm = set.subSet(two, four); in testSubSetContents() local
580 assertEquals(two, sm.first()); in testSubSetContents()
581 assertEquals(three, sm.last()); in testSubSetContents()
582 assertEquals(2, sm.size()); in testSubSetContents()
583 assertFalse(sm.contains(one)); in testSubSetContents()
584 assertTrue(sm.contains(two)); in testSubSetContents()
585 assertTrue(sm.contains(three)); in testSubSetContents()
586 assertFalse(sm.contains(four)); in testSubSetContents()
587 assertFalse(sm.contains(five)); in testSubSetContents()
588 Iterator i = sm.iterator(); in testSubSetContents()
[all …]
DTreeMapTest.java655 NavigableMap sm = map.subMap(two, true, four, false);
656 assertEquals(two, sm.firstKey());
657 assertEquals(three, sm.lastKey());
658 assertEquals(2, sm.size());
659 assertFalse(sm.containsKey(one));
660 assertTrue(sm.containsKey(two));
661 assertTrue(sm.containsKey(three));
662 assertFalse(sm.containsKey(four));
663 assertFalse(sm.containsKey(five));
664 Iterator i = sm.keySet().iterator();
[all …]
DConcurrentSkipListMapTest.java850 NavigableMap sm = map.subMap(two, true, four, false);
851 assertEquals(two, sm.firstKey());
852 assertEquals(three, sm.lastKey());
853 assertEquals(2, sm.size());
854 assertFalse(sm.containsKey(one));
855 assertTrue(sm.containsKey(two));
856 assertTrue(sm.containsKey(three));
857 assertFalse(sm.containsKey(four));
858 assertFalse(sm.containsKey(five));
859 Iterator i = sm.keySet().iterator();
[all …]
/libcore/jsr166-tests/src/test/java/jsr166/
DTreeSubSetTest.java503 SortedSet sm = set.subSet(two, four); in testSubSetContents() local
504 assertEquals(two, sm.first()); in testSubSetContents()
505 assertEquals(three, sm.last()); in testSubSetContents()
506 assertEquals(2, sm.size()); in testSubSetContents()
507 assertFalse(sm.contains(one)); in testSubSetContents()
508 assertTrue(sm.contains(two)); in testSubSetContents()
509 assertTrue(sm.contains(three)); in testSubSetContents()
510 assertFalse(sm.contains(four)); in testSubSetContents()
511 assertFalse(sm.contains(five)); in testSubSetContents()
512 Iterator i = sm.iterator(); in testSubSetContents()
[all …]
DConcurrentSkipListSubSetTest.java506 SortedSet sm = set.subSet(two, four); in testSubSetContents() local
507 assertEquals(two, sm.first()); in testSubSetContents()
508 assertEquals(three, sm.last()); in testSubSetContents()
509 assertEquals(2, sm.size()); in testSubSetContents()
510 assertFalse(sm.contains(one)); in testSubSetContents()
511 assertTrue(sm.contains(two)); in testSubSetContents()
512 assertTrue(sm.contains(three)); in testSubSetContents()
513 assertFalse(sm.contains(four)); in testSubSetContents()
514 assertFalse(sm.contains(five)); in testSubSetContents()
515 Iterator i = sm.iterator(); in testSubSetContents()
[all …]
DTreeSubMapTest.java459 SortedMap sm = map.subMap(two, four);
460 assertEquals(two, sm.firstKey());
461 assertEquals(three, sm.lastKey());
462 assertEquals(2, sm.size());
463 assertFalse(sm.containsKey(one));
464 assertTrue(sm.containsKey(two));
465 assertTrue(sm.containsKey(three));
466 assertFalse(sm.containsKey(four));
467 assertFalse(sm.containsKey(five));
468 Iterator i = sm.keySet().iterator();
[all …]
DConcurrentSkipListSubMapTest.java624 SortedMap sm = map.subMap(two, four);
625 assertEquals(two, sm.firstKey());
626 assertEquals(three, sm.lastKey());
627 assertEquals(2, sm.size());
628 assertFalse(sm.containsKey(one));
629 assertTrue(sm.containsKey(two));
630 assertTrue(sm.containsKey(three));
631 assertFalse(sm.containsKey(four));
632 assertFalse(sm.containsKey(five));
633 Iterator i = sm.keySet().iterator();
[all …]
DTreeSetTest.java552 SortedSet sm = set.subSet(two, four); in testSubSetContents() local
553 assertEquals(two, sm.first()); in testSubSetContents()
554 assertEquals(three, sm.last()); in testSubSetContents()
555 assertEquals(2, sm.size()); in testSubSetContents()
556 assertFalse(sm.contains(one)); in testSubSetContents()
557 assertTrue(sm.contains(two)); in testSubSetContents()
558 assertTrue(sm.contains(three)); in testSubSetContents()
559 assertFalse(sm.contains(four)); in testSubSetContents()
560 assertFalse(sm.contains(five)); in testSubSetContents()
561 Iterator i = sm.iterator(); in testSubSetContents()
[all …]
DConcurrentSkipListSetTest.java549 SortedSet sm = set.subSet(two, four); in testSubSetContents() local
550 assertEquals(two, sm.first()); in testSubSetContents()
551 assertEquals(three, sm.last()); in testSubSetContents()
552 assertEquals(2, sm.size()); in testSubSetContents()
553 assertFalse(sm.contains(one)); in testSubSetContents()
554 assertTrue(sm.contains(two)); in testSubSetContents()
555 assertTrue(sm.contains(three)); in testSubSetContents()
556 assertFalse(sm.contains(four)); in testSubSetContents()
557 assertFalse(sm.contains(five)); in testSubSetContents()
558 Iterator i = sm.iterator(); in testSubSetContents()
[all …]
DTreeMapTest.java632 NavigableMap sm = map.subMap(two, true, four, false);
633 assertEquals(two, sm.firstKey());
634 assertEquals(three, sm.lastKey());
635 assertEquals(2, sm.size());
636 assertFalse(sm.containsKey(one));
637 assertTrue(sm.containsKey(two));
638 assertTrue(sm.containsKey(three));
639 assertFalse(sm.containsKey(four));
640 assertFalse(sm.containsKey(five));
641 Iterator i = sm.keySet().iterator();
[all …]
DConcurrentSkipListMapTest.java827 NavigableMap sm = map.subMap(two, true, four, false);
828 assertEquals(two, sm.firstKey());
829 assertEquals(three, sm.lastKey());
830 assertEquals(2, sm.size());
831 assertFalse(sm.containsKey(one));
832 assertTrue(sm.containsKey(two));
833 assertTrue(sm.containsKey(three));
834 assertFalse(sm.containsKey(four));
835 assertFalse(sm.containsKey(five));
836 Iterator i = sm.keySet().iterator();
[all …]
/libcore/ojluni/src/main/java/java/net/
DAuthenticator.java123 SecurityManager sm = System.getSecurityManager(); in setDefault() local
124 if (sm != null) { in setDefault()
127 sm.checkPermission(setDefaultPermission); in setDefault()
167 SecurityManager sm = System.getSecurityManager(); in requestPasswordAuthentication() local
168 if (sm != null) { in requestPasswordAuthentication()
171 sm.checkPermission(requestPermission); in requestPasswordAuthentication()
229 SecurityManager sm = System.getSecurityManager(); in requestPasswordAuthentication() local
230 if (sm != null) { in requestPasswordAuthentication()
233 sm.checkPermission(requestPermission); in requestPasswordAuthentication()
296 SecurityManager sm = System.getSecurityManager(); in requestPasswordAuthentication() local
[all …]
DResponseCache.java84 SecurityManager sm = System.getSecurityManager(); in getDefault() local
85 if (sm != null) { in getDefault()
86 sm.checkPermission(SecurityConstants.GET_RESPONSECACHE_PERMISSION); in getDefault()
107 SecurityManager sm = System.getSecurityManager(); in setDefault() local
108 if (sm != null) { in setDefault()
109 sm.checkPermission(SecurityConstants.SET_RESPONSECACHE_PERMISSION); in setDefault()
DCookieHandler.java73 SecurityManager sm = System.getSecurityManager(); in getDefault() local
74 if (sm != null) { in getDefault()
75 sm.checkPermission(SecurityConstants.GET_COOKIEHANDLER_PERMISSION); in getDefault()
93 SecurityManager sm = System.getSecurityManager(); in setDefault() local
94 if (sm != null) { in setDefault()
95 sm.checkPermission(SecurityConstants.SET_COOKIEHANDLER_PERMISSION); in setDefault()
DProxySelector.java92 SecurityManager sm = System.getSecurityManager(); in getDefault() local
93 if (sm != null) { in getDefault()
94 sm.checkPermission(SecurityConstants.GET_PROXYSELECTOR_PERMISSION); in getDefault()
115 SecurityManager sm = System.getSecurityManager(); in setDefault() local
116 if (sm != null) { in setDefault()
117 sm.checkPermission(SecurityConstants.SET_PROXYSELECTOR_PERMISSION); in setDefault()
/libcore/ojluni/src/main/java/javax/net/ssl/
DHttpsURLConnection.java275 SecurityManager sm = System.getSecurityManager(); in setDefaultHostnameVerifier() local
276 if (sm != null) { in setDefaultHostnameVerifier()
277 sm.checkPermission(new SSLPermission("setHostnameVerifier")); in setDefaultHostnameVerifier()
390 SecurityManager sm = System.getSecurityManager(); in setDefaultSSLSocketFactory() local
391 if (sm != null) { in setDefaultSSLSocketFactory()
392 sm.checkSetFactory(); in setDefaultSSLSocketFactory()
439 SecurityManager sm = System.getSecurityManager(); in setSSLSocketFactory() local
440 if (sm != null) { in setSSLSocketFactory()
441 sm.checkSetFactory(); in setSSLSocketFactory()
/libcore/ojluni/src/main/java/javax/security/auth/
DSubject.java239 java.lang.SecurityManager sm = System.getSecurityManager(); in setReadOnly() local
240 if (sm != null) { in setReadOnly()
241 sm.checkPermission(AuthPermissionHolder.SET_READ_ONLY_PERMISSION); in setReadOnly()
285 java.lang.SecurityManager sm = System.getSecurityManager(); in getSubject() local
286 if (sm != null) { in getSubject()
287 sm.checkPermission(AuthPermissionHolder.GET_SUBJECT_PERMISSION); in getSubject()
346 java.lang.SecurityManager sm = System.getSecurityManager();
347 if (sm != null) {
348 sm.checkPermission(AuthPermissionHolder.DO_AS_PERMISSION);
408 java.lang.SecurityManager sm = System.getSecurityManager();
[all …]
/libcore/ojluni/src/main/java/sun/net/
DExtendedOptionsImpl.java60 SecurityManager sm = System.getSecurityManager(); in checkSetOptionPermission() local
61 if (sm == null) { in checkSetOptionPermission()
65 sm.checkPermission(new NetworkPermission(check)); in checkSetOptionPermission()
69 SecurityManager sm = System.getSecurityManager(); in checkGetOptionPermission() local
70 if (sm == null) { in checkGetOptionPermission()
74 sm.checkPermission(new NetworkPermission(check)); in checkGetOptionPermission()
/libcore/ojluni/src/main/java/sun/nio/fs/
DAbstractUserDefinedFileAttributeView.java47 SecurityManager sm = System.getSecurityManager(); in checkAccess() local
48 if (sm != null) { in checkAccess()
50 sm.checkRead(file); in checkAccess()
52 sm.checkWrite(file); in checkAccess()
53 sm.checkPermission(new RuntimePermission("accessUserDefinedAttributes")); in checkAccess()

1234