/** * @deprecated since 2.8 call <code>findJsonValueMethod</code> on {@link BeanDescription} instead */ @Deprecated // not used, possibly remove as early as 2.9 protected AnnotatedMethod _findJsonValueFor(DeserializationConfig config, JavaType enumType) { if (enumType == null) { return null; } BeanDescription beanDesc = config.introspect(enumType); return beanDesc.findJsonValueMethod(); } }
final AnnotatedMethod jsonValueMethod = beanDesc.findJsonValueMethod(); if(jsonValueMethod != null) { AnnotatedType aType = new AnnotatedType()
/** * Creates a new {@link JacksonMetadata} instance for the given {@link ObjectMapper} and type. * * @param mapper must not be {@literal null}. * @param type must not be {@literal null}. */ public JacksonMetadata(ObjectMapper mapper, Class<?> type) { Assert.notNull(mapper, "ObjectMapper must not be null!"); Assert.notNull(type, "Type must not be null!"); this.mapper = mapper; SerializationConfig serializationConfig = mapper.getSerializationConfig(); JavaType javaType = serializationConfig.constructType(type); BeanDescription description = serializationConfig.introspect(javaType); this.definitions = description.findProperties(); this.isValue = description.findJsonValueMethod() != null; DeserializationConfig deserializationConfig = mapper.getDeserializationConfig(); JavaType deserializationType = deserializationConfig.constructType(type); this.deserializationDefinitions = deserializationConfig.introspect(deserializationType).findProperties(); }
protected AnnotatedMethod _findJsonValueFor(DeserializationConfig config, JavaType enumType) { if (enumType == null) { return null; } BeanDescription beanDesc = config.introspect(enumType); return beanDesc.findJsonValueMethod(); } }
protected AnnotatedMethod _findJsonValueFor(DeserializationConfig config, JavaType enumType) { if (enumType == null) { return null; } BeanDescription beanDesc = config.introspect(enumType); return beanDesc.findJsonValueMethod(); } }
protected AnnotatedMethod _findJsonValueFor(DeserializationConfig config, JavaType enumType) { if (enumType == null) { return null; } BeanDescription beanDesc = config.introspect(enumType); return beanDesc.findJsonValueMethod(); } }
protected AnnotatedMethod _findJsonValueFor(DeserializationConfig config, JavaType enumType) { if (enumType == null) { return null; } BeanDescription beanDesc = config.introspect(enumType); return beanDesc.findJsonValueMethod(); } }
/** * @deprecated since 2.8 call <code>findJsonValueMethod</code> on {@link BeanDescription} instead */ @Deprecated // not used, possibly remove as early as 2.9 protected AnnotatedMethod _findJsonValueFor(DeserializationConfig config, JavaType enumType) { if (enumType == null) { return null; } BeanDescription beanDesc = config.introspect(enumType); return beanDesc.findJsonValueMethod(); } }
/** * @deprecated since 2.8 call <code>findJsonValueMethod</code> on {@link BeanDescription} instead */ @Deprecated // not used, possibly remove as early as 2.9 protected AnnotatedMethod _findJsonValueFor(DeserializationConfig config, JavaType enumType) { if (enumType == null) { return null; } BeanDescription beanDesc = config.introspect(enumType); return beanDesc.findJsonValueMethod(); } }
/** * Creates a new {@link JacksonMetadata} instance for the given {@link ObjectMapper} and type. * * @param mapper must not be {@literal null}. * @param type must not be {@literal null}. */ public JacksonMetadata(ObjectMapper mapper, Class<?> type) { Assert.notNull(mapper, "ObjectMapper must not be null!"); Assert.notNull(type, "Type must not be null!"); this.mapper = mapper; SerializationConfig serializationConfig = mapper.getSerializationConfig(); JavaType javaType = serializationConfig.constructType(type); BeanDescription description = serializationConfig.introspect(javaType); this.definitions = description.findProperties(); this.isValue = description.findJsonValueMethod() != null; DeserializationConfig deserializationConfig = mapper.getDeserializationConfig(); JavaType deserializationType = deserializationConfig.constructType(type); this.deserializationDefinitions = deserializationConfig.introspect(deserializationType).findProperties(); }
AnnotatedMethod valueMethod = beanDesc.findJsonValueMethod(); if (valueMethod != null) { Method m = valueMethod.getAnnotated();
AnnotatedMethod valueMethod = beanDesc.findJsonValueMethod(); if (valueMethod != null) { Method m = valueMethod.getAnnotated();
AnnotatedMethod valueMethod = beanDesc.findJsonValueMethod(); if (valueMethod != null) { Method m = valueMethod.getAnnotated();
AnnotatedMethod valueMethod = beanDesc.findJsonValueMethod(); if (valueMethod != null) { Method m = valueMethod.getAnnotated();
AnnotatedMethod valueMethod = beanDesc.findJsonValueMethod(); if (valueMethod != null) { Method m = valueMethod.getAnnotated();
return new EnumDeserializer(constructEnumResolver(enumClass, ctxt.getConfig(), beanDesc.findJsonValueMethod()));
return new EnumDeserializer(constructEnumResolver(enumClass, ctxt.getConfig(), beanDesc.findJsonValueMethod()));
EnumResolver<?> enumRes = constructEnumResolver(enumClass, config, beanDesc.findJsonValueMethod());
EnumResolver<?> enumRes = constructEnumResolver(enumClass, config, beanDesc.findJsonValueMethod());
EnumResolver<?> enumRes = constructEnumResolver(enumClass, config, beanDesc.findJsonValueMethod());