/** * Registers a translation with the given schema * * @param clazz The POJO class that will be returned when a JSON document of * this type is parsed * @param fromJson The implementation of FromJson interface that performs * the actual parsing * @param schema The JSON schema */ public void registerTranslation(Class clazz, FromJson fromJson, JsonSchema schema) { TranslationInfo ti = new TranslationInfo(fromJson, schema); translationMap.put(clazz, ti); }
LOGGER.debug("validating {}", clazz); try { String validationErrors = JsonUtils.jsonSchemaValidation(t.getSchema(), node); if (validationErrors != null) { throw Error.get(ConfigConstants.ERR_VALIDATION_FAILED, validationErrors);
LOGGER.debug("validating {}",clazz); try { String validationErrors=JsonUtils.jsonSchemaValidation(t.getSchema(),node); if(validationErrors!=null) { throw Error.get(ConfigConstants.ERR_VALIDATION_FAILED,validationErrors);
LOGGER.debug("validating {}", clazz); try { String validationErrors = JsonUtils.jsonSchemaValidation(t.getSchema(), node); if (validationErrors != null) { throw Error.get(ConfigConstants.ERR_VALIDATION_FAILED, validationErrors);
/** * Registers a translation with the given schema * * @param clazz The POJO class that will be returned when a JSON * document of this type is parsed * @param fromJson The implementation of FromJson interface that * performs the actual parsing * @param schema The JSON schema */ public void registerTranslation(Class clazz,FromJson fromJson,JsonSchema schema) { TranslationInfo ti=new TranslationInfo(fromJson,schema); translationMap.put(clazz,ti); }
/** * Registers a translation with the given schema * * @param clazz The POJO class that will be returned when a JSON document of * this type is parsed * @param fromJson The implementation of FromJson interface that performs * the actual parsing * @param schema The JSON schema */ public void registerTranslation(Class clazz, FromJson fromJson, JsonSchema schema) { TranslationInfo ti = new TranslationInfo(fromJson, schema); translationMap.put(clazz, ti); }