class ErrorDefinitionValidator {

    public static void validate(ErrorDefinition definition) {
        UNIQUE_FIELD_NAMES_VALIDATOR.validate(
                Stream.concat(definition.getSafeArgs().stream(), definition.getUnsafeArgs().stream())
                        .map(FieldDefinition::getFieldName)
                        .collect(Collectors.toSet()));
    }

    private  ErrorDefinitionValidator();

}