public class FulltextEvaluator extends MEXTransformerEvaluator
This evaluator acts as a bridge between the MEX query and the internal Full-Text Search (FTS) engine. It converts high-level search syntax into a list of primary keys that satisfy the search criteria.
Syntax: {Fulltext [from <ClassName>] matches <SearchTerms>}
Transformation Example:
Input: {Fulltext from Product matches 'blue suede'}
Output: obj.Id IN LIST ('101', '205', '309')
| Constructor and Description |
|---|
FulltextEvaluator(MEXPersistenceQueryResults _mexQR)
Initializes the evaluator with the query results context.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
canHandle(java.lang.CharSequence s)
Quickly determines if the expression is a Fulltext instruction.
|
java.lang.CharSequence |
evaluate(java.lang.CharSequence s,
MEXTransformer transformer)
Evaluates the Fulltext expression by invoking the FTS engine and generating an SQL IN-clause.
|
java.lang.String[] |
getGroups(java.lang.CharSequence s)
Deconstructs the Fulltext expression into its component parts.
|
public FulltextEvaluator(MEXPersistenceQueryResults _mexQR)
_mexQR - The execution context containing the FTS engine reference.public boolean canHandle(java.lang.CharSequence s)
canHandle in class MEXTransformerEvaluators - The segment of text being evaluated.true if the text starts with the "Fulltext" keyword.public java.lang.String[] getGroups(java.lang.CharSequence s)
throws MEXParseException
s - The full expression string.MEXParseException - if the syntax does not match PATTERN_FULLTEXT_FULL.public java.lang.CharSequence evaluate(java.lang.CharSequence s,
MEXTransformer transformer)
The process follows these steps:
obj.id IN LIST ('id1', 'id2', ...).evaluate in interface MEXTransformerEvaluatorIevaluate in class MEXTransformerEvaluators - The instruction sequence.transformer - The transformer instance used for source context inference.MEXUnavailableException - if the FTS engine is offline or unavailable.Copyright © 2000-2026 OAshi S.à r.l. All Rights Reserved.