Uses of Class
com.yahoo.prelude.query.Item
-
Packages that use Item Package Description com.yahoo.prelude.query The query model representing a boolean combination of selection criterions, where elements may be simple criterions, nested boolean operators, or annotated pieces of natural language text.com.yahoo.prelude.query.parser com.yahoo.prelude.query.textualrepresentation com.yahoo.prelude.querytransform com.yahoo.prelude.semantics.engine com.yahoo.prelude.semantics.rule com.yahoo.search.query The search query modelcom.yahoo.search.query.textserialize com.yahoo.search.query.textserialize.item com.yahoo.search.query.textserialize.serializer com.yahoo.search.querytransform Vespa search platform query transformation infrastructure. -
-
Uses of Item in com.yahoo.prelude.query
Subclasses of Item in com.yahoo.prelude.query Modifier and Type Class Description class
AndItem
An and'ing of a collection of sub-expressionsclass
AndSegmentItem
An immutable and'ing of a collection of sub-expressions.class
BoolItem
A true/false term suitable for searching bool indexes.class
CompositeIndexedItem
Common implementation for Item classes implementing the IndexedItem interface.class
CompositeItem
Superclass of expressions which contains a collection of sub-expressionsclass
CompositeTaggableItem
Common implementation for Item classes implementing the TaggableItem interface.class
DotProductItem
A weighted set query item to be evaluated as a sparse dot product.class
EquivItem
An Item where each child is an alternative which can be matched.class
ExactStringItem
Used to signal that this term requires exact match if the backend supports it.class
FalseItem
A query item which never matches.class
GeoLocationItem
This represents a geo-location in the query tree.class
IndexedSegmentItem
Common implementation for Item classes implementing the IndexedItem interface.class
IntItem
This represents either a number (integer or floating point) a partial range, given by "<number" or ">number", where the numbers are exclusive, or a full or open range "[number;number], "[number;]" or "[;number]" where the numbers are inclusive, or exclusive if a square bracket is replaced with a pointy one If a range is specified in brackets, it is also permissible to add a third number specifying the number of hits this will match on each node - [from;to;hitLimit]class
MarkerWordItem
Special words known by the index used for marking things.class
NearestNeighborItem
Represent a query item matching the K nearest neighbors in a multi-dimensional vector space.class
NearItem
A set of terms which must be near each other to match.class
NonReducibleCompositeItem
A composite item which specifies semantics which are not maintained if an instance with a single child is replaced by the single child.class
NotItem
A composite item where the first item is positive and the following items are negative items where matches should exclude the document should from the result.class
NullItem
A placeholder for null queries to make searchers easier to write.class
ONearItem
Ordered NearItem.class
OrItem
An or'ing of a collection of sub-expressionsclass
PhraseItem
A term which contains a phrase - a collection of word termsclass
PhraseSegmentItem
A term which contains a fixed length phrase, a collection of word terms, resulting from a single segmentation operation.class
PredicateQueryItem
A PredicateQueryItem is a collection of feature/value-pairs that are used to query predicate fields, which contains boolean constraints.class
PrefixItem
A word which matches beginnings of words instead of complete wordsclass
PureWeightedInteger
An integer item which only consists of a value and weight.class
PureWeightedItem
A word item which only consists of a value and weight, and gets other properties such as the index to query from ther parent item.class
PureWeightedString
A word item which only consists of a value and weight.class
RangeItem
This class represents a numeric range.class
RankItem
Represents the rank operator, which only orders the result set and does not change which hits are returned.class
RegExpItem
Match a field with the contained regular expression.class
SameElementItem
This represents a query where all terms are required to match in the same element id.class
SegmentItem
An immutable and'ing of a collection of sub-expressions.class
SimpleIndexedItem
Common implementation for Item classes implementing the IndexedItem interface.class
SimpleTaggableItem
Common implementation for Item classes implementing the TaggableItem interface.class
SubstringItem
A word that matches substrings of wordsclass
SuffixItem
A word that matches a suffix of words instead of a complete word.class
TaggableSegmentItem
Common implementation for Item classes implementing the TaggableItem interface.class
TermItem
Superclass of "leaf" conditions containing a single entity which is either matched in a field or not.class
TrueItem
A query item which matches everything.class
UriItem
An item matching a uri field.class
WandItem
A weighted set query item to be evaluated as a Wand with dot product scoring.class
WeakAndItem
Weak And of a collection of sub-expressions: this behaves like an OR unless many hits are returned and then it starts acting more like an AND.class
WeightedSetItem
A term which contains a weighted set.class
WordAlternativesItem
A set of words with differing exactness scores to be used for literal boost ranking.class
WordItem
A simple word or token to match in some field.Fields in com.yahoo.prelude.query declared as Item Modifier and Type Field Description protected Item
Item. connectedBacklink
protected Item
Item. connectedItem
Items for explicit connectivityMethods in com.yahoo.prelude.query that return Item Modifier and Type Method Description Item
Item. clone()
Returns a deep copy of this itemItem
TermType. createItemClass()
Returns an instance of the class corresponding to the given type, AndItem if this is the DEFAULT typeItem
CompositeTaggableItem. getConnectedItem()
Item
SimpleTaggableItem. getConnectedItem()
Item
TaggableItem. getConnectedItem()
Item
TaggableSegmentItem. getConnectedItem()
Item
CompositeItem. getItem(int index)
Returns a subitemItem
NotItem. getPositiveItem()
Returns the positive item (the first subitem), or TrueItem if no positive items has been added.Item
CompositeItem. removeItem(int index)
Removes the item at the given indexItem
NotItem. removeItem(int index)
Item
SegmentItem. removeItem(int index)
Item
CompositeItem. setItem(int index, Item item)
Replaces the item at the given index.Item
PhraseItem. setItem(int index, Item item)
Item
NotItem. setPositiveItem(Item item)
Sets the positive item (the first item)Methods in com.yahoo.prelude.query that return types with arguments of type Item Modifier and Type Method Description Optional<Item>
CompositeItem. extractSingleChild()
Returns the single child of this, if this can be omitted without changes to recall semantics.Optional<Item>
NonReducibleCompositeItem. extractSingleChild()
Optional<Item>
PhraseItem. extractSingleChild()
Optional<Item>
PhraseSegmentItem. extractSingleChild()
Optional<Item>
SameElementItem. extractSingleChild()
ListIterator<Item>
CompositeItem. getItemIterator()
Returns a modifiable list iterator of the immediate children of thisList<Item>
CompositeItem. items()
Returns a read only list of the immediate children of thisList<Item>
NotItem. negativeItems()
Returns the negative items of this: All child items except the firstMethods in com.yahoo.prelude.query with parameters of type Item Modifier and Type Method Description protected void
CompositeItem. adding(Item item)
protected void
EquivItem. adding(Item item)
protected void
SameElementItem. adding(Item item)
void
CompositeItem. addItem(int index, Item item)
Inserts the item at a position and increases the index of existing items starting on this position by onevoid
CompositeItem. addItem(Item item)
void
NotItem. addItem(Item item)
Adds an item.void
PhraseItem. addItem(int index, Item item)
void
PhraseItem. addItem(Item item)
Adds subitem.void
PhraseSegmentItem. addItem(Item item)
Adds subitem.void
SegmentItem. addItem(int index, Item item)
void
SegmentItem. addItem(Item item)
void
NotItem. addNegativeItem(Item negative)
Adds a negative item.void
NotItem. addPositiveItem(Item item)
Convenience method for adding a positive item.int
CompositeItem. getItemIndex(Item item)
Returns the index of a subitemvoid
ItemHelper. getPositiveTerms(Item item, List<IndexedItem> terms)
boolean
CompositeItem. removeItem(Item item)
Removes the given item.boolean
NotItem. removeItem(Item item)
boolean
SegmentItem. removeItem(Item item)
void
CompositeTaggableItem. setConnectivity(Item item, double connectivity)
void
SimpleTaggableItem. setConnectivity(Item item, double connectivity)
void
TaggableItem. setConnectivity(Item item, double connectivity)
Set the connectivity to another term in the same query tree.void
TaggableSegmentItem. setConnectivity(Item item, double connectivity)
Item
CompositeItem. setItem(int index, Item item)
Replaces the item at the given index.Item
PhraseItem. setItem(int index, Item item)
Item
NotItem. setPositiveItem(Item item)
Sets the positive item (the first item)abstract boolean
ToolBox.QueryVisitor. visit(Item item)
Called for each item in the query tree given toToolBox.visit(QueryVisitor, Item)
.static void
ToolBox. visit(ToolBox.QueryVisitor visitor, Item item)
Constructors in com.yahoo.prelude.query with parameters of type Item Constructor Description EquivItem(Item item)
Creates an EQUIV with the given item as child.EquivItem(Item item, Collection<String> words)
Creates an EQUIV with the given item and a set of alternate words as children. -
Uses of Item in com.yahoo.prelude.query.parser
Methods in com.yahoo.prelude.query.parser that return Item Modifier and Type Method Description protected Item
AllParser. combineItems(Item topLevelItem, Item item)
Returns the top level item resulting from combining the given top level item and the new item.protected Item
AnyParser. combineItems(Item topLevelItem, Item item)
Returns the top level item resulting from combining the given top level item and the new item.protected Item
AdvancedParser. handleComposite(boolean topLevel)
Deprecated.protected Item
AllParser. negativeItem()
protected Item
AnyParser. negativeItem()
Item
AbstractParser. parse(String queryToParse, String filterToParse, com.yahoo.language.Language parsingLanguage, IndexFacts.Session indexFacts, String defaultIndexName)
Item
CustomParser. parse(String queryToParse, String filterToParse, com.yahoo.language.Language parsingLanguage, IndexFacts.Session indexFacts, String defaultIndexName)
default Item
CustomParser. parse(String queryToParse, String filterToParse, com.yahoo.language.Language parsingLanguage, Set<String> toSearch, IndexFacts indexFacts, String defaultIndexName)
Returns the raw result from parsing, not wrapped in a QueryTree instance.Item
ProgrammaticParser. parse(String queryToParse, String filterToParse, com.yahoo.language.Language parsingLanguage, IndexFacts.Session indexFacts, String defaultIndexName)
protected abstract Item
AbstractParser. parseItems()
protected Item
AdvancedParser. parseItems()
Deprecated.protected Item
AllParser. parseItems()
protected Item
AnyParser. parseItems()
protected Item
PhraseParser. parseItems()
protected Item
AllParser. parseItemsBody()
protected Item
WebParser. parseItemsBody()
protected Item
AbstractParser. segment(String indexName, Token token, boolean quoted)
Segments a tokenstatic Item
AbstractParser. simplifyPhrases(Item unwashed)
Collapses single item phrases in the tree to the contained item.protected Item
AllParser. simplifyUnnecessaryComposites(Item item)
Methods in com.yahoo.prelude.query.parser with parameters of type Item Modifier and Type Method Description protected CompositeItem
AllParser. addAnd(Item item, CompositeItem and)
protected NotItem
AllParser. addNot(Item item, NotItem not)
protected OrItem
AllParser. addOr(Item item, OrItem or)
protected Item
AllParser. combineItems(Item topLevelItem, Item item)
Returns the top level item resulting from combining the given top level item and the new item.protected Item
AnyParser. combineItems(Item topLevelItem, Item item)
Returns the top level item resulting from combining the given top level item and the new item.static Item
AbstractParser. simplifyPhrases(Item unwashed)
Collapses single item phrases in the tree to the contained item.protected Item
AllParser. simplifyUnnecessaryComposites(Item item)
-
Uses of Item in com.yahoo.prelude.query.textualrepresentation
Methods in com.yahoo.prelude.query.textualrepresentation with parameters of type Item Modifier and Type Method Description void
Discloser. addChild(Item item)
Constructors in com.yahoo.prelude.query.textualrepresentation with parameters of type Item Constructor Description TextualQueryRepresentation(Item root)
-
Uses of Item in com.yahoo.prelude.querytransform
Methods in com.yahoo.prelude.querytransform that return Item Modifier and Type Method Description Item
PhraseMatcher.Phrase.MatchIterator. next()
Methods in com.yahoo.prelude.querytransform with parameters of type Item Modifier and Type Method Description List<PhraseMatcher.Phrase>
PhraseMatcher. matchPhrases(Item queryItem)
Finds all phrases (word sequences of length 1 or higher) of the same index, not negative items of a notitem, which constitutes a complete entry in the automaton of this matcher -
Uses of Item in com.yahoo.prelude.semantics.engine
Methods in com.yahoo.prelude.semantics.engine that return Item Modifier and Type Method Description Item
Match. toItem(String label)
Returns a new item representing this matchItem
Match. toItem(String label, String term)
Returns a new item representing this matchItem
ReferencedMatches. toItem(String label)
Returns the item to insert from these referenced matches, or null if noneMethods in com.yahoo.prelude.semantics.engine with parameters of type Item Modifier and Type Method Description void
Evaluation. addItem(Item item, TermType termType)
Adds an item to the query being evaluated in a way consistent with the query typevoid
Evaluation. removeItem(int position, Item item)
Removes an item, prefers the one at/close to the given position if there are multiple onesvoid
Evaluation. removeItem(Item item)
Removes this itemvoid
RuleEvaluation. removeItem(int position, Item item)
Removes an item, prefers the one at/close to the given position if there are multiple onesvoid
RuleEvaluation. removeItem(Item item)
void
Evaluation. removeItemByIdentity(Item item)
Removes this item by identity to ensure we remove the right one if there are multiple equal itemsvoid
RuleEvaluation. removeItemByIdentity(Item item)
Method parameters in com.yahoo.prelude.semantics.engine with type arguments of type Item Modifier and Type Method Description void
RuleEvaluation. addItems(List<Item> items, TermType termType)
Adds an item to the query being evaluated in a way consistent with the query typevoid
Evaluation. insertItems(List<Item> items, CompositeItem parent, int index, TermType desiredParentType)
Inserts an item to the query being evaluated in a way consistent with the query typevoid
RuleEvaluation. insertItems(List<Item> items, CompositeItem parent, int index, TermType termType)
Inserts an item to the query being evaluated in a way consistent with the query type -
Uses of Item in com.yahoo.prelude.semantics.rule
Method parameters in com.yahoo.prelude.semantics.rule with type arguments of type Item Modifier and Type Method Description protected void
TermProduction. insertMatch(RuleEvaluation e, Match matched, List<Item> newItems, int offset)
Inserts newItem at the position of this match TODO: Move to ruleevaluation -
Uses of Item in com.yahoo.search.query
Subclasses of Item in com.yahoo.search.query Modifier and Type Class Description class
QueryTree
The root node of a query tree.Methods in com.yahoo.search.query that return Item Modifier and Type Method Description Item
QueryTree. and(Item item)
Modifies this query to become the current query AND the given item.Item
QueryTree. getRoot()
Returns the query root.Methods in com.yahoo.search.query with parameters of type Item Modifier and Type Method Description void
QueryTree. addItem(int index, Item item)
void
QueryTree. addItem(Item item)
Item
QueryTree. and(Item item)
Modifies this query to become the current query AND the given item.static List<IndexedItem>
QueryTree. getPositiveTerms(Item item)
Returns a flattened list of all positive query terms under the given itemvoid
QueryTree. setRoot(Item root)
Constructors in com.yahoo.search.query with parameters of type Item Constructor Description QueryTree(Item root)
-
Uses of Item in com.yahoo.search.query.textserialize
Methods in com.yahoo.search.query.textserialize that return Item Modifier and Type Method Description static Item
TextSerialize. parse(String serializedQuery)
Methods in com.yahoo.search.query.textserialize with parameters of type Item Modifier and Type Method Description static String
TextSerialize. serialize(Item item)
-
Uses of Item in com.yahoo.search.query.textserialize.item
Methods in com.yahoo.search.query.textserialize.item with parameters of type Item Modifier and Type Method Description protected String
AndNotRestConverter. getFormName(Item item)
protected String
CompositeConverter. getFormName(Item item)
static void
ItemInitializer. initialize(Item item, ItemArguments arguments, ItemContext itemContext)
static void
ItemInitializer. initializeForm(DispatchForm form, Item item, ItemIdMapper itemIdMapper)
DispatchForm
CompositeConverter. itemToForm(Item item, ItemIdMapper itemIdMapper)
DispatchForm
ItemFormConverter. itemToForm(Item item, ItemIdMapper itemIdMapper)
DispatchForm
NearConverter. itemToForm(Item item, ItemIdMapper itemIdMapper)
DispatchForm
TermConverter. itemToForm(Item item, ItemIdMapper itemIdMapper)
void
ItemContext. setItemId(String id, Item item)
-
Uses of Item in com.yahoo.search.query.textserialize.serializer
Methods in com.yahoo.search.query.textserialize.serializer with parameters of type Item Modifier and Type Method Description String
ItemIdMapper. getId(Item item)
String
QueryTreeSerializer. serialize(Item root)
-
Uses of Item in com.yahoo.search.querytransform
Methods in com.yahoo.search.querytransform that return Item Modifier and Type Method Description static Item
QueryTreeUtil. andQueryItemWithRoot(QueryTree tree, Item item)
Deprecated.Adds the given item to this querystatic Item
QueryTreeUtil. andQueryItemWithRoot(Query query, Item item)
Deprecated.Adds the given item to this queryprotected Item
NGramSearcher. splitToGrams(Item term, String text, int gramSize, Query query)
Splits the given item into n-grams and adds them as a CompositeItem containing WordItems searching the index of the input term.Methods in com.yahoo.search.querytransform with parameters of type Item Modifier and Type Method Description static Item
QueryTreeUtil. andQueryItemWithRoot(QueryTree tree, Item item)
Deprecated.Adds the given item to this querystatic Item
QueryTreeUtil. andQueryItemWithRoot(Query query, Item item)
Deprecated.Adds the given item to this queryprotected Item
NGramSearcher. splitToGrams(Item term, String text, int gramSize, Query query)
Splits the given item into n-grams and adds them as a CompositeItem containing WordItems searching the index of the input term.
-