/packages/apps/SecureElement/src/com/android/se/security/gpac/ |
D | BerTlv.java | 60 StringBuilder sb = new StringBuilder(digest.length * 2); in toHex() 78 if (data == null || data.length == 0) { in decode() 86 if (curIndex < data.length) { in decode() 91 if (curIndex < data.length) { in decode() 95 "Index " + curIndex + " out of range! [0..[" + data.length); in decode() 104 throw new ParserException("Index " + curIndex + " out of range! [0..[" + data.length); in decode() 108 int length; in decode() local 109 if (curIndex < data.length) { in decode() 112 length = temp; in decode() 114 if (curIndex < data.length) { in decode() [all …]
|
/packages/apps/Gallery2/gallerycommon/src/com/android/gallery3d/exif/ |
D | ExifTag.java | 237 if (checkBadComponentCount(value.length)) { in setValue() 250 long[] data = new long[value.length]; in setValue() 251 for (int i = 0; i < value.length; i++) { in setValue() 255 mComponentCountActual = value.length; in setValue() 287 if (checkBadComponentCount(value.length) || mDataType != TYPE_UNSIGNED_LONG) { in setValue() 294 mComponentCountActual = value.length; in setValue() 334 if (buf.length > 0) { in setValue() 335 finalBuf = (buf[buf.length - 1] == 0 || mDataType == TYPE_UNDEFINED) ? buf : Arrays in setValue() 336 .copyOf(buf, buf.length + 1); in setValue() 340 int count = finalBuf.length; in setValue() [all …]
|
/packages/apps/Camera2/src/com/android/camera/exif/ |
D | ExifTag.java | 237 if (checkBadComponentCount(value.length)) { in setValue() 250 long[] data = new long[value.length]; in setValue() 251 for (int i = 0; i < value.length; i++) { in setValue() 255 mComponentCountActual = value.length; in setValue() 287 if (checkBadComponentCount(value.length) || mDataType != TYPE_UNSIGNED_LONG) { in setValue() 294 mComponentCountActual = value.length; in setValue() 334 if (buf.length > 0) { in setValue() 335 finalBuf = (buf[buf.length - 1] == 0 || mDataType == TYPE_UNDEFINED) ? buf : Arrays in setValue() 336 .copyOf(buf, buf.length + 1); in setValue() 340 int count = finalBuf.length; in setValue() [all …]
|
/packages/apps/Messaging/src/com/android/messaging/util/exif/ |
D | ExifTag.java | 237 if (checkBadComponentCount(value.length)) { in setValue() 250 long[] data = new long[value.length]; in setValue() 251 for (int i = 0; i < value.length; i++) { in setValue() 255 mComponentCountActual = value.length; in setValue() 287 if (checkBadComponentCount(value.length) || mDataType != TYPE_UNSIGNED_LONG) { in setValue() 294 mComponentCountActual = value.length; in setValue() 334 if (buf.length > 0) { in setValue() 335 finalBuf = (buf[buf.length - 1] == 0 || mDataType == TYPE_UNDEFINED) ? buf : Arrays in setValue() 336 .copyOf(buf, buf.length + 1); in setValue() 340 int count = finalBuf.length; in setValue() [all …]
|
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/ |
D | RichInputConnection.java | 172 final int actualLength = Math.min(beforeCursor.length(), internal.length()); in checkConsistencyForDebug() 173 if (internal.length() > actualLength) { in checkConsistencyForDebug() 174 internal.delete(0, internal.length() - actualLength); in checkConsistencyForDebug() 176 final String reference = (beforeCursor.length() <= actualLength) ? beforeCursor.toString() in checkConsistencyForDebug() 177 : beforeCursor.subSequence(beforeCursor.length() - actualLength, in checkConsistencyForDebug() 178 beforeCursor.length()).toString(); in checkConsistencyForDebug() 183 + "\nExpected text = " + internal.length() + " " + internal in checkConsistencyForDebug() 184 + "\nActual text = " + reference.length() + " " + reference; in checkConsistencyForDebug() 309 mExpectedSelStart += text.length() - mComposingText.length(); in commitText() 316 0, text.length(), CharacterStyle.class); in commitText() [all …]
|
/packages/inputmethods/LatinIME/tests/src/com/android/inputmethod/latin/makedict/ |
D | FusionDictionary.java | 160 assert(mChars.length > 0); in hasSeveralChars() 161 return 1 < mChars.length; in hasSeveralChars() 248 final int length = word.length(); in getCodePoints() local 249 if (length <= 0) return new int[] {}; in getCodePoints() 251 final int[] codePoints = new int[Character.codePointCount(characters, 0, length)]; in getCodePoints() 255 srci < length; srci += Character.charCount(codePoint), ++dsti) { in getCodePoints() 336 if (word.length >= DecoderSpecificConstants.DICTIONARY_MAX_WORD_LENGTH) { in add() 337 MakedictLog.w("Ignoring a word that is too long: word.length = " + word.length); in add() 351 && differentCharIndex < currentPtNode.mChars.length) break; in add() 353 charIndex += currentPtNode.mChars.length; in add() [all …]
|
/packages/apps/Bluetooth/src/com/android/bluetooth/opp/ |
D | BluetoothOppSendFileInfo.java | 82 public BluetoothOppSendFileInfo(String fileName, String type, long length, in BluetoothOppSendFileInfo() argument 86 mLength = length; in BluetoothOppSendFileInfo() 93 public BluetoothOppSendFileInfo(String data, String type, long length, int status) { in BluetoothOppSendFileInfo() argument 98 mLength = length; in BluetoothOppSendFileInfo() 108 long length = 0; in generateFileInfo() local 136 length = metadataCursor.getLong(indexSize); in generateFileInfo() 139 Log.d(TAG, "fileName = " + fileName + " length = " + length); in generateFileInfo() 165 length = f.length(); in generateFileInfo() 179 if (length != statLength && statLength > 0) { in generateFileInfo() 180 Log.e(TAG, "Content provider length is wrong (" + Long.toString(length) in generateFileInfo() [all …]
|
/packages/apps/Bluetooth/src/com/android/bluetooth/map/ |
D | BluetoothMapbMessage.java | 150 if (numbers != null && numbers.length > 0) { in setPhoneNumbers() 151 mPhoneNumbers = new String[numbers.length]; in setPhoneNumbers() 152 for (int i = 0, n = numbers.length; i < n; i++) { in setPhoneNumbers() 164 if (networkNumber != null && networkNumber.length() > 1 && !alpha) { in setPhoneNumbers() 174 if (mPhoneNumbers.length > 0) { in getFirstPhoneNumber() 190 if (mEmailAddresses.length > 0) { in getFirstEmail() 198 if (mBtUcis.length > 0) { in getFirstBtUci() 206 if (mBtUids.length > 0) { in getFirstBtUid() 258 if (parts.length == 2) { in parseVcard() 265 if (parts.length == 2) { in parseVcard() [all …]
|
/packages/apps/LegacyCamera/src/com/android/camera/ |
D | Exif.java | 30 int length = 0; in getOrientation() local 33 while (offset + 3 < jpeg.length && (jpeg[offset++] & 0xFF) == 0xFF) { in getOrientation() 52 length = pack(jpeg, offset, 2, false); in getOrientation() 53 if (length < 2 || offset + length > jpeg.length) { in getOrientation() 59 if (marker == 0xE1 && length >= 8 && in getOrientation() 63 length -= 8; in getOrientation() 68 offset += length; in getOrientation() 69 length = 0; in getOrientation() 73 if (length > 8) { in getOrientation() 84 if (count < 10 || count > length) { in getOrientation() [all …]
|
/packages/apps/Nfc/nci/src/com/android/nfc/dhimpl/ |
D | NativeNfcTag.java | 158 for (int i = 0; i < mTechList.length; i++) { in connectWithStatus() 432 if (mTechHandles.length > 0) { in getHandle() 454 if (mConnectedTechIndex != -1 && mConnectedTechIndex < mTechLibNfcTypes.length) { in getConnectedLibNfcType() 463 if (mConnectedTechIndex != -1 && mConnectedTechIndex < mTechList.length) { in getConnectedTechnology() 475 int[] mNewTechList = new int[mTechList.length + 1]; in addTechnology() 476 System.arraycopy(mTechList, 0, mNewTechList, 0, mTechList.length); in addTechnology() 477 mNewTechList[mTechList.length] = tech; in addTechnology() 480 int[] mNewHandleList = new int[mTechHandles.length + 1]; in addTechnology() 481 System.arraycopy(mTechHandles, 0, mNewHandleList, 0, mTechHandles.length); in addTechnology() 482 mNewHandleList[mTechHandles.length] = handle; in addTechnology() [all …]
|
/packages/inputmethods/LatinIME/tests/src/com/android/inputmethod/latin/utils/ |
D | SpannableStringUtilsTests.java | 63 final CharSequence b = s.subSequence(15, s.length()); in testConcatWithSuggestionSpansOnly() 67 Object[] spans = result.getSpans(0, result.length(), SuggestionSpan.class); in testConcatWithSuggestionSpansOnly() 68 for (int i = 0; i < spans.length; i++) { in testConcatWithSuggestionSpansOnly() 80 actualCount = spanned.getSpans(0, spanned.length(), Object.class).length; in assertSpanCount() 91 final Object[] actualSpans = spanned.getSpans(0, spanned.length(), Object.class); in assertSpan() 128 assertEquals(7, charSequencesFromString.length); in testSplitCharSequenceWithSpan() 129 assertEquals(7, charSequencesFromSpanned.length); in testSplitCharSequenceWithSpan() 205 false /* preserveTrailingEmptySegmengs */).length); in testSplitCharSequencePreserveTrailingEmptySegmengs() 207 false /* preserveTrailingEmptySegmengs */).length); in testSplitCharSequencePreserveTrailingEmptySegmengs() 210 true /* preserveTrailingEmptySegmengs */).length); in testSplitCharSequencePreserveTrailingEmptySegmengs() [all …]
|
/packages/apps/Bluetooth/src/com/android/bluetooth/gatt/ |
D | AdvertiseHelper.java | 58 int nameLength = nameBytes.length; in advertiseDataToBytes() 81 int dataLen = 2 + (manufacturerData == null ? 0 : manufacturerData.length); in advertiseDataToBytes() 87 System.arraycopy(manufacturerData, 0, concated, 2, manufacturerData.length); in advertiseDataToBytes() 90 ret.write(concated.length + 1); in advertiseDataToBytes() 92 ret.write(concated, 0, concated.length); in advertiseDataToBytes() 109 if (uuid.length == BluetoothUuid.UUID_BYTES_16_BIT) { in advertiseDataToBytes() 110 serviceUuids16.write(uuid, 0, uuid.length); in advertiseDataToBytes() 111 } else if (uuid.length == BluetoothUuid.UUID_BYTES_32_BIT) { in advertiseDataToBytes() 112 serviceUuids32.write(uuid, 0, uuid.length); in advertiseDataToBytes() 114 serviceUuids128.write(uuid, 0, uuid.length); in advertiseDataToBytes() [all …]
|
/packages/inputmethods/LatinIME/common/src/com/android/inputmethod/latin/common/ |
D | StringUtils.java | 56 return (str == null || str.length() == 0); in isEmpty() 95 final int length; in equals() local 96 if (a != null && b != null && (length = a.length()) == b.length()) { in equals() 100 for (int i = 0; i < length; i++) { in equals() 114 return Character.codePointCount(text, 0, text.length()); in codePointCount() 164 final ArrayList<String> result = new ArrayList<>(elements.length - 1); in removeFromCommaSplittableTextIfExists() 203 if (s.length() <= 1) { in capitalizeFirstCodePoint() 216 if (s.length() <= 1) { in capitalizeFirstAndDowncaseRest() 233 return toCodePointArray(charSequence, 0, charSequence.length()); in toCodePointArray() 249 final int length = charSequence.length(); in toCodePointArray() local [all …]
|
/packages/apps/SecureElement/src/com/android/se/security/arf/PKCS15/ |
D | EF.java | 81 if ((data == null) || (data.length < 15)) { in decodeSIMFileProps() 125 if ((buffer != null) && (buffer.length >= 2)) { in decodeUSIMFileProps() 131 if ((buffer != null) && (buffer.length >= 2)) { in decodeUSIMFileProps() 148 if (buffer.length == 5) { in decodeUSIMFileProps() 171 if ((path == null) || (path.length == 0) || ((path.length % 2) != 0)) { in selectFile() 174 int length = path.length; in selectFile() local 186 for (int index = 0; index < length; index += 2) { in selectFile() 194 int sw1 = data[data.length - 2] & 0xFF; in selectFile() 196 return (sw1 << 8) | (data[data.length - 1] & 0xFF); in selectFile() 222 int length, pos = 0; in readBinary() local [all …]
|
/packages/apps/Dialer/java/com/android/voicemail/impl/mail/ |
D | Address.java | 128 if (tokens.length > 0) { in getEmailAddress() 177 if (personal.length() == 0) { in decodeAddressPersonal() 192 if (addressList != null && addressList.length() > 0) { in isAllValid() 194 for (int i = 0, length = tokens.length; i < length; ++i) { in isAllValid() 213 if (addressList == null || addressList.length() == 0) { in parse() 218 for (int i = 0, length = tokens.length; i < length; ++i) { in parse() 317 if (addresses == null || addresses.length == 0) { in toString() 320 if (addresses.length == 1) { in toString() 324 for (int i = 1; i < addresses.length; i++) { in toString() 354 if (addresses == null || addresses.length == 0) { in toHeader() [all …]
|
D | FixedLengthInputStream.java | 28 private final int length; field in FixedLengthInputStream 31 public FixedLengthInputStream(InputStream in, int length) { in FixedLengthInputStream() argument 33 this.length = length; in FixedLengthInputStream() 38 return length - count; in available() 43 if (count < length) { in read() 52 public int read(byte[] b, int offset, int length) throws IOException { in read() argument 53 if (count < this.length) { in read() 54 int d = in.read(b, offset, Math.min(this.length - count, length)); in read() 68 return read(b, 0, b.length); in read() 72 return length; in getLength() [all …]
|
/packages/modules/IPsec/src/java/com/android/internal/net/ipsec/ike/message/ |
D | IkeConfigPayload.java | 206 int length = Short.toUnsignedInt(inputBuffer.getShort()); in decodeAttributeFrom() local 207 byte[] value = new byte[length]; in decodeAttributeFrom() 310 protected abstract boolean isLengthValid(int length); in isLengthValid() argument 359 super(attributeType, value.length); in TunnelModeChildConfigAttrIpv4AddressBase() 361 if (value.length == VALUE_LEN_NOT_INCLUDED) { in TunnelModeChildConfigAttrIpv4AddressBase() 391 protected boolean isLengthValid(int length) { in isLengthValid() argument 392 return length == IPV4_ADDRESS_LEN || length == VALUE_LEN_NOT_INCLUDED; in isLengthValid() 416 super(attributeType, value.length); in IkeConfigAttrIpv4AddressBase() 418 if (value.length == VALUE_LEN_NOT_INCLUDED) { in IkeConfigAttrIpv4AddressBase() 448 protected boolean isLengthValid(int length) { in isLengthValid() argument [all …]
|
/packages/apps/Test/connectivity/sl4n/rapidjson/include/rapidjson/internal/ |
D | strtod.h | 130 inline bool StrtodDiyFp(const char* decimals, size_t length, size_t decimalPosition, int exp, doubl… in StrtodDiyFp() argument 133 for (; i < length; i++) { in StrtodDiyFp() 140 if (i < length && decimals[i] >= '5') // Rounding in StrtodDiyFp() 143 size_t remaining = length - i; in StrtodDiyFp() 169 …if (length + static_cast<unsigned>(adjustment)> 19u) // has more digits than decimal digits in 64-… in StrtodDiyFp() 207 inline double StrtodBigInteger(double approx, const char* decimals, size_t length, size_t decimalPo… in StrtodBigInteger() argument 208 const BigInteger dInt(decimals, length); in StrtodBigInteger() 209 const int dExp = (int)decimalPosition - (int)length + exp; in StrtodBigInteger() 225 inline double StrtodFullPrecision(double d, int p, const char* decimals, size_t length, size_t deci… in StrtodFullPrecision() argument 227 RAPIDJSON_ASSERT(length >= 1); in StrtodFullPrecision() [all …]
|
/packages/apps/SecureElement/src/com/android/se/security/ |
D | CommandApdu.java | 62 mLc = data.length; in CommandApdu() 71 mLc = data.length; in CommandApdu() 90 if (header1.length < 4 || header2.length < 4) { in compareHeaders() 134 mLc = data.length; in setData() 150 int length = 4; // CLA, INS, P1, P2 in toBytes() local 151 if (mData.length != 0) { in toBytes() 152 length += 1; // LC in toBytes() 153 length += mData.length; // DATA in toBytes() 156 length += 1; // LE in toBytes() 159 byte[] apdu = new byte[length]; in toBytes() [all …]
|
/packages/apps/Dialer/java/com/android/dialer/callcomposer/camera/exif/ |
D | ExifTag.java | 223 if (checkBadComponentCount(value.length)) { in setValue() 237 long[] data = new long[value.length]; in setValue() 238 for (int i = 0; i < value.length; i++) { in setValue() 242 componentCountActual = value.length; in setValue() 257 if (checkBadComponentCount(value.length) || dataType != TYPE_UNSIGNED_LONG) { in setValue() 264 componentCountActual = value.length; in setValue() 289 if (buf.length > 0) { in setValue() 291 (buf[buf.length - 1] == 0 || dataType == TYPE_UNDEFINED) in setValue() 293 : Arrays.copyOf(buf, buf.length + 1); in setValue() 297 int count = finalBuf.length; in setValue() [all …]
|
/packages/apps/SecureElement/src/com/android/se/internal/ |
D | Util.java | 38 byte[] data = new byte[array1.length + array2.length]; in mergeBytes() 39 System.arraycopy(array1, 0, data, 0, array1.length); in mergeBytes() 40 System.arraycopy(array2, 0, data, array1.length, array2.length); in mergeBytes() 45 public static byte[] getMid(byte[] array, int start, int length) { in getMid() argument 46 byte[] data = new byte[length]; in getMid() 47 System.arraycopy(array, start, data, 0, length); in getMid() 59 public static byte[] appendResponse(byte[] r1, byte[] r2, int length) { in appendResponse() argument 60 byte[] rsp = new byte[r1.length + length]; in appendResponse() 61 System.arraycopy(r1, 0, rsp, 0, r1.length); in appendResponse() 62 System.arraycopy(r2, 0, rsp, r1.length, length); in appendResponse() [all …]
|
/packages/apps/CellBroadcastReceiver/tests/testapp/src/com/android/cellbroadcastreceiver/tests/ |
D | GsmSmsCbMessage.java | 100 if (subIds != null && subIds.length > 0) { in createSmsCbMessage() 132 if (pdu.length > wacDataOffset) { in createSmsCbMessage() 184 if (offset + wacDataLength > pdu.length) { in parseWarningAreaCoordinates() 186 + "least " + offset + wacDataLength + ", actual is " + pdu.length); in parseWarningAreaCoordinates() 197 int length = bitReader.read(10); in parseWarningAreaCoordinates() local 198 remainedBytes -= length; in parseWarningAreaCoordinates() 210 int n = (length - 2) * 8 / 44; in parseWarningAreaCoordinates() 262 if (pdu.length < SmsCbHeader.PDU_HEADER_LENGTH + 1 + (PDU_BODY_PAGE_LENGTH + 1) in parseUmtsBody() 264 throw new IllegalArgumentException("Pdu length " + pdu.length + " does not match " in parseUmtsBody() 274 int length = pdu[offset + PDU_BODY_PAGE_LENGTH]; in parseUmtsBody() local [all …]
|
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/keyboard/internal/ |
D | MatrixUtils.java | 103 final int size = squareMatrix.length; in inverse() 104 if (squareMatrix[0].length != size || inverseMatrix.length != size in inverse() 105 || inverseMatrix[0].length != size) { in inverse() 125 if (m0[0].length != m1.length) { in multiply() 127 "--- invalid length for multiply " + m0[0].length + ", " + m1.length); in multiply() 129 final int m0h = m0.length; in multiply() 130 final int m0w = m0[0].length; in multiply() 131 final int m1w = m1[0].length; in multiply() 132 if (retval.length != m0h || retval[0].length != m1w) { in multiply() 134 "--- invalid length of retval " + retval.length + ", " + retval[0].length); in multiply() [all …]
|
/packages/modules/CellBroadcastService/src/com/android/cellbroadcastservice/ |
D | GsmSmsCbMessage.java | 101 if (subIds != null && subIds.length > 0) { in createSmsCbMessage() 133 if (pdu.length > wacDataOffset) { in createSmsCbMessage() 194 int length = bitReader.read(7); in createGeoFencingTriggerMessage() local 198 int messageIdentifierCount = (length - 2) * 8 / 32; in createGeoFencingTriggerMessage() 229 if (offset + wacDataLength > pdu.length) { in parseWarningAreaCoordinates() 231 + "least " + offset + wacDataLength + ", actual is " + pdu.length); in parseWarningAreaCoordinates() 242 int length = bitReader.read(10); in parseWarningAreaCoordinates() local 243 remainedBytes -= length; in parseWarningAreaCoordinates() 255 int n = (length - 2) * 8 / 44; in parseWarningAreaCoordinates() 308 if (pdu.length < SmsCbHeader.PDU_HEADER_LENGTH + 1 + (PDU_BODY_PAGE_LENGTH + 1) in parseUmtsBody() [all …]
|
/packages/apps/SecureElement/src/com/android/se/ |
D | CommandApduValidator.java | 54 if (apdu.length < CMD_APDU_LENGTH_CASE1) { in execute() 55 throw new IllegalArgumentException("Invalid length for command (" + apdu.length + ")."); in execute() 60 if (apdu.length == CMD_APDU_LENGTH_CASE1) { in execute() 64 if (apdu.length == CMD_APDU_LENGTH_CASE2) { in execute() 71 if (apdu.length == CMD_APDU_LENGTH_CASE3_WITHOUT_DATA + lc) { in execute() 74 if (apdu.length == CMD_APDU_LENGTH_CASE4_WITHOUT_DATA + lc) { in execute() 75 checkLe((int) 0x0FF & apdu[apdu.length - 1]); in execute() 81 if (apdu.length == CMD_APDU_LENGTH_CASE2_EXTENDED) { in execute() 87 if (apdu.length <= OFFSET_DATA_EXTENDED) { in execute() 88 throw new IllegalArgumentException("Unexpected value of Lc or Le" + apdu.length); in execute() [all …]
|