Class GlobalViolation
- java.lang.Object
-
- org.nuxeo.ecm.core.api.validation.GlobalViolation
-
- All Implemented Interfaces:
Serializable,ValidationViolation
public class GlobalViolation extends Object implements ValidationViolation
Global validation violation simply handling a message key.- Since:
- 11.1
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected StringmessageKey
-
Constructor Summary
Constructors Constructor Description GlobalViolation(String messageKey)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetMessage(Locale locale)StringgetMessageKey()
-
-
-
Field Detail
-
messageKey
protected String messageKey
-
-
Constructor Detail
-
GlobalViolation
public GlobalViolation(String messageKey)
-
-
Method Detail
-
getMessageKey
public String getMessageKey()
- Specified by:
getMessageKeyin interfaceValidationViolation
-
getMessage
public String getMessage(Locale locale)
- Specified by:
getMessagein interfaceValidationViolation- Returns:
- The message if it's found in message bundles,
getMessageKey()otherwise.
-
-