Searched defs:formatVersion (Results 1 - 14 of 14) sorted by relevance

/packages/inputmethods/LatinIME/native/jni/src/suggest/policyimpl/dictionary/utils/
H A Dformat_utils.cpp28 /* static */ FormatUtils::FORMAT_VERSION FormatUtils::getFormatVersion(const int formatVersion) { argument
29 switch (formatVersion) {
H A Ddict_file_writing_utils.cpp44 const FormatUtils::FORMAT_VERSION formatVersion = FormatUtils::getFormatVersion(dictVersion); local
45 switch (formatVersion) {
50 filePath, localeAsCodePointVector, attributeMap, formatVersion);
55 filePath, localeAsCodePointVector, attributeMap, formatVersion);
67 const FormatUtils::FORMAT_VERSION formatVersion) {
68 HeaderPolicy headerPolicy(formatVersion, localeAsCodePointVector, attributeMap);
64 createEmptyV4DictFile(const char *const dirPath, const std::vector<int> localeAsCodePointVector, const DictionaryHeaderStructurePolicy::AttributeMap *const attributeMap, const FormatUtils::FORMAT_VERSION formatVersion) argument
/packages/inputmethods/LatinIME/tests/src/com/android/inputmethod/latin/utils/
H A DBinaryDictionaryUtilsTests.java39 final int formatVersion) throws IOException {
40 if (formatVersion == FormatSpec.VERSION4) {
43 throw new IOException("Dictionary format version " + formatVersion
73 final int formatVersion = FormatSpec.VERSION4;
76 dictFile0 = createEmptyDictionaryAndGetFile("MoveFromDictionary", formatVersion);
89 assertTrue(binaryDictionary.getFormatVersion() == formatVersion);
38 createEmptyDictionaryAndGetFile(final String dictId, final int formatVersion) argument
/packages/inputmethods/LatinIME/native/jni/src/suggest/policyimpl/dictionary/structure/backward/v402/
H A Dver4_dict_buffers.cpp41 const FormatUtils::FORMAT_VERSION formatVersion) {
50 formatVersion));
130 const FormatUtils::FORMAT_VERSION formatVersion)
134 mHeaderPolicy(mHeaderBuffer->getReadOnlyByteArrayView().data(), formatVersion),
39 openVer4DictBuffers( const char *const dictPath, MmappedBuffer::MmappedBufferPtr headerBuffer, const FormatUtils::FORMAT_VERSION formatVersion) argument
128 Ver4DictBuffers(const char *const dictPath, MmappedBuffer::MmappedBufferPtr headerBuffer, const bool isUpdatable, const FormatUtils::FORMAT_VERSION formatVersion) argument
/packages/inputmethods/LatinIME/native/jni/src/suggest/policyimpl/dictionary/structure/
H A Ddictionary_structure_with_buffer_policy_factory.cpp57 const int formatVersion, const std::vector<int> &locale,
59 FormatUtils::FORMAT_VERSION dictFormatVersion = FormatUtils::getFormatVersion(formatVersion);
76 formatVersion);
85 const FormatUtils::FORMAT_VERSION formatVersion,
88 HeaderPolicy headerPolicy(formatVersion, locale, attributeMap);
113 const FormatUtils::FORMAT_VERSION formatVersion = FormatUtils::detectFormatVersion( local
116 switch (formatVersion) {
125 headerFilePath, formatVersion, std::move(mmappedBuffer));
131 headerFilePath, formatVersion, std::move(mmappedBuffer));
144 const char *const headerFilePath, const FormatUtils::FORMAT_VERSION formatVersion,
56 newPolicyForOnMemoryDict( const int formatVersion, const std::vector<int> &locale, const DictionaryHeaderStructurePolicy::AttributeMap *const attributeMap) argument
84 newPolicyForOnMemoryV4Dict( const FormatUtils::FORMAT_VERSION formatVersion, const std::vector<int> &locale, const DictionaryHeaderStructurePolicy::AttributeMap *const attributeMap) argument
143 newPolicyForV4Dict( const char *const headerFilePath, const FormatUtils::FORMAT_VERSION formatVersion, MmappedBuffer::MmappedBufferPtr &&mmappedBuffer) argument
[all...]
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/dictionarypack/
H A DWordListMetadata.java55 final String remoteFilename, final int version, final int formatVersion,
67 mFormatVersion = formatVersion;
88 final Integer formatVersion = values.getAsInteger(MetadataDbHelper.FORMATVERSION_COLUMN);
100 || null == formatVersion
106 checksum, localFilename, remoteFilename, version, formatVersion, flags, locale);
52 WordListMetadata(final String id, final int type, final String description, final long lastUpdate, final long fileSize, final String rawChecksum, final String checksum, final String localFilename, final String remoteFilename, final int version, final int formatVersion, final int flags, final String locale) argument
H A DMetadataDbHelper.java456 final int formatVersion) {
471 result.put(FORMATVERSION_COLUMN, formatVersion);
452 makeContentValues(final int pendingId, final int type, final int status, final String wordlistId, final String locale, final String description, final String filename, final String url, final long date, final String rawChecksum, final String checksum, final long filesize, final int version, final int formatVersion) argument
/packages/inputmethods/LatinIME/native/jni/src/suggest/policyimpl/dictionary/structure/v4/
H A Dver4_dict_buffers.cpp35 const FormatUtils::FORMAT_VERSION formatVersion) {
69 formatVersion, buffers, bufferSizes));
180 const FormatUtils::FORMAT_VERSION formatVersion,
183 mHeaderPolicy(mHeaderBuffer->getReadOnlyByteArrayView().data(), formatVersion),
33 openVer4DictBuffers( const char *const dictPath, MmappedBuffer::MmappedBufferPtr &&headerBuffer, const FormatUtils::FORMAT_VERSION formatVersion) argument
178 Ver4DictBuffers(MmappedBuffer::MmappedBufferPtr &&headerBuffer, MmappedBuffer::MmappedBufferPtr &&bodyBuffer, const FormatUtils::FORMAT_VERSION formatVersion, const std::vector<uint8_t *> &contentBuffers, const std::vector<int> &contentBufferSizes) argument
/packages/inputmethods/LatinIME/tests/src/com/android/inputmethod/latin/
H A DBinaryDictionaryDecayingTests.java67 private static boolean supportsBeginningOfSentence(final int formatVersion) { argument
68 return formatVersion > FormatSpec.VERSION401;
107 final int formatVersion) throws IOException {
108 if (formatVersion == FormatSpec.VERSION4
109 || formatVersion == FormatSpec.VERSION4_ONLY_FOR_TESTING
110 || formatVersion == FormatSpec.VERSION4_DEV) {
111 return createEmptyVer4DictionaryAndGetFile(dictId, formatVersion);
113 throw new IOException("Dictionary format version " + formatVersion
118 private File createEmptyVer4DictionaryAndGetFile(final String dictId, final int formatVersion) argument
131 if (BinaryDictionaryUtils.createEmptyDictFile(file.getAbsolutePath(), formatVersion,
106 createEmptyDictionaryAndGetFile(final String dictId, final int formatVersion) argument
154 testReadDictInJavaSide(final int formatVersion) argument
216 testAddValidAndInvalidWords(final int formatVersion) argument
261 testDecayingProbability(final int formatVersion) argument
318 testAddManyUnigramsToDecayingDict(final int formatVersion) argument
379 testOverflowUnigrams(final int formatVersion) argument
440 testAddManyBigramsToDecayingDict(final int formatVersion) argument
516 testOverflowBigrams(final int formatVersion) argument
648 testBeginningOfSentence(final int formatVersion) argument
[all...]
H A DBinaryDictionaryTests.java50 private static boolean canCheckBigramProbability(final int formatVersion) { argument
51 return formatVersion > FormatSpec.VERSION401;
54 private static boolean supportsBeginningOfSentence(final int formatVersion) { argument
55 return formatVersion > FormatSpec.VERSION401;
59 final int formatVersion) throws IOException {
60 if (formatVersion == FormatSpec.VERSION4
61 || formatVersion == FormatSpec.VERSION4_ONLY_FOR_TESTING
62 || formatVersion == FormatSpec.VERSION4_DEV) {
63 return createEmptyVer4DictionaryAndGetFile(dictId, formatVersion);
65 throw new IOException("Dictionary format version " + formatVersion
58 createEmptyDictionaryAndGetFile(final String dictId, final int formatVersion) argument
70 createEmptyVer4DictionaryAndGetFile(final String dictId, final int formatVersion) argument
92 testIsValidDictionary(final int formatVersion) argument
122 testConstructingDictionaryOnMemory(final int formatVersion) argument
155 testAddTooLongWord(final int formatVersion) argument
232 testAddUnigramWord(final int formatVersion) argument
276 testRandomlyAddUnigramWord(final int formatVersion) argument
314 testAddBigramWords(final int formatVersion) argument
392 testRandomlyAddBigramWords(final int formatVersion) argument
457 testRemoveBigramWords(final int formatVersion) argument
509 testFlushDictionary(final int formatVersion) argument
563 testFlushWithGCDictionary(final int formatVersion) argument
614 testAddBigramWordsAndFlashWithGC(final int formatVersion) argument
687 testRandomOperationsAndFlashWithGC(final int formatVersion) argument
804 testAddManyUnigramsAndFlushWithGC(final int formatVersion) argument
854 testUnigramAndBigramCount(final int formatVersion) argument
915 testAddMultipleDictionaryEntries(final int formatVersion) argument
980 testGetWordProperties(final int formatVersion) argument
1083 testIterateAllWords(final int formatVersion) argument
1180 testAddShortcuts(final int formatVersion) argument
1246 testAddManyShortcuts(final int formatVersion) argument
1458 testBeginningOfSentence(final int formatVersion) argument
1494 testGetMaxFrequencyOfExactMatches(final int formatVersion) argument
[all...]
/packages/inputmethods/LatinIME/native/jni/src/suggest/policyimpl/dictionary/header/
H A Dheader_policy.h34 HeaderPolicy(const uint8_t *const dictBuf, const FormatUtils::FORMAT_VERSION formatVersion) argument
35 : mDictFormatVersion(formatVersion),
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/
H A DExpandableBinaryDictionary.java113 private boolean matchesExpectedBinaryDictFormatVersionForThisType(final int formatVersion) { argument
114 return formatVersion == FormatSpec.VERSION4;
117 private boolean needsToMigrateDictionary(final int formatVersion) { argument
120 return formatVersion == FormatSpec.VERSION4_ONLY_FOR_TESTING;
H A DBinaryDictionary.java135 * @param formatVersion the format version of the dictionary
139 final Locale locale, final String dictType, final long formatVersion,
157 mNativeDict = createOnMemoryNative(formatVersion, locale.toString(), keyArray, valueArray);
167 private static native long createOnMemoryNative(long formatVersion, argument
138 BinaryDictionary(final String filename, final boolean useFullEditDistance, final Locale locale, final String dictType, final long formatVersion, final Map<String, String> attributeMap) argument
/packages/inputmethods/LatinIME/native/jni/
H A Dcom_android_inputmethod_latin_BinaryDictionary.cpp71 jlong formatVersion, jstring locale, jobjectArray attributeKeyStringArray,
89 formatVersion, localeCodePoints, &attributeMap);
70 latinime_BinaryDictionary_createOnMemory(JNIEnv *env, jclass clazz, jlong formatVersion, jstring locale, jobjectArray attributeKeyStringArray, jobjectArray attributeValueStringArray) argument

Completed in 1582 milliseconds