Home
last modified time | relevance | path

Searched refs:bs (Results 1 – 21 of 21) sorted by relevance

/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/
DBitSetTest.java29 BitSet bs = new BitSet(); in test_Constructor() local
31 assertEquals("Created BitSet of incorrect size", 64, bs.size()); in test_Constructor()
32 assertEquals("New BitSet had invalid string representation", "{}", bs in test_Constructor()
37 BitSet bs = new BitSet(128); in test_ConstructorI() local
40 assertEquals("Created BitSet of incorrect size", 128, bs.size()); in test_ConstructorI()
42 + bs.toString(), "{}", bs.toString()); in test_ConstructorI()
46 bs = new BitSet(89); in test_ConstructorI()
47 assertEquals("Failed to round BitSet element size", 128, bs.size()); in test_ConstructorI()
50 bs = new BitSet(-9); in test_ConstructorI()
57 BitSet bs = (BitSet) eightbs.clone(); in test_clone() local
[all …]
/libcore/luni/src/test/java/libcore/java/util/
DBitSetTest.java28 BitSet bs = new BitSet(); in test_toString() local
29 assertEquals("{}", bs.toString()); in test_toString()
30 bs.set(2); in test_toString()
31 assertEquals("{2}", bs.toString()); in test_toString()
32 bs.set(4); in test_toString()
33 bs.set(10); in test_toString()
34 assertEquals("{2, 4, 10}", bs.toString()); in test_toString()
53 private static void assertBitSet(BitSet bs, long[] longs, String s) { in assertBitSet() argument
55 assertEquals(bs.toString(), ((longs[i / 64] & (1L << (i % 64))) != 0), bs.get(i)); in assertBitSet()
62 assertFalse(bs.isEmpty()); in assertBitSet()
[all …]
/libcore/ojluni/src/main/java/java/nio/channels/
DChannels.java149 private byte[] bs = null; // Invoker's previous array in newOutputStream()
159 public synchronized void write(byte[] bs, int off, int len) in newOutputStream() argument
162 if ((off < 0) || (off > bs.length) || (len < 0) || in newOutputStream()
163 ((off + len) > bs.length) || ((off + len) < 0)) { in newOutputStream()
168 ByteBuffer bb = ((this.bs == bs) in newOutputStream()
170 : ByteBuffer.wrap(bs)); in newOutputStream()
174 this.bs = bs; in newOutputStream()
205 private byte[] bs = null; // Invoker's previous array in newInputStream()
219 public synchronized int read(byte[] bs, int off, int len) in newInputStream() argument
222 if ((off < 0) || (off > bs.length) || (len < 0) || in newInputStream()
[all …]
/libcore/ojluni/src/main/java/sun/nio/ch/
DChannelInputStream.java72 private byte[] bs = null; // Invoker's previous array field in ChannelInputStream
88 public synchronized int read(byte[] bs, int off, int len) in read() argument
91 if ((off < 0) || (off > bs.length) || (len < 0) || in read()
92 ((off + len) > bs.length) || ((off + len) < 0)) { in read()
97 ByteBuffer bb = ((this.bs == bs) in read()
99 : ByteBuffer.wrap(bs)); in read()
103 this.bs = bs; in read()
DUtil.java305 static ByteBuffer[] subsequence(ByteBuffer[] bs, int offset, int length) { in subsequence() argument
306 if ((offset == 0) && (length == bs.length)) in subsequence()
307 return bs; in subsequence()
311 bs2[i] = bs[offset + i]; in subsequence()
/libcore/ojluni/src/test/java/util/concurrent/tck/
DConcurrentSkipListSetTest.java703 BitSet bs = new BitSet(setSize); in testRecursiveSubSets() local
705 populate(set, setSize, bs); in testRecursiveSubSets()
706 check(set, 0, setSize - 1, true, bs); in testRecursiveSubSets()
707 check(set.descendingSet(), 0, setSize - 1, false, bs); in testRecursiveSubSets() local
709 mutateSet(set, 0, setSize - 1, bs); in testRecursiveSubSets()
710 check(set, 0, setSize - 1, true, bs); in testRecursiveSubSets()
711 check(set.descendingSet(), 0, setSize - 1, false, bs); in testRecursiveSubSets() local
714 0, setSize - 1, true, bs); in testRecursiveSubSets()
736 void populate(NavigableSet<Integer> set, int limit, BitSet bs) { in populate() argument
739 put(set, element, bs); in populate()
[all …]
DTreeMapTest.java808 BitSet bs;
817 bs = new BitSet(mapSize);
858 bs.clear(it.next());
883 bs.clear(it.next());
904 bs.set(key);
909 bs.clear(key);
1025 if (bs.get(key))
1036 int result = bs.nextSetBit(key);
1056 boolean bsContainsI = bs.get(i);
1067 assertTrue(bs.get(key));
DConcurrentSkipListMapTest.java1003 BitSet bs;
1012 bs = new BitSet(mapSize);
1053 bs.clear(it.next());
1078 bs.clear(it.next());
1099 bs.set(key);
1104 bs.clear(key);
1220 if (bs.get(key))
1231 int result = bs.nextSetBit(key);
1251 boolean bsContainsI = bs.get(i);
1262 assertTrue(bs.get(key));
DConcurrentHashMapTest.java170 BS bs = new BS(String.valueOf(i)); in testGenericComparable() local
172 LexicographicList<BS> bss = new LexicographicList<BS>(bs); in testGenericComparable()
/libcore/jsr166-tests/src/test/java/jsr166/
DConcurrentSkipListSetTest.java673 BitSet bs = new BitSet(setSize); in testRecursiveSubSets() local
675 populate(set, setSize, bs); in testRecursiveSubSets()
676 check(set, 0, setSize - 1, true, bs); in testRecursiveSubSets()
677 check(set.descendingSet(), 0, setSize - 1, false, bs); in testRecursiveSubSets() local
679 mutateSet(set, 0, setSize - 1, bs); in testRecursiveSubSets()
680 check(set, 0, setSize - 1, true, bs); in testRecursiveSubSets()
681 check(set.descendingSet(), 0, setSize - 1, false, bs); in testRecursiveSubSets() local
684 0, setSize - 1, true, bs); in testRecursiveSubSets()
705 void populate(NavigableSet<Integer> set, int limit, BitSet bs) { in populate() argument
708 put(set, element, bs); in populate()
[all …]
DTreeSetTest.java667 BitSet bs; field in TreeSetTest
677 bs = new BitSet(setSize); in testRecursiveSubSets()
728 bs.clear(it.next()); in mutateSet()
753 bs.clear(it.next()); in mutateSubSet()
774 bs.set(element); in put()
779 bs.clear(element); in remove()
899 if (bs.get(element)) in check()
910 int result = bs.nextSetBit(element); in check()
930 boolean bsContainsI = bs.get(i); in check()
941 assertTrue(bs.get(element)); in check()
DTreeMapTest.java785 BitSet bs;
794 bs = new BitSet(mapSize);
835 bs.clear(it.next());
860 bs.clear(it.next());
881 bs.set(key);
886 bs.clear(key);
1002 if (bs.get(key))
1013 int result = bs.nextSetBit(key);
1033 boolean bsContainsI = bs.get(i);
1044 assertTrue(bs.get(key));
DConcurrentSkipListMapTest.java980 BitSet bs;
989 bs = new BitSet(mapSize);
1030 bs.clear(it.next());
1055 bs.clear(it.next());
1076 bs.set(key);
1081 bs.clear(key);
1197 if (bs.get(key))
1208 int result = bs.nextSetBit(key);
1228 boolean bsContainsI = bs.get(i);
1239 assertTrue(bs.get(key));
DConcurrentHashMapTest.java145 BS bs = new BS(String.valueOf(i)); in testGenericComparable() local
147 LexicographicList<BS> bss = new LexicographicList<BS>(bs); in testGenericComparable()
/libcore/ojluni/src/main/java/sun/security/provider/certpath/
DAdjacencyList.java213 BuildStep bs = new BuildStep(v, BuildStep.FOLLOW); in buildList() local
214 mStepList.add(bs); in buildList()
215 success = buildList(theList, v.getIndex(), bs); in buildList()
/libcore/luni/src/test/java/libcore/java/util/zip/
DOldZipFileTest.java32 ByteArrayOutputStream bs = new ByteArrayOutputStream(); in getAllBytesFromStream() local
36 bs.write(buf, 0, iRead); in getAllBytesFromStream()
38 return bs.toByteArray(); in getAllBytesFromStream()
/libcore/ojluni/src/main/java/com/sun/security/cert/internal/x509/
DX509V1CertImpl.java81 ByteArrayInputStream bs; in X509V1CertImpl() local
83 bs = new ByteArrayInputStream(certData); in X509V1CertImpl()
85 getFactory().generateCertificate(bs); in X509V1CertImpl()
/libcore/support/src/test/java/tests/resources/x509/
Dprivkey.pem22 bs+oiq7MxzTuCUUo6vWfYNoMYTxqd9rDCtMfw9vG+3wCLfOywbjgcygYa9R+cJwY
/libcore/ojluni/src/test/java/util/stream/test/org/openjdk/tests/java/util/stream/
DGroupByOpTest.java166 Set<V> bs = new HashSet<>(b.get(k)); in multiMapEquals() local
167 if (!Objects.equals(as, bs)) { in multiMapEquals()
/libcore/luni/src/test/java/libcore/java/net/
DInetAddressTest.java373 byte[] bs = new byte[16]; in test_equals()
374 assertEquals(Inet6Address.getByAddress("1", bs, 1), Inet6Address.getByAddress("2", bs, 2)); in test_equals()
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/io/
DOutputStreamWriterTest.java426 byte[] bs = { 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H' }; in testHandleEarlyEOFChar_2()
428 bytes[i] = bs[i / 8192]; in testHandleEarlyEOFChar_2()