Class JsonDataExtractor
java.lang.Object
io.jmix.dataimport.extractor.data.impl.JsonDataExtractor
- All Implemented Interfaces:
ImportedDataExtractor
@Component("datimp_JsonDataExtractor")
public class JsonDataExtractor
extends Object
implements ImportedDataExtractor
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected ImportedDataItem
createImportedDataItem
(com.fasterxml.jackson.databind.JsonNode jsonNode, int itemIndex) protected ImportedObject
createImportedObject
(com.fasterxml.jackson.databind.JsonNode objectNode) protected ImportedObjectList
createImportedObjectList
(com.fasterxml.jackson.databind.JsonNode rootNode) extract
(ImportConfiguration importConfiguration, byte[] inputData) Parses input data specified as a byte array and creates an instance ofImportedData
.extract
(ImportConfiguration importConfiguration, InputStream inputStream) Parses input data specified as input stream and creates an instance ofImportedData
.protected ImportedData
getImportedData
(com.fasterxml.jackson.databind.JsonNode rootNode) protected void
readRawValues
(com.fasterxml.jackson.databind.JsonNode objectNode, RawValuesSource rawValuesSource)
-
Constructor Details
-
JsonDataExtractor
public JsonDataExtractor()
-
-
Method Details
-
extract
Description copied from interface:ImportedDataExtractor
Parses input data specified as input stream and creates an instance ofImportedData
.- Specified by:
extract
in interfaceImportedDataExtractor
- Parameters:
importConfiguration
- import configurationinputStream
- input data- Returns:
- an instance of
ImportedData
containing list ofImportedDataItem
with raw values for entity properties
-
extract
Description copied from interface:ImportedDataExtractor
Parses input data specified as a byte array and creates an instance ofImportedData
.- Specified by:
extract
in interfaceImportedDataExtractor
- Parameters:
importConfiguration
- import configurationinputData
- input data- Returns:
- an instance of
ImportedData
containing list ofImportedDataItem
with raw values for entity properties
-
getSupportedDataFormat
- Specified by:
getSupportedDataFormat
in interfaceImportedDataExtractor
- Returns:
- supported format of input data
-
getImportedData
-
createImportedDataItem
protected ImportedDataItem createImportedDataItem(com.fasterxml.jackson.databind.JsonNode jsonNode, int itemIndex) -
createImportedObject
-
readRawValues
protected void readRawValues(com.fasterxml.jackson.databind.JsonNode objectNode, RawValuesSource rawValuesSource) -
createImportedObjectList
protected ImportedObjectList createImportedObjectList(com.fasterxml.jackson.databind.JsonNode rootNode)
-