Uses of Class
com.yahoo.document.annotation.SpanNode
Packages that use SpanNode
Package
Description
Provides classes and interfaces for creating trees of spans over string
values in Vespa documents, and annotating these spans.
-
Uses of SpanNode in com.yahoo.document.annotation
Subclasses of SpanNode in com.yahoo.document.annotationModifier and TypeClassDescriptionclassA node in aSpanNodetree that can have a multiple trees of child nodes, each with its own probability.classThis class represents a range of characters from a string. This is the leaf node in a Span tree.classA node in a Span tree that can have child nodes.Fields in com.yahoo.document.annotation with type parameters of type SpanNodeModifier and TypeFieldDescriptionprotected ListIterator<SpanNode>RecursiveNodeIterator.iteratorFromLastCallToNextRecursiveNodeIterator.stackMethods in com.yahoo.document.annotation that return SpanNodeModifier and TypeMethodDescriptionSpanNode.annotate(Annotation annotation) Convenience method for adding an annotation to this span, same asgetSpanTree().spanTree.annotate(this,annotation)SpanNode.annotate(AnnotationType type) Convenience method for adding an annotation with no value to this span, same asgetSpanTree().spanTree.annotate(this,type)SpanNode.annotate(AnnotationType type, FieldValue value) Convenience method for adding an annotation to this span, same asgetSpanTree().spanTree.annotate(this,type,value)SpanNode.annotate(AnnotationType type, Integer value) Convenience method for adding an annotation to this span, same asgetSpanTree().spanTree.annotate(this,type,new IntegerFieldValue(value))SpanNode.annotate(AnnotationType type, String value) Convenience method for adding an annotation to this span, same asgetSpanTree().spanTree.annotate(this,type,new StringFieldValue(value))SpanTree.getRoot()Returns the root node of this span tree.Annotation.getSpanNode()Returns theSpanNodethis Annotation is annotating, if any.final SpanNodeAnnotation.getSpanNodeFast()Returns theSpanNodethis Annotation is annotating, if any.Methods in com.yahoo.document.annotation that return types with arguments of type SpanNodeModifier and TypeMethodDescriptionAlternateSpanList.childIterator()Traverses all immediate children of all subtrees of this AlternateSpanList.AlternateSpanList.childIterator(int i) Traverses all immediate children of the given subtree of this AlternateSpanList.Span.childIterator()Returns a ListIterator that iterates over absolutely nothing.SpanList.childIterator()Traverses all immediate children of this SpanList.abstract ListIterator<SpanNode>SpanNode.childIterator()Traverses all immediate children of this SpanNode.AlternateSpanList.childIteratorRecursive()Recursively traverses all children (not only leaf nodes) of all subtrees of this AlternateSpanList, in a depth-first fashion.AlternateSpanList.childIteratorRecursive(int i) Recursively traverses all children (not only leaf nodes) of the given subtree of this AlternateSpanList, in a depth-first fashion.Span.childIteratorRecursive()Returns a ListIterator that iterates over absolutely nothing.SpanList.childIteratorRecursive()Recursively traverses all children (not only leaf nodes) of this SpanList, in a depth-first fashion.abstract ListIterator<SpanNode>SpanNode.childIteratorRecursive()Recursively traverses all possible children (not only leaf nodes) of this SpanNode, in a depth-first fashion.AlternateSpanList.children()Returns a modifiableListof child nodes of first subtree.AlternateSpanList.children(int i) Returns a modifiableListof child nodes of the specified subtree.SpanList.children()Returns a modifiable list of the immediate children of this SpanList.AlternateSpanList.removeChildren(int i) Removes the subtree at index i (both the subtree itself and its contents, which become invalidated).AlternateSpanList.setChildren(int i, List<SpanNode> subtree, double probability) Sets the subtree at index i.Methods in com.yahoo.document.annotation with parameters of type SpanNodeModifier and TypeMethodDescriptionConvenience method to add a span node to the child tree at index i.Adds a child node to the first subtree of this AlternateSpanList.Adds a child node to this SpanList.SpanTree.annotate(SpanNode node, Annotation annotation) Adds an Annotation to the internal list of annotations for this SpanTree.SpanTree.annotate(SpanNode node, AnnotationType type) Creates an Annotation based on the given AnnotationType, and adds it to the internal list of annotations for this SpanTree (convenience method). Use this when adding an Annotation (that does not have a FieldValue) that shall annotate a SpanNode.SpanTree.annotate(SpanNode node, AnnotationType type, FieldValue value) Adds an Annotation.final SpanTreeSpanTree.annotateFast(SpanNode node, Annotation annotation) Adds an Annotation to the internal list of annotations for this SpanTree.voidSpanTree.clearAnnotations(SpanNode node) Clears all Annotations for a given SpanNode.voidSpanTree.clearAnnotationsRecursive(SpanNode node) Clears all Annotations for a given SpanNode and its child nodes.intCompares two SpanNodes. Note: this class has a natural ordering that might be inconsistent with equals.booleanChecks if the text covered by another span is within the text covered by this span.Returns an Iterator over all annotations that annotate the given node.SpanTree.iteratorRecursive(SpanNode node) Returns a recursive Iterator over all annotations that annotate the given node and its subnodes.voidAlternateSpanList.move(int i, SpanNode node, AlternateSpanList target, int targetSubTree) Moves a child of this SpanList to another SpanList.voidMoves a child of this SpanList to another SpanList.voidSpanList.move(SpanNode node, AlternateSpanList target, int targetSubTree) Moves a child of this SpanList to another SpanList.voidMoves a child of this SpanList to another SpanList.booleanChecks if the text covered by this span overlaps with the text covered by another span.Removes and invalidates the given SpanNode from this.voidWARNING!voidAnnotation.setSpanNode(SpanNode spanNode) WARNING!final voidAnnotation.setSpanNodeFast(SpanNode spanNode) WARNING!Method parameters in com.yahoo.document.annotation with type arguments of type SpanNodeModifier and TypeMethodDescriptionvoidAlternateSpanList.addChildren(int i, List<SpanNode> subtree, double probability) Adds a possible subtree of this AlternateSpanList, with the given probability, at index i.booleanAlternateSpanList.addChildren(List<SpanNode> subtree, double probability) Adds a possible subtree of this AlternateSpanList, with the given probability.AlternateSpanList.setChildren(int i, List<SpanNode> subtree, double probability) Sets the subtree at index i.Constructors in com.yahoo.document.annotation with parameters of type SpanNodeModifierConstructorDescriptionCreates a new SpanTree with a given root node.Constructor parameters in com.yahoo.document.annotation with type arguments of type SpanNode -
Uses of SpanNode in com.yahoo.document.serialization
Methods in com.yahoo.document.serialization with parameters of type SpanNode