/cts/tests/tests/renderscript/src/android/renderscript/cts/ |
D | RSUtils.java | 78 for (int i = 0; i < array.length; i++) { in genRandomDoubles() 90 for (int i = 0; i < array.length; i++) { in genRandomDoubles() 96 for (int i = 0; i < sInterestingDoubles.length; i++) { in genRandomDoubles() 99 array[r.nextInt(array.length)] = d; in genRandomDoubles() 102 array[r.nextInt(array.length)] = min; in genRandomDoubles() 103 array[r.nextInt(array.length)] = max; in genRandomDoubles() 105 array[r.nextInt(array.length)] = Double.NaN; in genRandomDoubles() 106 array[r.nextInt(array.length)] = Double.POSITIVE_INFINITY; in genRandomDoubles() 107 array[r.nextInt(array.length)] = Double.NEGATIVE_INFINITY; in genRandomDoubles() 108 array[r.nextInt(array.length)] = Double.MIN_VALUE; in genRandomDoubles() [all …]
|
D | AtomicTest.java | 128 for (int i=0; i < mSrcData.length; i++) { in testAdd() 142 for (int i=0; i < mSrcData.length; i++) { in testUAdd() 156 for (int i=0; i < mSrcData.length; i++) { in testSub() 170 for (int i=0; i < mSrcData.length; i++) { in testUSub() 184 for (int i=0; i < mSrcData.length; i++) { in testXor() 198 for (int i=0; i < mSrcData.length; i++) { in testUXor() 278 for (int j = 0; j < mSrcData.length; j++) { in testAnd() 281 mSrcData[r.nextInt(mSrcData.length)] = ~0x40000000; in testAnd() 282 mSrcData[r.nextInt(mSrcData.length)] = ~0x10000000; in testAnd() 283 mSrcData[r.nextInt(mSrcData.length)] = ~0x02000000; in testAnd() [all …]
|
D | ReduceTest.java | 46 assertEquals("length", javaRslt.length, rsRslt.length); in assertEquals() 47 for (int i = 0; i < javaRslt.length; ++i) in assertEquals() 52 assertEquals("length", javaRslt.length, rsRslt.length); in assertEquals() 53 for (int i = 0; i < javaRslt.length; ++i) in assertEquals() 58 assertEquals("length", javaRslt.length, rsRslt.length); in assertEquals() 59 for (int i = 0; i < javaRslt.length; ++i) in assertEquals() 176 for (int idx = 0; idx < input.length; ++idx) in addint() 215 for (int idx = 0; idx < input.length; ++idx) { in findMinAndMax() 247 … Allocation inputAllocation = Allocation.createSized(mRS, Element.F16(mRS), inputArray.length); in findMinAndMaxHalf() 284 assertEquals(inputArray.length % 2, 0); in findMinAndMaxHalf2() [all …]
|
/cts/tests/tests/text/src/android/text/method/cts/ |
D | DigitsKeyListenerTest.java | 89 assertNull(digitsKeyListener.filter(source, 0, source.length(), in testFilter1() 90 dest, 0, dest.length())); in testFilter1() 94 assertEquals("123", (digitsKeyListener.filter(source, 0, source.length(), in testFilter1() 95 dest, 0, dest.length())).toString()); in testFilter1() 99 assertEquals("123", (digitsKeyListener.filter(source, 0, source.length(), in testFilter1() 100 dest, 0, dest.length())).toString()); in testFilter1() 104 assertEquals("123", (digitsKeyListener.filter(source, 0, source.length(), in testFilter1() 105 dest, 0, dest.length())).toString()); in testFilter1() 110 spannableSource.setSpan(what, 0, spannableSource.length(), Spanned.SPAN_POINT_POINT); in testFilter1() 112 0, spannableSource.length(), dest, 0, dest.length()); in testFilter1() [all …]
|
/cts/tests/tests/renderscriptlegacy/src/android/renderscriptlegacy/cts/ |
D | RSUtils.java | 56 for (int i = 0; i < array.length; i++) { in genRandomDoubles() 68 for (int i = 0; i < array.length; i++) { in genRandomDoubles() 74 for (int i = 0; i < sInterestingDoubles.length; i++) { in genRandomDoubles() 77 array[r.nextInt(array.length)] = d; in genRandomDoubles() 80 array[r.nextInt(array.length)] = min; in genRandomDoubles() 81 array[r.nextInt(array.length)] = max; in genRandomDoubles() 83 array[r.nextInt(array.length)] = Double.NaN; in genRandomDoubles() 84 array[r.nextInt(array.length)] = Double.POSITIVE_INFINITY; in genRandomDoubles() 85 array[r.nextInt(array.length)] = Double.NEGATIVE_INFINITY; in genRandomDoubles() 86 array[r.nextInt(array.length)] = Double.MIN_VALUE; in genRandomDoubles() [all …]
|
/cts/tests/tests/text/src/android/text/cts/ |
D | TextUtilsTest.java | 110 for (int i = 0; i < s.length(); i++) { in countChars() 273 string1.setSpan(urlSpan, 0, string1.length() - 1, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testConcat() 275 string2.setSpan(bgColorSpan, 0, string2.length() - 1, Spanned.SPAN_EXCLUSIVE_EXCLUSIVE); in testConcat() 280 Object spans[] = strResult.getSpans(0, strResult.length(), Object.class); in testConcat() 281 assertEquals(2, spans.length); in testConcat() 287 assertEquals(string1.length() - 1, strResult.getSpanEnd(urlSpan)); in testConcat() 288 assertEquals(string1.length() + comma.length(), strResult.getSpanStart(bgColorSpan)); in testConcat() 289 assertEquals(strResult.length() - 1, strResult.getSpanEnd(bgColorSpan)); in testConcat() 309 piece.setSpan(span, 0, piece.length(), Spanned.SPAN_INCLUSIVE_EXCLUSIVE); in testConcat_NullParameters() 312 final Object[] spans = result.getSpans(0, result.length(), Object.class); in testConcat_NullParameters() [all …]
|
D | SpannedTest.java | 65 spanned.charAt(spanned.length()); in testCharAt() 78 text.setSpan(new UnderlineSpan(), 5, text.length(), flags); in testNextSpanTransition() 84 assertEquals(4, spanned.nextSpanTransition(1, spanned.length(), QuoteSpan.class)); in testNextSpanTransition() 85 assertEquals(spanned.length(), in testNextSpanTransition() 86 spanned.nextSpanTransition(4, spanned.length(), QuoteSpan.class)); in testNextSpanTransition() 87 assertEquals(5, spanned.nextSpanTransition(4, spanned.length(), UnderlineSpan.class)); in testNextSpanTransition() 89 assertEquals(2, spanned.nextSpanTransition(0, spanned.length(), Object.class)); in testNextSpanTransition() 90 assertEquals(4, spanned.nextSpanTransition(2, spanned.length(), Object.class)); in testNextSpanTransition() 91 assertEquals(5, spanned.nextSpanTransition(4, spanned.length(), Object.class)); in testNextSpanTransition() 92 assertEquals(7, spanned.nextSpanTransition(5, spanned.length(), Object.class)); in testNextSpanTransition() [all …]
|
D | LoginFilterTest.java | 59 assertNull(loginFilter.filter(source1, 0, source1.length(), dest1, 0, dest1.length())); in testFilter() 65 assertNull(loginFilter.filter(source1, 0, source1.length(), dest2, 5, 6)); in testFilter() 71 assertNull(loginFilter.filter(source2, 0, source2.length(), in testFilter() 72 dest1, 0, dest1.length())); in testFilter() 78 assertNull(loginFilter.filter(spannedSource, 0, spannedSource.length(), in testFilter() 79 dest1, 0, dest1.length())); in testFilter() 85 result = loginFilter.filter(source2, 0, source2.length(), dest1, 0, dest1.length()); in testFilter() 93 result = loginFilter.filter(spannedSource, 0, spannedSource.length(), in testFilter() 94 dest1, 0, dest1.length()); in testFilter() 101 loginFilter.filter(null, 0, source1.length(), dest1, 0, dest1.length()); in testFilter() [all …]
|
D | HtmlTest.java | 72 assertEquals(expectLen, spans.length); in verifySingleTagOnWhileString() 93 assertEquals(spansLen, spans.length); in verifyBadHtml() 112 ForegroundColorSpan[] colors = s.getSpans(0, s.length(), type); in testColor() 116 colors = s.getSpans(0, s.length(), type); in testColor() 120 colors = s.getSpans(0, s.length(), type); in testColor() 121 assertEquals(0, colors.length); in testColor() 125 colors = s.getSpans(0, s.length(), type); in testColor() 129 colors = s.getSpans(0, s.length(), type); in testColor() 133 colors = s.getSpans(0, s.length(), type); in testColor() 137 colors = s.getSpans(0, s.length(), type); in testColor() [all …]
|
D | SpannableStringBuilderSpanTest.java | 72 positionSet.addPosition(original.length() / 3); in replace() 73 positionSet.addPosition(2 * original.length() / 3); in replace() 74 positionSet.addPosition(original.length()); in replace() 78 replPositionSet.addPosition(replacement.length() / 3); in replace() 79 replPositionSet.addPosition(2 * replacement.length() / 3); in replace() 80 replPositionSet.addPosition(replacement.length()); in replace() 117 subReplacement + original.substring(replaceEnd, original.length()); in replaceWithSpanFlag() 133 verifySpanPositions(originalSpannable, replaceStart, replaceEnd, subReplacement.length(), in replaceWithSpanFlag() 277 for (int i = 0; i < addedSpans.length; i++) { in verifyReplacementSpanPositions() 379 mPositionSet.addPosition((rangeEnd + spannable.length()) / 2); in initSpans() [all …]
|
/cts/tests/tests/renderscript/src/android/renderscript/cts/refocus/ |
D | XmpDepthDecode.java | 47 XMP_EXTENSION_HEADER.length() + 32 + 1; // 32 byte GUID + 1 byte null termination. 139 public int length; field in XmpDepthDecode.Section 235 section.length = -1; in parse() 237 is.read(section.data, 0, section.data.length); in parse() 247 int length = lh << 8 | ll; in parse() local 249 sections.add(readSection(is, length, marker, skipExtendedContent)); in parse() 253 is.skip(length - 2); in parse() 279 if (data.length < header.length()) { in hasHeader() 283 byte[] buffer = new byte[header.length()]; in hasHeader() 284 System.arraycopy(data, 0, buffer, 0, header.length()); in hasHeader() [all …]
|
/cts/apps/CtsVerifier/src/com/android/cts/verifier/audio/ |
D | Util.java | 50 public static Complex[] padZeros(Complex[] data, int length) { in padZeros() argument 51 Complex[] result = new Complex[length]; in padZeros() 52 if (length < data.length) { in padZeros() 53 System.arraycopy(data, 0, result, 0, length); in padZeros() 55 System.arraycopy(data, 0, result, 0, data.length); in padZeros() 56 for (int i = data.length; i < result.length; i++) { in padZeros() 68 int n = nextPowerOfTwo(Math.max(data1.length, data2.length)); in computeCrossCorrelation() 76 double[] resultDouble = new double[resultComplex.length]; in computeCrossCorrelation() 77 for (int i = 0; i < resultComplex.length; i++) { in computeCrossCorrelation() 87 double[] result = new double[data.length]; in toDouble() [all …]
|
/cts/tests/tests/graphics/src/android/graphics/text/cts/ |
D | MeasuredTextTest.java | 63 .appendStyleRun(sPaint, text.length(), false /* isRtl */).build(); in testBuilder() 70 .appendStyleRun(sPaint, text.length(), false /* isRtl */).build(); in testBuilder_FromExistingMeasuredText() 72 .appendStyleRun(sPaint, text.length(), true /* isRtl */).build()); in testBuilder_FromExistingMeasuredText() 80 .appendStyleRun(sPaint, text.length(), false /* isRtl */).build(); in testBuilder_FromExistingMeasuredText_differentLayoutParam() 82 .appendStyleRun(sPaint, text.length(), true /* isRtl */).build(); in testBuilder_FromExistingMeasuredText_differentLayoutParam() 90 .appendStyleRun(sPaint, text.length(), false /* isRtl */).build(); in testBuilder_FromExistingMeasuredText_differentHyphenationParam() 93 .appendStyleRun(sPaint, text.length(), true /* isRtl */).build(); in testBuilder_FromExistingMeasuredText_differentHyphenationParam() 109 new MeasuredText.Builder(text.toCharArray()).appendStyleRun(null, text.length(), false); in testBuilder_NullPaint() 116 .appendStyleRun(sPaint, text.length(), false /* isRtl */).build(); in testGetWidth() 128 .appendStyleRun(sPaint, text.length(), false /* isRtl */) in testGetWidth_StartSmallerThanZero() [all …]
|
/cts/tests/tests/carrierapi/src/android/carrierapi/cts/ |
D | FcpTemplate.java | 85 int responseLength = data.length; in parseFcpTemplate() 99 int length = data[index++] & 0xFF; // assumes that length is < 128 bytes. in parseFcpTemplate() local 100 String value = fcpResponse.substring(index * 2, (index + length) * 2); in parseFcpTemplate() 101 tlvObjects .add(new Tlv(tag, length, value)); in parseFcpTemplate() 102 index += length; in parseFcpTemplate() 105 String status = fcpResponse.substring(fcpResponse.length() - 4); in parseFcpTemplate() 115 private final int length; field in FcpTemplate.Tlv 118 public Tlv(int tag, int length, @Nonnull String value) { in Tlv() argument 120 this.length = length; in Tlv() 129 return length; in getLength() [all …]
|
/cts/tests/tests/location/src/android/location/cts/psedorange/ |
D | GpsMathOperations.java | 33 for (int i = 0; i < inputVector.length; i++) { in vectorNorm() 46 double[] result = new double[firstVector.length]; in subtractTwoVectors() 47 if (firstVector.length != secondVector.length) { in subtractTwoVectors() 51 for (int i = 0; i < firstVector.length; i++) { in subtractTwoVectors() 65 double result[] = new double[matrix.length]; in matrixByColVectMultiplication() 66 int matrixLength = matrix.length; in matrixByColVectMultiplication() 67 int vectorLength = vector.length; in matrixByColVectMultiplication() 68 if (vectorLength != matrix[0].length) { in matrixByColVectMultiplication() 87 if (firstVector.length != secondVector.length) { in dotProduct() 91 for (int i = 0; i < firstVector.length; i++) { in dotProduct()
|
/cts/hostsidetests/dumpsys/src/android/dumpsys/cts/ |
D | ProcessStatsDumpsysTest.java | 62 assertTrue(procstats.length() > 0); in testProcstatsOutput() 85 if (" ".equals(values[values.length - 1])) { in commaSplit() 86 values[values.length - 1] = ""; in commaSplit() 109 assertEquals(2, parts.length); in checkProcStateOutput() 159 assertTrue("Length should be >= 5, found: " + parts.length, in checkPeriod() 160 parts.length >= 5); in checkPeriod() 163 for (int i = 4; i < parts.length; i++) { in checkPeriod() 179 assertTrue(parts.length >= 5); in checkPkgProc() 186 for (int i = statesStartIndex; i < parts.length; i++) { in checkPkgProc() 188 assertEquals(2, subparts.length); in checkPkgProc() [all …]
|
D | BatteryStatsDumpsysTest.java | 44 assertTrue(batterystats.length() > 0); in testBatterystatsOutput() 225 assertEquals(8, parts.length); in checkVersion() 233 assertEquals(6, parts.length); in checkUid() 239 assertEquals(10, parts.length); in checkApk() 252 assertTrue(parts.length >= 9); in checkProcess() 261 assertEquals(10, parts.length); in checkSensor() 271 assertEquals(6, parts.length); in checkVibrator() 277 assertEquals(6, parts.length); in checkForegroundActivity() 283 assertEquals(6, parts.length); in checkForegroundService() 289 assertEquals(11, parts.length); in checkStateTime() [all …]
|
/cts/apps/CtsVerifier/src/com/android/cts/verifier/nfc/hcef/ |
D | HceFReaderActivity.java | 59 byte length = (byte) (2 + nfcid2.length + payload.length); in createEchoCommand() 61 byte[] echo_cmd = new byte[length]; in createEchoCommand() 62 echo_cmd[0] = length; in createEchoCommand() 64 System.arraycopy(nfcid2, 0, echo_cmd, 2, nfcid2.length); in createEchoCommand() 65 System.arraycopy(payload, 0, echo_cmd, 2 + nfcid2.length, payload.length); in createEchoCommand() 70 byte[] cmd = new byte[2 + nfcid2.length]; in createSuccessCommand() 71 cmd[0] = (byte) (2 + nfcid2.length); in createSuccessCommand() 73 System.arraycopy(nfcid2, 0, cmd, 2, nfcid2.length); in createSuccessCommand() 81 if (resp[0] != resp.length) return false; in verifyResponse() 82 if (resp.length != cmd.length) return false; in verifyResponse() [all …]
|
/cts/tests/tests/text/src/android/text/util/cts/ |
D | LinkifyTest.java | 76 for (int i = 0, size = matchingRegion.length(); i < size; i++) { 115 URLSpan[] spans = spannable.getSpans(0, spannable.length(), URLSpan.class); in testAddLinksToSpannable() 116 assertEquals(4, spans.length); in testAddLinksToSpannable() 123 spans = spannable.getSpans(0, spannable.length(), URLSpan.class); in testAddLinksToSpannable() 124 assertEquals(1, spans.length); in testAddLinksToSpannable() 143 URLSpan[] spans = ((Spannable) tv.getText()).getSpans(0, text.length(), URLSpan.class); in testAddLinksToTextView() 144 assertEquals(1, spans.length); in testAddLinksToTextView() 150 spans = ((Spannable) tv.getText()).getSpans(0, text.length(), URLSpan.class); in testAddLinksToTextView() 151 assertEquals(1, spans.length); in testAddLinksToTextView() 171 URLSpan[] spans = ((Spannable) tv.getText()).getSpans(0, text.length(), URLSpan.class); in testAddLinksToTextViewWithScheme() [all …]
|
/cts/tests/tests/graphics/src/android/graphics/cts/ |
D | PaintTest.java | 138 float[] widths = new float[text.length()]; in testBreakText() 139 assertEquals(text.length(), p.getTextWidths(text, widths)); in testBreakText() 142 for (int i = 0; i < text.length(); i++) { in testBreakText() 146 for (int i = 0; i < text.length(); i++) { in testBreakText() 190 float[] emojiWidths = new float[emoji.length()]; in testBreakText() 191 assertEquals(emoji.length(), p.getTextWidths(emoji, emojiWidths)); in testBreakText() 234 for (int i = 0; i < measured.length; i++) { in verifyBreakText() 1009 float[] widths = new float[text.length()]; 1100 p.getTextBounds(text1, 0, text1.length(), bounds1); 1102 p.getTextBounds(textChars1, 0, textChars1.length, bounds2); [all …]
|
/cts/tests/tests/secure_element/omapi/src/android/omapi/cts/ |
D | OmapiTest.java | 308 if (readers != null && readers.length > 0) { in testATR() 309 for (int i = 0; i < readers.length; i++) { in testATR() 439 assertGreaterOrEqual(selectResponse.length, 2); in testSelectableAid() 440 assertThat(selectResponse[selectResponse.length - 1] & 0xFF, is(0x00)); in testSelectableAid() 441 assertThat(selectResponse[selectResponse.length - 2] & 0xFF, is(0x90)); in testSelectableAid() 496 assertGreaterOrEqual(selectResponse.length, 2); in testSecurityExceptionInTransmit() 497 assertThat(selectResponse[selectResponse.length - 1] & 0xFF, is(0x00)); in testSecurityExceptionInTransmit() 498 assertThat(selectResponse[selectResponse.length - 2] & 0xFF, is(0x90)); in testSecurityExceptionInTransmit() 529 assertGreaterOrEqual(selectResponse.length, 2); in internalTransmitApdu() 550 assertGreaterOrEqual(selectResponse.length, 2); in internalTransmitApduWithoutP2() [all …]
|
/cts/tests/signature/api-check/src/java/android/signature/cts/api/ |
D | BootClassPathClassesProvider.java | 45 return classname.substring(1, classname.length() - 1); in getAllClasses() 62 if (field_infos.length != 2 || field_infos[0].length != field_infos[1].length || in getAllMembers() 63 method_infos.length != 2 || method_infos[0].length != method_infos[1].length) { in getAllMembers() 68 DexMember[] members = new DexMember[field_infos[0].length + method_infos[0].length]; in getAllMembers() 69 for (int i = 0; i < field_infos[0].length; i++) { in getAllMembers() 72 for (int i = 0; i < method_infos[0].length; i++) { in getAllMembers() 73 members[i + field_infos[0].length] = in getAllMembers()
|
/cts/apps/CtsVerifier/src/com/android/cts/verifier/audio/peripheralprofile/ |
D | ListsHelper.java | 21 if (a.length != b.length) { in isMatch() 25 int len = a.length; in isMatch() 51 if (a.length > b.length) { in isSubset() 67 for (int index = 0; index < list.length; index++) { in textFormatHex() 69 if (index < list.length-1) { in textFormatHex() 80 for (int index = 0; index < list.length; index++) { in textFormatDecimal() 82 if (index < list.length-1) { in textFormatDecimal()
|
D | AudioStringsHelper.java | 43 return fmt < formatStrings.length ? formatStrings[fmt] : ("" + fmt + " Unknown Format "); in encodingToString() 47 return fmt < shortFormatStrings.length in encodingToShortString() 63 for(int rateIndex = 0; rateIndex < rates.length; rateIndex++) { in buildRatesStr() 65 if (rateIndex < rates.length - 1) { in buildRatesStr() 75 for(int encodingIndex = 0; encodingIndex < encodings.length; encodingIndex++) { in buildEncodingsStr() 77 if (encodingIndex < encodings.length - 1) { in buildEncodingsStr() 97 for (int index = 0; index < values.length; index++) { in makeIntList() 99 if (index < values.length - 1) { in makeIntList() 110 for (int index = 0; index < values.length; index++) { in makeHexList() 112 if (index < values.length - 1) { in makeHexList()
|
/cts/tests/tests/keystore/src/android/keystore/cts/ |
D | BlockCipherTestBase.java | 386 assertEquals(getKatIv().length, generatedIv.length); in testIvGeneratedAndUsedWhenEncryptingWithoutExplicitIv() 448 + (ivBeforeReinitialization.length * 8) + "})"); in testGeneratedIvDoesNotSurviveReinitialization() 465 + (getKatIv().length * 8) + "})"); in testExplicitlySetIvDoesNotSurviveReinitialization() 589 if (input.length < getBlockSize() * 2) { in assertDoFinalResetsCipher() 594 doFinal(subarray(input, getBlockSize() * 3 / 2, input.length)))); in assertDoFinalResetsCipher() 665 assertEquals(getBlockSize(), output.length); in assertUpdateDoesNotProduceOutputWhenInsufficientInput() 697 assertEquals(expectedOutput, doFinal(input, 0, input.length)); in assertKatOneShotTransformUsingDoFinal() 702 input.length)); in assertKatOneShotTransformUsingDoFinal() 707 input.length); in assertKatOneShotTransformUsingDoFinal() 708 ByteBuffer actualOutputBuffer = ByteBuffer.allocate(expectedOutput.length); in assertKatOneShotTransformUsingDoFinal() [all …]
|