public class WholeXmiStaxSplitter extends Object implements XmiSplitter
| Constructor and Description |
|---|
WholeXmiStaxSplitter(String tableName)
Creates an StaxXmiSplitter that returns the whole xmi data.
|
WholeXmiStaxSplitter(String tableName,
int attribute_size)
Creates an StaxXmiSplitter that returns the whole xmi data.
|
| Modifier and Type | Method and Description |
|---|---|
int |
determineMaxXmiId(byte[] ba)
Determines the maximum XMI ID assigned in the XMI data given by
bais plus one.
|
List<String> |
getAnnotationsToStore()
Returns the specified annotations to select.
|
String |
getFirstAnnotationtype()
Return the first annotation type that is not an element of the base
document.
|
XmiSplitterResult |
process(byte[] ba,
org.apache.uima.jcas.JCas aCas,
int nextPossibleId,
Map<String,Integer> existingSofaIdMap)
Processes the xmi data according to the parameters set for the
StaxXmiSplitter.
|
void |
setAllJavaNames(ByteArrayInputStream bais)
Retrieves the types namespace uri from the xmi element in order to create
the fully qualified java name for all annotations that have not been
given in this form.
|
public WholeXmiStaxSplitter(String tableName, int attribute_size)
tableName - The table to store the xmi data.attribute_size - The maximum attribute size accepted by the employed StAX parser.public WholeXmiStaxSplitter(String tableName)
tableName - The table to store the xmi data.public XmiSplitterResult process(byte[] ba, org.apache.uima.jcas.JCas aCas, int nextPossibleId, Map<String,Integer> existingSofaIdMap) throws XMISplitterException
process in interface XmiSplitterba - The current xmi data.aCas - The current cas.nextPossibleId - The next xmi id that can be assigned to the new annotations.
If the base document has not yet been stored this should be 0.HashMapString, ByteArrayOutputStream
- the next possible xmi id - an Integer - to store
in the database and a namespace map derived from XMI opening
element where each namespace prefix is mapped to the namespace
URI (only unless the complete XMI document should be stored).IOExceptionXMISplitterExceptionpublic int determineMaxXmiId(byte[] ba)
ba - The current xmi data as input stream.public void setAllJavaNames(ByteArrayInputStream bais)
bais - The current xmi data as input stream.public List<String> getAnnotationsToStore()
public String getFirstAnnotationtype()
Copyright © 2019 JULIE Lab Jena, Germany. All rights reserved.