public class JsonSplitter extends java.lang.Object implements DocumentSplitter
构造器和说明 |
---|
JsonSplitter() |
限定符和类型 | 方法和说明 |
---|---|
protected java.lang.String |
buildContent(java.util.Map<java.lang.String,java.lang.Object> jsonData)
构建内容
|
protected java.util.Map<java.lang.String,java.lang.Object> |
buildMetadata(java.util.Map<java.lang.String,java.lang.Object> jsonData)
构建元数据
|
JsonSplitter |
contentSelector(java.lang.String... keys)
内容选择器
|
JsonSplitter |
metadataMapper(java.util.function.Function<java.util.Map<java.lang.String,java.lang.Object>,java.util.Map<java.lang.String,java.lang.Object>> mapper)
元数据映射器(将内容数据转为元数据)
|
java.util.List<Document> |
split(java.util.List<Document> documents)
分割
|
protected java.util.List<Document> |
splitDocument(Document in,
java.util.List<Document> outs)
分割文档
|
protected java.util.List<Document> |
splitJson(java.lang.String josn)
分割 json text
|
protected void |
splitJsonNode(org.noear.snack.ONode oNode,
java.util.List<Document> docs)
分割 json node
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
split
public JsonSplitter contentSelector(java.lang.String... keys)
public JsonSplitter metadataMapper(java.util.function.Function<java.util.Map<java.lang.String,java.lang.Object>,java.util.Map<java.lang.String,java.lang.Object>> mapper)
public java.util.List<Document> split(java.util.List<Document> documents)
DocumentSplitter
split
在接口中 DocumentSplitter
documents
- 文档protected java.util.List<Document> splitDocument(Document in, java.util.List<Document> outs)
protected java.util.List<Document> splitJson(java.lang.String josn)
protected void splitJsonNode(org.noear.snack.ONode oNode, java.util.List<Document> docs)
protected java.lang.String buildContent(java.util.Map<java.lang.String,java.lang.Object> jsonData)
protected java.util.Map<java.lang.String,java.lang.Object> buildMetadata(java.util.Map<java.lang.String,java.lang.Object> jsonData)