Home
last modified time | relevance | path

Searched refs:traverseSession (Results 1 – 19 of 19) sorted by relevance

/packages/inputmethods/LatinIME/native/jni/src/suggest/core/
Dsuggest.cpp48 void Suggest::getSuggestions(ProximityInfo *pInfo, void *traverseSession, in getSuggestions() argument
55 DicTraverseSession *tSession = static_cast<DicTraverseSession *>(traverseSession); in getSuggestions()
81 void Suggest::initializeSearch(DicTraverseSession *traverseSession) const { in initializeSearch()
82 if (!traverseSession->getProximityInfoState(0)->isUsed()) { in initializeSearch()
86 if (traverseSession->getInputSize() > MIN_CONTINUOUS_SUGGESTION_INPUT_SIZE in initializeSearch()
87 && traverseSession->isContinuousSuggestionPossible()) { in initializeSearch()
89 traverseSession->getDicTraverseCache()->continueSearch(); in initializeSearch()
92 traverseSession->resetCache(TRAVERSAL->getMaxCacheSize(traverseSession->getInputSize(), in initializeSearch()
93 traverseSession->getSuggestOptions()->weightForLocale()), in initializeSearch()
97 DicNodeUtils::initAsRoot(traverseSession->getDictionaryStructurePolicy(), in initializeSearch()
[all …]
Dsuggest.h50 void getSuggestions(ProximityInfo *pInfo, void *traverseSession, int *inputXs, int *inputYs,
57 void createNextWordDicNode(DicTraverseSession *traverseSession, DicNode *dicNode,
59 void initializeSearch(DicTraverseSession *traverseSession) const;
60 void expandCurrentDicNodes(DicTraverseSession *traverseSession) const;
61 void processTerminalDicNode(DicTraverseSession *traverseSession, DicNode *dicNode) const;
62 void processExpandedDicNode(DicTraverseSession *traverseSession, DicNode *dicNode) const;
63 void weightChildNode(DicTraverseSession *traverseSession, DicNode *dicNode) const;
64 void processDicNodeAsOmission(DicTraverseSession *traverseSession, DicNode *dicNode) const;
65 void processDicNodeAsDigraph(DicTraverseSession *traverseSession, DicNode *dicNode) const;
66 void processDicNodeAsTransposition(DicTraverseSession *traverseSession,
[all …]
Dsuggest_interface.h29 virtual void getSuggestions(ProximityInfo *pInfo, void *traverseSession, int *inputXs,
/packages/inputmethods/LatinIME/native/jni/src/suggest/policyimpl/typing/
Dtyping_weighting.h40 float getTerminalSpatialCost(const DicTraverseSession *const traverseSession, in getTerminalSpatialCost() argument
75 float getMatchedCost(const DicTraverseSession *const traverseSession, in getMatchedCost() argument
78 const float normalizedSquaredLength = traverseSession->getProximityInfoState(0) in getMatchedCost()
82 traverseSession->isTouchPositionCorrectionEnabled(), normalizedSquaredLength); in getMatchedCost()
86 const bool isProximity = isProximityDicNode(traverseSession, dicNode); in getMatchedCost()
105 bool isProximityDicNode(const DicTraverseSession *const traverseSession, in isProximityDicNode() argument
109 traverseSession->getProximityInfoState(0)->getPrimaryCodePointAt(pointIndex)); in isProximityDicNode()
114 float getTranspositionCost(const DicTraverseSession *const traverseSession, in getTranspositionCost() argument
118 const float distance1 = traverseSession->getProximityInfoState(0)->getPointToKeyLength( in getTranspositionCost()
121 const float distance2 = traverseSession->getProximityInfoState(0)->getPointToKeyLength( in getTranspositionCost()
[all …]
Dtyping_traversal.h47 AK_FORCE_INLINE bool isOmission(const DicTraverseSession *const traverseSession, in isOmission() argument
59 const int inputSize = traverseSession->getInputSize(); in isOmission()
71 CharUtils::toBaseLowerCase(traverseSession->getProximityInfoState(0) in isOmission()
77 const DicTraverseSession *const traverseSession, const DicNode *const dicNode) const { in isSpaceSubstitutionTerminal() argument
81 if (traverseSession->getSuggestOptions()->weightForLocale() in isSpaceSubstitutionTerminal()
88 if (!canDoLookAheadCorrection(traverseSession, dicNode)) { in isSpaceSubstitutionTerminal()
93 && traverseSession->getProximityInfoState(0)-> in isSpaceSubstitutionTerminal()
98 const DicTraverseSession *const traverseSession, const DicNode *const dicNode) const { in isSpaceOmissionTerminal() argument
102 if (traverseSession->getSuggestOptions()->weightForLocale() in isSpaceOmissionTerminal()
109 const int inputSize = traverseSession->getInputSize(); in isSpaceOmissionTerminal()
[all …]
Dtyping_scoring.h35 AK_FORCE_INLINE void getMostProbableString(const DicTraverseSession *const traverseSession, in getMostProbableString() argument
40 DicTraverseSession *const traverseSession, DicNode *const terminals, in getAdjustedWeightOfLangModelVsSpatialModel() argument
105 AK_FORCE_INLINE bool sameAsTyped(const DicTraverseSession *const traverseSession, in sameAsTyped() argument
107 return traverseSession->getProximityInfoState(0)->sameAsTyped( in sameAsTyped()
Dtyping_weighting.cpp28 const DicTraverseSession *const traverseSession, const DicNode *const parentDicNode, in getErrorType() argument
32 if (isProximityDicNode(traverseSession, dicNode)) { in getErrorType()
39 traverseSession->getProximityInfoState(0); in getErrorType()
43 const int keyIndex = traverseSession->getProximityInfo()->getKeyIndexOf( in getErrorType()
/packages/inputmethods/LatinIME/native/jni/src/suggest/core/policy/
Dweighting.cpp76 const CorrectionType correctionType, const DicTraverseSession *const traverseSession, in addCostAndForwardInputIndex() argument
79 const int inputSize = traverseSession->getInputSize(); in addCostAndForwardInputIndex()
83 traverseSession, parentDicNode, dicNode, &inputStateG); in addCostAndForwardInputIndex()
85 traverseSession, parentDicNode, dicNode, multiBigramMap); in addCostAndForwardInputIndex()
87 traverseSession, parentDicNode, dicNode); in addCostAndForwardInputIndex()
105 const CorrectionType correctionType, const DicTraverseSession *const traverseSession, in getSpatialCost() argument
115 + weighting->getMatchedCost(traverseSession, dicNode, inputStateG); in getSpatialCost()
120 + weighting->getMatchedCost(traverseSession, dicNode, inputStateG); in getSpatialCost()
122 return weighting->getSpaceOmissionCost(traverseSession, dicNode, inputStateG); in getSpatialCost()
124 return weighting->getMatchedCost(traverseSession, dicNode, inputStateG); in getSpatialCost()
[all …]
Dweighting.h34 const DicTraverseSession *const traverseSession,
39 virtual float getTerminalSpatialCost(const DicTraverseSession *const traverseSession,
46 const DicTraverseSession *const traverseSession, const DicNode *const dicNode,
49 virtual bool isProximityDicNode(const DicTraverseSession *const traverseSession,
53 const DicTraverseSession *const traverseSession, const DicNode *const parentDicNode,
57 const DicTraverseSession *const traverseSession,
60 virtual float getSpaceOmissionCost(const DicTraverseSession *const traverseSession,
64 const DicTraverseSession *const traverseSession, const DicNode *const dicNode,
68 const DicTraverseSession *const traverseSession,
72 const DicTraverseSession *const traverseSession,
[all …]
Dtraversal.h30 virtual bool isOmission(const DicTraverseSession *const traverseSession,
33 virtual bool isSpaceSubstitutionTerminal(const DicTraverseSession *const traverseSession,
35 virtual bool isSpaceOmissionTerminal(const DicTraverseSession *const traverseSession,
37 virtual bool shouldDepthLevelCache(const DicTraverseSession *const traverseSession) const = 0;
38 virtual bool shouldNodeLevelCache(const DicTraverseSession *const traverseSession,
40 virtual bool canDoLookAheadCorrection(const DicTraverseSession *const traverseSession,
42 virtual ProximityType getProximityType(const DicTraverseSession *const traverseSession,
49 virtual bool isPossibleOmissionChildNode(const DicTraverseSession *const traverseSession,
Dscoring.h34 virtual void getMostProbableString(const DicTraverseSession *const traverseSession,
38 DicTraverseSession *const traverseSession, DicNode *const terminals,
43 virtual bool sameAsTyped(const DicTraverseSession *const traverseSession,
/packages/inputmethods/LatinIME/native/jni/src/suggest/core/result/
Dsuggestions_output_utils.cpp36 const Scoring *const scoringPolicy, DicTraverseSession *traverseSession, in outputSuggestions() argument
42 const int terminalSize = traverseSession->getDicTraverseCache()->terminalSize(); in outputSuggestions()
46 traverseSession->getDicTraverseCache()->popTerminal(&terminals[index]); in outputSuggestions()
52 ? scoringPolicy->getAdjustedWeightOfLangModelVsSpatialModel(traverseSession, in outputSuggestions()
61 && (traverseSession->getInputSize() >= MIN_LEN_FOR_MULTI_WORD_AUTOCORRECT in outputSuggestions()
65 traverseSession->isOnlyOnePointerUsed(0 /* pointerId */); in outputSuggestions()
66 const bool boostExactMatches = traverseSession->getDictionaryStructurePolicy()-> in outputSuggestions()
71 outputSuggestionsOfDicNode(scoringPolicy, traverseSession, &terminalDicNode, in outputSuggestions()
75 scoringPolicy->getMostProbableString(traverseSession, in outputSuggestions()
126 const Scoring *const scoringPolicy, DicTraverseSession *traverseSession, in outputSuggestionsOfDicNode() argument
[all …]
Dsuggestions_output_utils.h45 DicTraverseSession *traverseSession, const float weightOfLangModelVsSpatialModel,
55 DicTraverseSession *traverseSession, const DicNode *const terminalDicNode,
/packages/inputmethods/LatinIME/native/jni/
Dcom_android_inputmethod_latin_DicTraverseSession.cpp31 void *traverseSession = DicTraverseSession::getSessionInstance(env, localeJStr, dictSize); in latinime_setDicTraverseSession() local
32 return reinterpret_cast<jlong>(traverseSession); in latinime_setDicTraverseSession()
35 static void latinime_initDicTraverseSession(JNIEnv *env, jclass clazz, jlong traverseSession, in latinime_initDicTraverseSession() argument
37 DicTraverseSession *ts = reinterpret_cast<DicTraverseSession *>(traverseSession); in latinime_initDicTraverseSession()
53 static void latinime_releaseDicTraverseSession(JNIEnv *env, jclass clazz, jlong traverseSession) { in latinime_releaseDicTraverseSession() argument
54 DicTraverseSession *ts = reinterpret_cast<DicTraverseSession *>(traverseSession); in latinime_releaseDicTraverseSession()
Dcom_android_inputmethod_latin_BinaryDictionary.cpp194 DicTraverseSession *traverseSession = in latinime_BinaryDictionary_getSuggestions() local
196 if (!traverseSession) { in latinime_BinaryDictionary_getSuggestions()
249 dictionary->getSuggestions(pInfo, traverseSession, xCoordinates, yCoordinates, in latinime_BinaryDictionary_getSuggestions()
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/
DBinaryDictionary.java105 DicTraverseSession traverseSession = mDicTraverseSessions.get(traverseSessionId); in getTraverseSession() local
106 if (traverseSession == null) { in getTraverseSession()
107 traverseSession = new DicTraverseSession(mLocale, mNativeDict, mDictSize); in getTraverseSession()
108 mDicTraverseSessions.put(traverseSessionId, traverseSession); in getTraverseSession()
110 return traverseSession; in getTraverseSession()
194 long traverseSession, int[] xCoordinates, int[] yCoordinates, int[] times, in getSuggestionsNative() argument
643 final DicTraverseSession traverseSession = mDicTraverseSessions.valueAt(index); in close() local
644 if (traverseSession != null) { in close()
645 traverseSession.close(); in close()
/packages/inputmethods/LatinIME/native/jni/src/suggest/core/dictionary/
Ddictionary.cpp47 void Dictionary::getSuggestions(ProximityInfo *proximityInfo, DicTraverseSession *traverseSession, in getSuggestions() argument
53 traverseSession->init(this, ngramContext, suggestOptions); in getSuggestions()
55 suggest->getSuggestions(proximityInfo, traverseSession, xcoordinates, in getSuggestions()
Ddictionary.h68 void getSuggestions(ProximityInfo *proximityInfo, DicTraverseSession *traverseSession,
/packages/inputmethods/LatinIME/native/jni/src/suggest/core/session/
Ddic_traverse_session.h49 static AK_FORCE_INLINE void releaseSessionInstance(DicTraverseSession *traverseSession) { in releaseSessionInstance() argument
50 delete traverseSession; in releaseSessionInstance() local