Modifier and Type | Field and Description |
---|---|
static int |
STATUS_FINISHED |
static int |
STATUS_QUEUED |
static int |
STATUS_WORKING |
Constructor and Description |
---|
RunnableImportService(IImportSource importSource,
String strTableName,
fr.paris.lutece.portal.service.plugin.Plugin plugin,
Locale locale,
boolean bUpdateExistingRows,
boolean bStopOnErrors,
boolean bEmptyTable)
Service to asynchronously import data
|
Modifier and Type | Method and Description |
---|---|
ImportResult |
getImportResult()
Get the result of the importation of this service
|
int |
getServiceStatus()
Get the status of the service.
|
void |
run() |
public static final int STATUS_QUEUED
public static final int STATUS_WORKING
public static final int STATUS_FINISHED
public RunnableImportService(IImportSource importSource, String strTableName, fr.paris.lutece.portal.service.plugin.Plugin plugin, Locale locale, boolean bUpdateExistingRows, boolean bStopOnErrors, boolean bEmptyTable)
importSource
- The data source to get data fromstrTableName
- The name of the tableplugin
- The plugin associated with the pool the table of the
database is in.locale
- The locale to display messages inbUpdateExistingRows
- Indicates whether existing rows should be
updated (true) or ignored (false)bStopOnErrors
- True to stop when an error occurred, false to skip
the item and continuebEmptyTable
- True to empty the table before importing data, false
otherwisepublic int getServiceStatus()
STATUS_QUEUED
if the serviced has not been started,
STATUS_WORKING
if it is executing, or
STATUS_FINISHED
if its execution has ended.public ImportResult getImportResult()
Copyright © 2018 City of Paris. All rights reserved.