Package org.apache.tika.inference
Class ChunkTarget
java.lang.Object
org.apache.tika.inference.ChunkTarget
Where the chunks produced for a unit land and how they name where they came from. The
dispatcher decides the destination (
InferenceUnit.getDestination()); when that is
not the unit's own document, an EmbeddedLocator names the child the chunks came
from. The in-parse form is for a parser that writes during its own document's parse.-
Method Summary
Modifier and TypeMethodDescriptionNames the child the chunks came from; null when they stay on that child.static ChunkTargetof(InferenceUnit unit) The unit's destination, with a locator naming the unit's document when lifted off it.static ChunkTargetresolve(Metadata target, ParseContext context) During a parse: the parent for an inline part or a page render the wrapper numbered, the document itself otherwise.static ChunkTargetThe target keeps its own chunks.voidTags the chunks with the locator, if any, and appends them to the field.
-
Method Details
-
of
The unit's destination, with a locator naming the unit's document when lifted off it. -
resolve
During a parse: the parent for an inline part or a page render the wrapper numbered, the document itself otherwise. -
self
The target keeps its own chunks. -
getMetadata
-
getLocator
Names the child the chunks came from; null when they stay on that child. -
write
Tags the chunks with the locator, if any, and appends them to the field.- Throws:
IOException
-