public class ImportLog extends Object
Constructor and Description |
---|
ImportLog() |
ImportLog(String logMessage)
Constructor.
|
ImportLog(String logMessage,
int created,
int updated,
int unchanged,
Map<String,String> errors) |
Modifier and Type | Method and Description |
---|---|
void |
addCreated()
Increment the creation count.
|
void |
addError(String item,
String error)
Indicate that importing the item with the given id
failed with the given error.
|
void |
addUnchanged()
Increment the unchanged count.
|
void |
addUpdated()
Increment the update count.
|
int |
getChanged() |
int |
getCreated() |
Map<String,Object> |
getData() |
int |
getErrored() |
Map<String,String> |
getErrors() |
Optional<String> |
getLogMessage() |
int |
getUnchanged() |
int |
getUpdated() |
boolean |
hasDoneWork()
Indicated whether the import succeeded at all,
in terms of items created/updated.
|
String |
toString() |
public ImportLog(String logMessage)
logMessage
- a log messagepublic ImportLog()
public void addCreated()
public void addUpdated()
public void addUnchanged()
public int getCreated()
public int getUpdated()
public int getUnchanged()
public int getErrored()
public void addError(String item, String error)
item
- The itemerror
- The error that occurredpublic boolean hasDoneWork()
public int getChanged()
Copyright © 2018 The European Holocaust Research Infrastructure (EHRI). All rights reserved.