Coverage Summary for Class: DuplicateElementException (it.polimi.ingsw.Exceptions.Input)
| Class | Class, % | Method, % | Line, % |
|---|---|---|---|
| DuplicateElementException | 100% (1/1) | 100% (1/1) | 100% (1/1) |
1 package it.polimi.ingsw.Exceptions.Input; 2 3 /** 4 * Signals there was an error while validating part of a contract. In this case the error is: an element was not unique in the 5 * context of validation 6 */ 7 public class DuplicateElementException extends InputValidationException { 8 /** 9 * Creates an exception reporting a specific error and an identifier for the part of the failed contract 10 * 11 * @param elementName the name of the field in the contract that failed validation 12 */ 13 public DuplicateElementException(String elementName) { 14 super(elementName, "element " + elementName + " was found to be duplicate."); 15 } 16 }