Interface ImportNotificationMonitor
public interface ImportNotificationMonitor
This callback interface can be passed to a 
DataStoreConnection to receive errors and warnings during import.
 Importation can take place on multiple worker threads simultaneously, so implementations should be prepared to handle 
 asynchronous invocations. Moreover, it is possible that multiple sources will be imported simultaneously, so each
 source is distinguished by an integer job ID.- 
Nested Class SummaryNested Classes Modifier and Type Interface Description static classImportNotificationMonitor.NotificationActionDetermines how to proceed after a notification.static classImportNotificationMonitor.NotificationTypeDetermines the type of a notification.
- 
Field SummaryFields Modifier and Type Field Description static ImportNotificationMonitors_firstErrorExceptionMonitorProvides a default implementation of an import monitor that throws an exception upon first error notification.static ImportNotificationMonitors_nullMonitorProvides a default implementation of an import monitor that ignores all notifications.
- 
Method SummaryModifier and Type Method Description voidimportJobFinished(int jobID)Called when the importation of a data source finishes.voidimportJobStarted(int jobID, java.lang.String inputSourceName)Called when the importation of a data source starts.ImportNotificationMonitor.NotificationActionimportNotification(int jobID, ImportNotificationMonitor.NotificationType notificationType, long line, long column, java.lang.String description, long totalNotificationsThusFar)Called when an error or a warning is encountered.voidimportProcessFinished(ImportResult importResult, Prefixes prefixes)Called at the end of importation to notify the monitor about the results.voidimportProcessStarted()Called at the beginning of importation to allow the monitor to prepare any data structures it might need.
- 
Field Details- 
s_nullMonitorProvides a default implementation of an import monitor that ignores all notifications.
- 
s_firstErrorExceptionMonitorProvides a default implementation of an import monitor that throws an exception upon first error notification.
 
- 
- 
Method Details- 
importProcessStartedvoid importProcessStarted()Called at the beginning of importation to allow the monitor to prepare any data structures it might need.
- 
importJobStartedvoid importJobStarted(int jobID, java.lang.String inputSourceName)Called when the importation of a data source starts.- Parameters:
- jobID- an identifier identifying an import job
- inputSourceName- the name of the input source that will be imported
 
- 
importNotificationImportNotificationMonitor.NotificationAction importNotification(int jobID, ImportNotificationMonitor.NotificationType notificationType, long line, long column, java.lang.String description, long totalNotificationsThusFar)Called when an error or a warning is encountered.- Parameters:
- jobID- an identifier identifying an import job
- notificationType- determines the type of notification (i.e., an error or a warning)
- line- the line number in the input source where the error/warning was produced
- column- the column number in the input source where the error/warning was produced
- description- text describing the error/warning
- totalNotificationsThusFar- the total number of errors/notifications encountered thus far across all input sources
- Returns:
- determines how the import should proceed after this notification
 
- 
importJobFinishedvoid importJobFinished(int jobID)Called when the importation of a data source finishes.- Parameters:
- jobID- an identifier identifying an import job
 
- 
importProcessFinishedCalled at the end of importation to notify the monitor about the results.- Parameters:
- importResult- contains information about the import
- prefixes- contains the prefixes encountered during the process
 
 
-