| 1 | package fr.sii.ogham.core.exception.handler; | |
| 2 | ||
| 3 | import static fr.sii.ogham.core.CoreConstants.SERIAL_VERSION_UID; | |
| 4 | ||
| 5 | import java.util.List; | |
| 6 | ||
| 7 | import fr.sii.ogham.core.message.content.MultiContent; | |
| 8 | ||
| 9 | /** | |
| 10 | * A specialized exception that is thrown when the content of the message is not | |
| 11 | * set or empty. | |
| 12 | * | |
| 13 | * @author Aurélien Baudet | |
| 14 | * | |
| 15 | */ | |
| 16 | public class NoContentException extends ContentTranslatorException { | |
| 17 | /** | |
| 18 | * | |
| 19 | */ | |
| 20 | private static final long serialVersionUID = SERIAL_VERSION_UID; | |
| 21 | ||
| 22 | private final transient MultiContent content; | |
| 23 | private final List<ContentTranslatorException> errors; | |
| 24 | ||
| 25 | public NoContentException(String message, MultiContent content, List<ContentTranslatorException> errors) { | |
| 26 | super(message); | |
| 27 | this.content = content; | |
| 28 | this.errors = errors; | |
| 29 | } | |
| 30 | ||
| 31 | public MultiContent getContent() { | |
| 32 |
1
1. getContent : replaced return value with null for fr/sii/ogham/core/exception/handler/NoContentException::getContent → NO_COVERAGE |
return content; |
| 33 | } | |
| 34 | ||
| 35 | public List<ContentTranslatorException> getErrors() { | |
| 36 |
2
1. getErrors : replaced return value with Collections.emptyList for fr/sii/ogham/core/exception/handler/NoContentException::getErrors → NO_COVERAGE 2. getErrors : replaced return value with Collections.emptyList for fr/sii/ogham/core/exception/handler/NoContentException::getErrors → KILLED |
return errors; |
| 37 | } | |
| 38 | } | |
Mutations | ||
| 32 |
1.1 |
|
| 36 |
1.1 2.2 |