Home
last modified time | relevance | path

Searched refs:max (Results 1 – 25 of 127) sorted by relevance

123456

/libcore/ojluni/src/main/java/java/util/
DIntSummaryStatistics.java68 private int max = Integer.MIN_VALUE; field in IntSummaryStatistics
87 max = Math.max(max, value); in accept()
100 max = Math.max(max, other.max); in combine()
139 return max; in getMax()
DLongSummaryStatistics.java69 private long max = Long.MIN_VALUE; field in LongSummaryStatistics
98 max = Math.max(max, value); in accept()
112 max = Math.max(max, other.max); in combine()
151 return max; in getMax()
DDoubleSummaryStatistics.java68 private double max = Double.NEGATIVE_INFINITY; field in DoubleSummaryStatistics
88 max = Math.max(max, value); in accept()
104 max = Math.max(max, other.max); in combine()
188 return max; in getMax()
/libcore/luni/src/test/java/libcore/java/lang/
DByteTest.java23 final byte max = Byte.MAX_VALUE; in test_compare()
24 assertTrue(Byte.compare(max, max) == 0); in test_compare()
27 assertTrue(Byte.compare(max, zero) > 0); in test_compare()
28 assertTrue(Byte.compare(max, min) > 0); in test_compare()
29 assertTrue(Byte.compare(zero, max) < 0); in test_compare()
32 assertTrue(Byte.compare(min, max) < 0); in test_compare()
DShortTest.java23 final short max = Short.MAX_VALUE; in test_compare() local
24 assertTrue(Short.compare(max, max) == 0); in test_compare()
27 assertTrue(Short.compare(max, zero) > 0); in test_compare()
28 assertTrue(Short.compare(max, min) > 0); in test_compare()
29 assertTrue(Short.compare(zero, max) < 0); in test_compare()
32 assertTrue(Short.compare(min, max) < 0); in test_compare()
DIntegerTest.java42 final int max = Integer.MAX_VALUE; in testCompare() local
43 assertTrue(Integer.compare(max, max) == 0); in testCompare()
46 assertTrue(Integer.compare(max, zero) > 0); in testCompare()
47 assertTrue(Integer.compare(max, min) > 0); in testCompare()
48 assertTrue(Integer.compare(zero, max) < 0); in testCompare()
51 assertTrue(Integer.compare(min, max) < 0); in testCompare()
142 assertEquals(Math.max(a, b), Integer.max(a, b));
DLongTest.java40 final long max = Long.MAX_VALUE; in testCompare() local
41 assertTrue(Long.compare(max, max) == 0); in testCompare()
44 assertTrue(Long.compare(max, zero) > 0); in testCompare()
45 assertTrue(Long.compare(max, min) > 0); in testCompare()
46 assertTrue(Long.compare(zero, max) < 0); in testCompare()
49 assertTrue(Long.compare(min, max) < 0); in testCompare()
148 assertEquals(Math.max(a, b), Long.max(a, b));
DOldAndroidMathTest.java330 assertEquals("Incorrect double max value", 1908897.6000089, Math.max(-1908897.6000089, in testMaxDD()
333 1908897.6000089, Math.max(2.0, 1908897.6000089), 0D); in testMaxDD()
334 assertEquals("Incorrect double max value", -2.0, Math.max(-2.0, in testMaxDD()
341 assertTrue("Incorrect float max value", Math.max(-1908897.600f, in testMaxFF()
344 Math.max(2.0f, 1908897.600f) == 1908897.600f); in testMaxFF()
346 Math.max(-2.0f, -1908897.600f) == -2.0f); in testMaxFF()
352 19088976, Math.max(-19088976, 19088976)); in testMaxII()
354 19088976, Math.max(20, 19088976)); in testMaxII()
355 assertEquals("Incorrect int max value", -20, Math.max(-20, -19088976)); in testMaxII()
360 assertEquals("Incorrect long max value", 19088976000089L, Math.max(-19088976000089L, in testMaxJJ()
[all …]
/libcore/luni/src/main/java/org/xml/sax/helpers/
DAttributesImpl.java201 int max = length * 5; in getIndex() local
202 for (int i = 0; i < max; i += 5) { in getIndex()
220 int max = length * 5; in getIndex() local
221 for (int i = 0; i < max; i += 5) { in getIndex()
242 int max = length * 5; in getType() local
243 for (int i = 0; i < max; i += 5) { in getType()
262 int max = length * 5; in getType() local
263 for (int i = 0; i < max; i += 5) { in getType()
284 int max = length * 5; in getValue() local
285 for (int i = 0; i < max; i += 5) { in getValue()
[all …]
/libcore/ojluni/src/test/java/util/stream/test/org/openjdk/tests/java/util/stream/
DMinMaxTest.java56 assertTrue(!countTo(0).stream().max(Integer::compare).isPresent()); in testMinMax()
58 assertEquals(1000, (int) countTo(1000).stream().max(Integer::compare).get()); in testMinMax()
64 exerciseTerminalOps(data, s -> s.max(Integer::compare)); in testOps()
69 assertEquals(IntStream.empty().max(), OptionalInt.empty()); in testIntMinMax()
71 assertEquals(1000, IntStream.range(1, 1001).max().getAsInt()); in testIntMinMax()
77 exerciseTerminalOps(data, s -> s.max()); in testIntOps()
82 assertEquals(LongStream.empty().max(), OptionalLong.empty()); in testLongMinMax()
84 assertEquals(1000, LongStream.range(1, 1001).max().getAsLong()); in testLongMinMax()
90 exerciseTerminalOps(data, s -> s.max()); in testLongOps()
95 assertEquals(DoubleStream.empty().max(), OptionalDouble.empty()); in testDoubleMinMax()
[all …]
/libcore/jsr166-tests/src/test/java/jsr166/
DLongAccumulatorTest.java32 LongAccumulator ai = new LongAccumulator(Long::max, 0L); in testConstructor()
40 LongAccumulator ai = new LongAccumulator(Long::max, 0L); in testAccumulateAndGet()
53 LongAccumulator ai = new LongAccumulator(Long::max, 0L); in testReset()
64 LongAccumulator ai = new LongAccumulator(Long::max, 0L); in testGetThenReset()
75 LongAccumulator ai = new LongAccumulator(Long::max, 0L); in testToString()
85 LongAccumulator ai = new LongAccumulator(Long::max, 0L); in testIntValue()
95 LongAccumulator ai = new LongAccumulator(Long::max, 0L); in testLongValue()
105 LongAccumulator ai = new LongAccumulator(Long::max, 0L); in testFloatValue()
115 LongAccumulator ai = new LongAccumulator(Long::max, 0L); in testDoubleValue()
128 LongAccumulator a = new LongAccumulator(Long::max, 0L); in testAccumulateAndGetMT()
DDoubleAccumulatorTest.java32 DoubleAccumulator ai = new DoubleAccumulator(Double::max, 0.0); in testConstructor()
40 DoubleAccumulator ai = new DoubleAccumulator(Double::max, 0.0); in testAccumulateAndGet()
53 DoubleAccumulator ai = new DoubleAccumulator(Double::max, 0.0); in testReset()
64 DoubleAccumulator ai = new DoubleAccumulator(Double::max, 0.0); in testGetThenReset()
75 DoubleAccumulator ai = new DoubleAccumulator(Double::max, 0.0); in testToString()
85 DoubleAccumulator ai = new DoubleAccumulator(Double::max, 0.0); in testIntValue()
95 DoubleAccumulator ai = new DoubleAccumulator(Double::max, 0.0); in testLongValue()
105 DoubleAccumulator ai = new DoubleAccumulator(Double::max, 0.0); in testFloatValue()
115 DoubleAccumulator ai = new DoubleAccumulator(Double::max, 0.0); in testDoubleValue()
128 DoubleAccumulator a = new DoubleAccumulator(Double::max, 0.0); in testAccumulateAndGetMT()
DTreeSetTest.java716 void mutateSet(NavigableSet<Integer> set, int min, int max) { in mutateSet() argument
718 int rangeSize = max - min + 1; in mutateSet()
736 assertTrue(element >= min && element <= max); in mutateSet()
741 void mutateSubSet(NavigableSet<Integer> set, int min, int max) { in mutateSubSet() argument
743 int rangeSize = max - min + 1; in mutateSubSet()
761 if (element >= min && element <= max) { in mutateSubSet()
783 int min, int max, boolean ascending) { in bashSubSet() argument
784 check(set, min, max, ascending); in bashSubSet()
785 check(set.descendingSet(), min, max, !ascending); in bashSubSet() local
787 mutateSubSet(set, min, max); in bashSubSet()
[all …]
DConcurrentSkipListSetTest.java712 void mutateSet(NavigableSet<Integer> set, int min, int max, BitSet bs) { in mutateSet() argument
714 int rangeSize = max - min + 1; in mutateSet()
732 assertTrue(element >= min && element <= max); in mutateSet()
737 void mutateSubSet(NavigableSet<Integer> set, int min, int max, in mutateSubSet() argument
740 int rangeSize = max - min + 1; in mutateSubSet()
758 if (element >= min && element <= max) { in mutateSubSet()
780 int min, int max, boolean ascending, in bashSubSet() argument
782 check(set, min, max, ascending, bs); in bashSubSet()
783 check(set.descendingSet(), min, max, !ascending, bs); in bashSubSet() local
785 mutateSubSet(set, min, max, bs); in bashSubSet()
[all …]
DTreeMapTest.java823 void mutateMap(NavigableMap<Integer, Integer> map, int min, int max) {
825 int rangeSize = max - min + 1;
843 assertTrue(key >= min && key <= max);
848 void mutateSubMap(NavigableMap<Integer, Integer> map, int min, int max) {
850 int rangeSize = max - min + 1;
868 if (key >= min && key <= max) {
890 int min, int max, boolean ascending) {
891 check(map, min, max, ascending);
892 check(map.descendingMap(), min, max, !ascending);
894 mutateSubMap(map, min, max);
[all …]
DConcurrentSkipListMapTest.java1018 void mutateMap(NavigableMap<Integer, Integer> map, int min, int max) {
1020 int rangeSize = max - min + 1;
1038 assertTrue(key >= min && key <= max);
1043 void mutateSubMap(NavigableMap<Integer, Integer> map, int min, int max) {
1045 int rangeSize = max - min + 1;
1063 if (key >= min && key <= max) {
1085 int min, int max, boolean ascending) {
1086 check(map, min, max, ascending);
1087 check(map.descendingMap(), min, max, !ascending);
1089 mutateSubMap(map, min, max);
[all …]
/libcore/ojluni/src/main/java/sun/security/util/
DPropertyExpander.java71 int max = value.length(); in expand() local
75 while (p < max) { in expand()
84 if (pe < max && value.charAt(pe) == '{') { in expand()
86 if (pe == -1 || pe+2 == max) { in expand()
96 while ((pe < max) && (value.charAt(pe) != '}')) { in expand()
99 if (pe == max) { in expand()
134 if (i < max) { in expand()
135 sb.append(value.substring(i, max)); in expand()
/libcore/benchmarks/src/benchmarks/regression/
DLoopingBackwardsBenchmark.java27 @Param({"2", "20", "2000", "20000000"}) int max; field in LoopingBackwardsBenchmark
32 for (int j = 0; j < max; j++) { in timeForwards()
42 for (int j = max - 1; j >= 0; j--) { in timeBackwards()
/libcore/ojluni/src/main/java/sun/security/ssl/
DCipherSuite.java900 int max = ProtocolVersion.LIMIT_MAX_VALUE;
907 0xc024, --p, K_ECDHE_ECDSA, B_AES_256, T, max, tls12, P_SHA384);
909 0xc028, --p, K_ECDHE_RSA, B_AES_256, T, max, tls12, P_SHA384);
911 0x003d, --p, K_RSA, B_AES_256, T, max, tls12, P_SHA256);
913 0xc026, --p, K_ECDH_ECDSA, B_AES_256, T, max, tls12, P_SHA384);
915 0xc02a, --p, K_ECDH_RSA, B_AES_256, T, max, tls12, P_SHA384);
917 0x006b, --p, K_DHE_RSA, B_AES_256, T, max, tls12, P_SHA256);
919 0x006a, --p, K_DHE_DSS, B_AES_256, T, max, tls12, P_SHA256);
937 0xc023, --p, K_ECDHE_ECDSA, B_AES_128, T, max, tls12, P_SHA256);
939 0xc027, --p, K_ECDHE_RSA, B_AES_128, T, max, tls12, P_SHA256);
[all …]
DProtocolList.java46 final ProtocolVersion min, max; field in ProtocolList
68 max = protocols.get(protocols.size() - 1); in ProtocolList()
72 max = ProtocolVersion.NONE; in ProtocolList()
/libcore/luni/src/test/java/libcore/util/
DNativeAllocationRegistryTest.java48 long max = Runtime.getRuntime().maxMemory(); in testNativeAllocation() local
51 int expectedMaxNumAllocations = (int)(max-total)/size; in testNativeAllocation()
91 + " exceeds max memory (" + max + ")", in testNativeAllocation()
92 getNumNativeBytesAllocated() < max); in testNativeAllocation()
/libcore/ojluni/src/main/java/java/util/zip/
DInflaterInputStream.java207 int max = (int)Math.min(n, Integer.MAX_VALUE); in skip() local
209 while (total < max) { in skip()
210 int len = max - total; in skip()
/libcore/ojluni/src/main/java/java/io/
DCharArrayWriter.java82 buf = Arrays.copyOf(buf, Math.max(buf.length << 1, newcount)); in write()
105 buf = Arrays.copyOf(buf, Math.max(buf.length << 1, newcount)); in write()
122 buf = Arrays.copyOf(buf, Math.max(buf.length << 1, newcount)); in write()
/libcore/support/src/test/java/org/apache/harmony/xnet/tests/support/
DSSLContextSpiImpl.java62 int max = 65535; in engineCreateSSLEngine() local
64 if (port < 0 || port > max) { in engineCreateSSLEngine()
/libcore/luni/src/test/java/libcore/javax/net/
DServerSocketFactoryTest.java96 int max = 100; in assertBacklog() local
97 for (int i = 0; i < max; i++) { in assertBacklog()
103 fail("Failed to exhaust backlog after " + max + " connections!"); in assertBacklog()

123456