/packages/inputmethods/LatinIME/native/jni/tests/dictionary/utils/ |
D | format_utils_test.cpp | 29 EXPECT_EQ(0x9BC13AFE, FormatUtils::MAGIC_NUMBER) << "Magic number must not be changed."; in TEST() 54 EXPECT_EQ(FormatUtils::UNKNOWN_VERSION, in TEST() 55 FormatUtils::detectFormatVersion(ReadOnlyByteArrayView())); in TEST() 59 getBuffer(FormatUtils::MAGIC_NUMBER, FormatUtils::VERSION_2, 0, 0); in TEST() 60 EXPECT_EQ(FormatUtils::VERSION_2, FormatUtils::detectFormatVersion( in TEST() 65 getBuffer(FormatUtils::MAGIC_NUMBER, FormatUtils::VERSION_402, 0, 0); in TEST() 66 EXPECT_EQ(FormatUtils::VERSION_402, FormatUtils::detectFormatVersion( in TEST() 71 getBuffer(FormatUtils::MAGIC_NUMBER, FormatUtils::VERSION_403, 0, 0); in TEST() 72 EXPECT_EQ(FormatUtils::VERSION_403, FormatUtils::detectFormatVersion( in TEST() 78 getBuffer(FormatUtils::MAGIC_NUMBER - 1, FormatUtils::VERSION_2, 0, 0); in TEST() [all …]
|
/packages/apps/DocumentsUI/tests/unit/com/android/documentsui/util/ |
D | FormatUtilsTest.java | 26 assertEquals("0 seconds", FormatUtils.formatDuration(0)); in testFormatDuration_seconds() 27 assertEquals("0 seconds", FormatUtils.formatDuration(1)); in testFormatDuration_seconds() 28 assertEquals("0 seconds", FormatUtils.formatDuration(499)); in testFormatDuration_seconds() 29 assertEquals("1 second", FormatUtils.formatDuration(500)); in testFormatDuration_seconds() 30 assertEquals("1 second", FormatUtils.formatDuration(1000)); in testFormatDuration_seconds() 31 assertEquals("2 seconds", FormatUtils.formatDuration(1500)); in testFormatDuration_seconds() 36 assertEquals("59 seconds", FormatUtils.formatDuration(59000)); in testFormatDuration_Minutes() 37 assertEquals("60 seconds", FormatUtils.formatDuration(59500)); in testFormatDuration_Minutes() 38 assertEquals("1 minute", FormatUtils.formatDuration(60000)); in testFormatDuration_Minutes() 39 assertEquals("1 minute", FormatUtils.formatDuration(65000)); in testFormatDuration_Minutes() [all …]
|
/packages/inputmethods/LatinIME/native/jni/src/dictionary/structure/ |
D | dictionary_structure_with_buffer_policy_factory.cpp | 59 FormatUtils::FORMAT_VERSION dictFormatVersion = FormatUtils::getFormatVersion(formatVersion); in newPolicyForOnMemoryDict() 61 case FormatUtils::VERSION_402: { in newPolicyForOnMemoryDict() 68 case FormatUtils::VERSION_4_ONLY_FOR_TESTING: in newPolicyForOnMemoryDict() 69 case FormatUtils::VERSION_403: { in newPolicyForOnMemoryDict() 85 const FormatUtils::FORMAT_VERSION formatVersion, in newPolicyForOnMemoryV4Dict() 113 const FormatUtils::FORMAT_VERSION formatVersion = FormatUtils::detectFormatVersion( in newPolicyForDirectoryDict() 116 case FormatUtils::VERSION_2: in newPolicyForDirectoryDict() 117 case FormatUtils::VERSION_201: in newPolicyForDirectoryDict() 118 case FormatUtils::VERSION_202: in newPolicyForDirectoryDict() 121 case FormatUtils::VERSION_402: { in newPolicyForDirectoryDict() [all …]
|
D | dictionary_structure_with_buffer_policy_factory.h | 45 newPolicyForOnMemoryV4Dict(const FormatUtils::FORMAT_VERSION formatVersion, 54 const char *const headerFilePath, const FormatUtils::FORMAT_VERSION formatVersion,
|
/packages/inputmethods/LatinIME/native/jni/src/dictionary/header/ |
D | header_policy.h | 35 HeaderPolicy(const uint8_t *const dictBuf, const FormatUtils::FORMAT_VERSION formatVersion) in HeaderPolicy() 60 HeaderPolicy(const FormatUtils::FORMAT_VERSION dictFormatVersion, in HeaderPolicy() 102 : mDictFormatVersion(FormatUtils::UNKNOWN_VERSION), mDictionaryFlags(0), mSize(0), in HeaderPolicy() 116 case FormatUtils::VERSION_2: in getFormatVersionNumber() 117 case FormatUtils::VERSION_201: in getFormatVersionNumber() 119 return FormatUtils::UNKNOWN_VERSION; in getFormatVersionNumber() 120 case FormatUtils::VERSION_202: in getFormatVersionNumber() 121 return FormatUtils::VERSION_202; in getFormatVersionNumber() 122 case FormatUtils::VERSION_4_ONLY_FOR_TESTING: in getFormatVersionNumber() 123 return FormatUtils::VERSION_4_ONLY_FOR_TESTING; in getFormatVersionNumber() [all …]
|
D | header_read_write_utils.cpp | 105 BufferWithExtendableBuffer *const buffer, const FormatUtils::FORMAT_VERSION version, in writeDictionaryVersion() 107 if (!buffer->writeUintAndAdvancePosition(FormatUtils::MAGIC_NUMBER, HEADER_MAGIC_NUMBER_SIZE, in writeDictionaryVersion() 112 case FormatUtils::VERSION_2: in writeDictionaryVersion() 113 case FormatUtils::VERSION_201: in writeDictionaryVersion() 114 case FormatUtils::VERSION_202: in writeDictionaryVersion() 117 case FormatUtils::VERSION_4_ONLY_FOR_TESTING: in writeDictionaryVersion() 118 case FormatUtils::VERSION_402: in writeDictionaryVersion() 119 case FormatUtils::VERSION_403: in writeDictionaryVersion()
|
D | header_read_write_utils.h | 53 const FormatUtils::FORMAT_VERSION version, int *const writingPos);
|
/packages/apps/Contacts/tests/src/com/android/contacts/format/ |
D | FormatUtilsTests.java | 30 assertEquals(2, FormatUtils.overlapPoint("abcde", "cdefg")); in testOverlapPoint() 31 assertEquals(-1, FormatUtils.overlapPoint("John Doe", "John Doe")); in testOverlapPoint() 32 assertEquals(5, FormatUtils.overlapPoint("John Doe", "Doe, John")); in testOverlapPoint() 33 assertEquals(-1, FormatUtils.overlapPoint("Mr. John Doe", "Mr. Doe, John")); in testOverlapPoint() 34 assertEquals(13, FormatUtils.overlapPoint("John Herbert Doe", "Doe, John Herbert")); in testOverlapPoint() 59 FormatUtils.copyToCharArrayBuffer(text, buffer); in checkCharArrayBufferToString() 60 assertEquals(text, FormatUtils.charArrayBufferToString(buffer)); in checkCharArrayBufferToString() 67 FormatUtils.copyToCharArrayBuffer(value, buffer); in checkCopyToCharArrayBuffer() 75 assertEquals(-1, FormatUtils.indexOfWordPrefix("test", null)); in testIndexOfWordPrefix_NullPrefix() 79 assertEquals(-1, FormatUtils.indexOfWordPrefix(null, "TE")); in testIndexOfWordPrefix_NullText() [all …]
|
/packages/inputmethods/LatinIME/native/jni/src/dictionary/utils/ |
D | format_utils.cpp | 23 const uint32_t FormatUtils::MAGIC_NUMBER = 0x9BC13AFE; 26 const size_t FormatUtils::DICTIONARY_MINIMUM_SIZE = 12; 28 /* static */ FormatUtils::FORMAT_VERSION FormatUtils::getFormatVersion(const int formatVersion) { in getFormatVersion() 46 /* static */ FormatUtils::FORMAT_VERSION FormatUtils::detectFormatVersion( in detectFormatVersion()
|
D | dict_file_writing_utils.cpp | 45 const FormatUtils::FORMAT_VERSION formatVersion = FormatUtils::getFormatVersion(dictVersion); in createEmptyDictFile() 47 case FormatUtils::VERSION_402: in createEmptyDictFile() 52 case FormatUtils::VERSION_4_ONLY_FOR_TESTING: in createEmptyDictFile() 53 case FormatUtils::VERSION_403: in createEmptyDictFile() 68 const FormatUtils::FORMAT_VERSION formatVersion) { in createEmptyV4DictFile()
|
D | format_utils.h | 30 class FormatUtils { 54 DISALLOW_IMPLICIT_CONSTRUCTORS(FormatUtils);
|
D | dict_file_writing_utils.h | 52 const FormatUtils::FORMAT_VERSION formatVersion); 58 const FormatUtils::FORMAT_VERSION formatVersion);
|
/packages/apps/DocumentsUI/src/com/android/documentsui/util/ |
D | FormatUtils.java | 30 public class FormatUtils { class 31 private FormatUtils() {} in FormatUtils() method in FormatUtils
|
/packages/inputmethods/LatinIME/native/jni/src/dictionary/structure/v4/ |
D | ver4_dict_buffers.h | 40 const FormatUtils::FORMAT_VERSION formatVersion); 114 const FormatUtils::FORMAT_VERSION formatVersion,
|
D | ver4_dict_buffers.cpp | 35 const FormatUtils::FORMAT_VERSION formatVersion) { in openVer4DictBuffers() 172 const FormatUtils::FORMAT_VERSION formatVersion, in Ver4DictBuffers()
|
/packages/inputmethods/LatinIME/native/jni/src/dictionary/structure/backward/v402/ |
D | ver4_dict_buffers.h | 49 const FormatUtils::FORMAT_VERSION formatVersion); 134 const FormatUtils::FORMAT_VERSION formatVersion);
|
D | ver4_dict_buffers.cpp | 41 const FormatUtils::FORMAT_VERSION formatVersion) { in openVer4DictBuffers() 130 const FormatUtils::FORMAT_VERSION formatVersion) in Ver4DictBuffers()
|
/packages/apps/DocumentsUI/src/com/android/documentsui/ui/ |
D | OperationProgressDialog.java | 31 import com.android.documentsui.util.FormatUtils; 74 FormatUtils.formatDuration(message.arg2))); in OperationProgressDialog()
|
/packages/apps/Contacts/src/com/android/contacts/format/ |
D | TextHighlighter.java | 85 int index = FormatUtils.indexOfWordPrefix(text, trimmedPrefix); in applyPrefixHighlight()
|
D | FormatUtils.java | 30 public class FormatUtils { class
|
/packages/inputmethods/LatinIME/native/jni/src/dictionary/structure/v2/ |
D | patricia_trie_policy.h | 47 FormatUtils::detectFormatVersion(mMmappedBuffer->getReadOnlyByteArrayView())), in PatriciaTriePolicy()
|
/packages/apps/DocumentsUI/src/com/android/documentsui/services/ |
D | CopyJob.java | 87 import com.android.documentsui.util.FormatUtils; 149 FormatUtils.formatDuration(remainingTime))); in getProgressNotification()
|
/packages/apps/Contacts/ |
D | proguard.flags | 32 -keep class com.android.contacts.format.FormatUtils { *; }
|