Class ChunkReader
- java.lang.Object
-
- javax.batch.api.chunk.AbstractItemReader
-
- com.ibm.fhir.jbatch.bulkdata.export.patient.ChunkReader
-
- All Implemented Interfaces:
javax.batch.api.chunk.ItemReader
- Direct Known Subclasses:
ChunkReader
@Dependent public class ChunkReader extends javax.batch.api.chunk.AbstractItemReader
Bulk patient export Chunk implementation - the Reader.
-
-
Field Summary
Fields Modifier and Type Field Description protected String
fhirDatastoreId
FHIR data store id.protected String
fhirExportFormat
FHIR export format.protected FHIRPersistence
fhirPersistence
protected String
fhirResourceType
FHIR resource type to process.(package private) String
fhirSearchFromDate
FHIR Search from date.(package private) String
fhirSearchPageSize
FHIR search page size.(package private) String
fhirSearchToDate
FHIR search to date.protected String
fhirTenant
FHIR tenant id.(package private) String
fhirTypeFilters
FHIR export type filters.(package private) String
incomingUrl
(package private) boolean
isDoDuplicationCheck
(package private) Set<String>
loadedResourceIds
protected int
pageNum
protected int
pageSize
(package private) Class<? extends Resource>
resourceType
(package private) Map<Class<? extends Resource>,List<Map<String,List<String>>>>
searchParametersForResoureTypes
(package private) javax.batch.runtime.context.StepContext
stepCtx
-
Constructor Summary
Constructors Constructor Description ChunkReader()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Serializable
checkpointInfo()
void
close()
protected void
fillChunkData(List<Resource> resources, List<String> patientIds)
protected void
fillChunkDataBuffer(List<String> patientIds)
protected void
fillChunkPatientDataBuffer(List<Resource> patients)
void
open(Serializable checkpoint)
Object
readItem()
-
-
-
Field Detail
-
pageNum
protected int pageNum
-
pageSize
protected int pageSize
-
fhirPersistence
protected FHIRPersistence fhirPersistence
-
searchParametersForResoureTypes
Map<Class<? extends Resource>,List<Map<String,List<String>>>> searchParametersForResoureTypes
-
isDoDuplicationCheck
boolean isDoDuplicationCheck
-
fhirTenant
@Inject protected String fhirTenant
FHIR tenant id.
-
fhirDatastoreId
@Inject protected String fhirDatastoreId
FHIR data store id.
-
fhirResourceType
@Inject protected String fhirResourceType
FHIR resource type to process.
-
fhirExportFormat
@Inject protected String fhirExportFormat
FHIR export format.
-
fhirSearchFromDate
@Inject String fhirSearchFromDate
FHIR Search from date.
-
fhirSearchToDate
@Inject String fhirSearchToDate
FHIR search to date.
-
fhirSearchPageSize
@Inject String fhirSearchPageSize
FHIR search page size.
-
fhirTypeFilters
@Inject String fhirTypeFilters
FHIR export type filters.
-
incomingUrl
@Inject String incomingUrl
-
stepCtx
@Inject javax.batch.runtime.context.StepContext stepCtx
-
-
Method Detail
-
fillChunkDataBuffer
protected void fillChunkDataBuffer(List<String> patientIds) throws Exception
- Throws:
Exception
-
fillChunkPatientDataBuffer
protected void fillChunkPatientDataBuffer(List<Resource> patients) throws Exception
- Throws:
Exception
-
fillChunkData
protected void fillChunkData(List<Resource> resources, List<String> patientIds) throws Exception
- Throws:
Exception
-
readItem
public Object readItem() throws Exception
- Specified by:
readItem
in interfacejavax.batch.api.chunk.ItemReader
- Specified by:
readItem
in classjavax.batch.api.chunk.AbstractItemReader
- Throws:
Exception
-
open
public void open(Serializable checkpoint) throws Exception
- Specified by:
open
in interfacejavax.batch.api.chunk.ItemReader
- Overrides:
open
in classjavax.batch.api.chunk.AbstractItemReader
- Throws:
Exception
-
close
public void close() throws Exception
- Specified by:
close
in interfacejavax.batch.api.chunk.ItemReader
- Overrides:
close
in classjavax.batch.api.chunk.AbstractItemReader
- Throws:
Exception
-
checkpointInfo
public Serializable checkpointInfo() throws Exception
- Specified by:
checkpointInfo
in interfacejavax.batch.api.chunk.ItemReader
- Overrides:
checkpointInfo
in classjavax.batch.api.chunk.AbstractItemReader
- Throws:
Exception
-
-