
com.yahoo.document.annotation.DummySpanNode Maven / Gradle / Ivy
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.document.annotation;
import java.util.Collections;
import java.util.ListIterator;
/**
* @author Einar M R Rosenvinge
*/
class DummySpanNode extends SpanNode {
final static DummySpanNode INSTANCE = new DummySpanNode();
private DummySpanNode() {
}
@Override
public boolean isLeafNode() {
return true;
}
@Override
public ListIterator childIterator() {
return Collections.emptyList().listIterator();
}
@Override
public ListIterator childIteratorRecursive() {
return Collections.emptyList().listIterator();
}
@Override
public int getFrom() {
return 0;
}
@Override
public int getTo() {
return 0;
}
@Override
public int getLength() {
return 0;
}
@Override
public CharSequence getText(CharSequence text) {
return null;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy