Package org.openbravo.service.db
Class ImportResult
- java.lang.Object
-
- org.openbravo.service.db.ImportResult
-
public class ImportResult extends Object
Contains the result of an import action, i.e. warning, error, inserted objects and other import result related information.- Author:
- mtaal
-
-
Constructor Summary
Constructors Constructor Description ImportResult()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getErrorMessages()
Throwable
getException()
List<BaseOBObject>
getInsertedObjects()
The list of objects which have been inserted.String
getLogMessages()
List<BaseOBObject>
getUpdatedObjects()
The list of objects which have been updated.String
getWarningMessages()
boolean
hasErrorOccured()
-
-
-
Method Detail
-
hasErrorOccured
public boolean hasErrorOccured()
- Returns:
- true if an Exception is present in the ImportResult or the errormessages are set
-
getUpdatedObjects
public List<BaseOBObject> getUpdatedObjects()
The list of objects which have been updated. Note that for these objects theOBDal.save(Object)
method has been called, but the commit is the responsibility of the caller of the import service.This list is empty if an error has occurred during the import (@see
hasErrorOccured()
.- Returns:
- the list of objects which have been updated.
-
getInsertedObjects
public List<BaseOBObject> getInsertedObjects()
The list of objects which have been inserted. Note that for these objects theOBDal.save(Object)
method has been called, but the commit is the responsibility of the caller of the import service.This list is empty if an error has occurred during the import (@see
hasErrorOccured()
.- Returns:
- the list of objects which have been inserted.
-
getErrorMessages
public String getErrorMessages()
- Returns:
- the error messages, if no error messages then null is returned.
-
getLogMessages
public String getLogMessages()
- Returns:
- the log messages, if no log messages then null is returned.
-
getException
public Throwable getException()
- Returns:
- if an Exception occurred during import then this Exception can be retrieved through this method
-
getWarningMessages
public String getWarningMessages()
- Returns:
- the warning messages, if no warning messages then null is returned.
-
-