Revision ea7b7584
Added by Cherian Mathew almost 9 years ago
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/operation/RemotingCdmUpdateOperation.java | ||
---|---|---|
30 | 30 |
public abstract class RemotingCdmUpdateOperation extends RemotingCdmOperation { |
31 | 31 |
|
32 | 32 |
private UpdateResult updateResult; |
33 |
public static boolean throwExceptions = false; |
|
33 | 34 |
|
34 | 35 |
/** |
35 | 36 |
* @param label |
... | ... | |
46 | 47 |
try { |
47 | 48 |
updateResult = doUpdateExecute(monitor, info); |
48 | 49 |
} catch (Exception e) { |
49 |
UpdateResult exceptionResult = new UpdateResult(); |
|
50 |
exceptionResult.addException(e); |
|
51 |
exceptionResult.setError(); |
|
52 |
updateResult = exceptionResult; |
|
50 |
if(throwExceptions) { |
|
51 |
throw new RuntimeException(e); |
|
52 |
} else { |
|
53 |
UpdateResult exceptionResult = new UpdateResult(); |
|
54 |
exceptionResult.addException(e); |
|
55 |
exceptionResult.setError(); |
|
56 |
updateResult = exceptionResult; |
|
57 |
} |
|
53 | 58 |
} |
54 | 59 |
return updateResult.isOk(); |
55 | 60 |
} |
Also available in: Unified diff
#5025 : Implement load of UpdateResult using new cdm entity identifier