public class FileLoaderProcess
extends java.lang.Object
Constructor and Description |
---|
FileLoaderProcess(ExtSystemInfo extSysInfo,
MaxExtIfaceInInfo extIfaceInInfo,
boolean preview,
boolean fromClientImport,
boolean isFileExtract,
java.lang.String fileFormat,
java.lang.String fileName,
java.lang.String delimiter,
java.lang.String textQualifier,
java.lang.String colHeader,
java.lang.String processOwner)
Construct the set
|
Modifier and Type | Method and Description |
---|---|
void |
cleanup()
Clean up called by flat and xml file load callers to clean up on sql statements, connection etc.
|
void |
close()
Close the JMS related resources.
|
void |
commit()
commit Queue Transaction.
|
org.jdom.Document |
getMasterDoc()
Get Master Document (which is then converted into extract file)/
Applicable in case of Preview mode when Extract file is generated on the fly in memory
|
java.util.List<java.lang.String> |
getTempFiles()
Get list of temporary files.
|
boolean |
isErrorOccured()
Return the value indicating whether error occured during this instance os FileLoader
|
void |
markDBExtractComplete()
In case of File Extract operation in a cron task scenario, because there is an individual commit,
when all records are 'read', database entry will be done to mark it as complete indicating that
the file is been read completely.
|
void |
processCleanup()
Clean up called by flat and xml file load callers to to update database file extract entry,
clean up on sql statements, connection etc.
|
void |
processData(byte[] data,
int intCurrentNoun,
MboRemote npMbo)
Process the incoming Data.
|
void |
writeToQueue(byte[] extData)
Write the data to Queue.
|
public FileLoaderProcess(ExtSystemInfo extSysInfo, MaxExtIfaceInInfo extIfaceInInfo, boolean preview, boolean fromClientImport, boolean isFileExtract, java.lang.String fileFormat, java.lang.String fileName, java.lang.String delimiter, java.lang.String textQualifier, java.lang.String colHeader, java.lang.String processOwner) throws MXException
extSysInfo
- External system Info objectextIfaceInInfo
- Enterprise service info objectpreview
- boolean indicating whether it is a UI preview mode or not.fromClientImport
- boolean indicating whether it is from UI import or crontaskisFileExtract
- boolean indicating if File Load process is looking to do Extract functionality or notfileFormat
- Could be XML or FLAT file formatfileName
- Input file name that is being loadeddelimiter
- Applicable in case of Flat file load operation when fields are separated by certain charactertextQualifier
- Applicable in case of Flat file load operation when field value could delimiter itself and needs to be distinguished in such casecolHeader
- Applicable in case of Flat file load operation when this full string will indicate all column names in order to regenerated extract fileprocessOwner
- Applicable in case of Cron task file load operation and this field indicates the instance name of teh cron taskMXException
- MAXIMO exceptionjava.rmi.RemoteException
- Remote Exceptionpublic void writeToQueue(byte[] extData) throws MXException
extData
- the xml dataMXException
public void commit() throws MXException
MXException
public void close()
public void processData(byte[] data, int intCurrentNoun, MboRemote npMbo) throws MXException, java.rmi.RemoteException
data
- Xml DataintCurrentNoun
- the current noun (or) split noun\npMbo
- Non-persistent Mbo which is used in Preview case to show the stats on data processingMXException
java.rmi.RemoteException
public void markDBExtractComplete() throws java.sql.SQLException
java.lang.Exception
java.sql.SQLException
public void cleanup()
public boolean isErrorOccured()
public java.util.List<java.lang.String> getTempFiles()
public org.jdom.Document getMasterDoc()
public void processCleanup() throws MXApplicationException
MXApplicationException