本文整理汇总了Java中org.codehaus.jackson.map.DeserializerProvider.findValueDeserializer方法的典型用法代码示例。如果您正苦于以下问题:Java DeserializerProvider.findValueDeserializer方法的具体用法?Java DeserializerProvider.findValueDeserializer怎么用?Java DeserializerProvider.findValueDeserializer使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.codehaus.jackson.map.DeserializerProvider
的用法示例。
在下文中一共展示了DeserializerProvider.findValueDeserializer方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: createArrayDeserializer
import org.codehaus.jackson.map.DeserializerProvider; //导入方法依赖的package包/类
public JsonDeserializer<?> createArrayDeserializer(DeserializationConfig paramDeserializationConfig, DeserializerProvider paramDeserializerProvider, ArrayType paramArrayType, BeanProperty paramBeanProperty)
throws JsonMappingException
{
JavaType localJavaType = paramArrayType.getContentType();
JsonDeserializer localJsonDeserializer1 = (JsonDeserializer)localJavaType.getValueHandler();
if (localJsonDeserializer1 == null)
{
Object localObject = (JsonDeserializer)_arrayDeserializers.get(localJavaType);
if (localObject != null)
{
JsonDeserializer localJsonDeserializer3 = _findCustomArrayDeserializer(paramArrayType, paramDeserializationConfig, paramDeserializerProvider, paramBeanProperty, null, null);
if (localJsonDeserializer3 != null)
localObject = localJsonDeserializer3;
return localObject;
}
if (localJavaType.isPrimitive())
throw new IllegalArgumentException("Internal error: primitive type (" + paramArrayType + ") passed, no array deserializer found");
}
TypeDeserializer localTypeDeserializer = (TypeDeserializer)localJavaType.getTypeHandler();
if (localTypeDeserializer == null)
localTypeDeserializer = findTypeDeserializer(paramDeserializationConfig, localJavaType, paramBeanProperty);
JsonDeserializer localJsonDeserializer2 = _findCustomArrayDeserializer(paramArrayType, paramDeserializationConfig, paramDeserializerProvider, paramBeanProperty, localTypeDeserializer, localJsonDeserializer1);
if (localJsonDeserializer2 != null)
return localJsonDeserializer2;
if (localJsonDeserializer1 == null)
localJsonDeserializer1 = paramDeserializerProvider.findValueDeserializer(paramDeserializationConfig, localJavaType, paramBeanProperty);
return (JsonDeserializer<?>)new ArrayDeserializer(paramArrayType, localJsonDeserializer1, localTypeDeserializer);
}
示例2: createCollectionDeserializer
import org.codehaus.jackson.map.DeserializerProvider; //导入方法依赖的package包/类
public JsonDeserializer<?> createCollectionDeserializer(DeserializationConfig paramDeserializationConfig, DeserializerProvider paramDeserializerProvider, CollectionType paramCollectionType, BeanProperty paramBeanProperty)
throws JsonMappingException
{
CollectionType localCollectionType1 = (CollectionType)mapAbstractType(paramDeserializationConfig, paramCollectionType);
Object localObject = localCollectionType1.getRawClass();
BasicBeanDescription localBasicBeanDescription = (BasicBeanDescription)paramDeserializationConfig.introspectClassAnnotations((Class)localObject);
JsonDeserializer localJsonDeserializer1 = findDeserializerFromAnnotation(paramDeserializationConfig, localBasicBeanDescription.getClassInfo(), paramBeanProperty);
if (localJsonDeserializer1 != null)
return localJsonDeserializer1;
CollectionType localCollectionType2 = (CollectionType)modifyTypeByAnnotation(paramDeserializationConfig, localBasicBeanDescription.getClassInfo(), localCollectionType1, null);
JavaType localJavaType = localCollectionType2.getContentType();
JsonDeserializer localJsonDeserializer2 = (JsonDeserializer)localJavaType.getValueHandler();
TypeDeserializer localTypeDeserializer = (TypeDeserializer)localJavaType.getTypeHandler();
if (localTypeDeserializer == null)
localTypeDeserializer = findTypeDeserializer(paramDeserializationConfig, localJavaType, paramBeanProperty);
JsonDeserializer localJsonDeserializer3 = _findCustomCollectionDeserializer(localCollectionType2, paramDeserializationConfig, paramDeserializerProvider, localBasicBeanDescription, paramBeanProperty, localTypeDeserializer, localJsonDeserializer2);
if (localJsonDeserializer3 != null)
return localJsonDeserializer3;
if (localJsonDeserializer2 == null)
{
if (EnumSet.class.isAssignableFrom((Class)localObject))
return new EnumSetDeserializer(constructEnumResolver(localJavaType.getRawClass(), paramDeserializationConfig));
localJsonDeserializer2 = paramDeserializerProvider.findValueDeserializer(paramDeserializationConfig, localJavaType, paramBeanProperty);
}
if ((localCollectionType2.isInterface()) || (localCollectionType2.isAbstract()))
{
Class localClass = (Class)_collectionFallbacks.get(((Class)localObject).getName());
if (localClass == null)
throw new IllegalArgumentException("Can not find a deserializer for non-concrete Collection type " + localCollectionType2);
localObject = localClass;
}
Constructor localConstructor = ClassUtil.findConstructor((Class)localObject, paramDeserializationConfig.isEnabled(DeserializationConfig.Feature.CAN_OVERRIDE_ACCESS_MODIFIERS));
if (localJavaType.getRawClass() == String.class)
return new StringCollectionDeserializer(localCollectionType2, localJsonDeserializer2, localConstructor);
return (JsonDeserializer<?>)new CollectionDeserializer(localCollectionType2, localJsonDeserializer2, localTypeDeserializer, localConstructor);
}
示例3: _findSubclassDeserializer
import org.codehaus.jackson.map.DeserializerProvider; //导入方法依赖的package包/类
protected JsonDeserializer<Object> _findSubclassDeserializer(DeserializationContext paramDeserializationContext, Object paramObject, TokenBuffer paramTokenBuffer)
{
Object localObject2;
try
{
if (this._subDeserializers == null);
for (localObject2 = null; ; localObject2 = (JsonDeserializer)this._subDeserializers.get(new ClassKey(paramObject.getClass())))
{
if (localObject2 == null)
break;
return localObject2;
}
}
finally
{
}
DeserializerProvider localDeserializerProvider = paramDeserializationContext.getDeserializerProvider();
if (localDeserializerProvider != null)
{
JavaType localJavaType = paramDeserializationContext.constructType(paramObject.getClass());
localObject2 = localDeserializerProvider.findValueDeserializer(paramDeserializationContext.getConfig(), localJavaType, this._property);
if (localObject2 != null)
try
{
if (this._subDeserializers == null)
this._subDeserializers = new HashMap();
this._subDeserializers.put(new ClassKey(paramObject.getClass()), localObject2);
return localObject2;
}
finally
{
}
}
return localObject2;
}
示例4: findDeserializer
import org.codehaus.jackson.map.DeserializerProvider; //导入方法依赖的package包/类
protected JsonDeserializer<Object> findDeserializer(DeserializationConfig paramDeserializationConfig, DeserializerProvider paramDeserializerProvider, JavaType paramJavaType, BeanProperty paramBeanProperty)
throws JsonMappingException
{
return paramDeserializerProvider.findValueDeserializer(paramDeserializationConfig, paramJavaType, paramBeanProperty);
}
示例5: resolve
import org.codehaus.jackson.map.DeserializerProvider; //导入方法依赖的package包/类
public void resolve(DeserializationConfig paramDeserializationConfig, DeserializerProvider paramDeserializerProvider)
throws JsonMappingException
{
this._valueDeserializer = paramDeserializerProvider.findValueDeserializer(paramDeserializationConfig, this._referencedType, this._property);
}
示例6: findDeserializer
import org.codehaus.jackson.map.DeserializerProvider; //导入方法依赖的package包/类
protected JsonDeserializer<Object> findDeserializer(DeserializationConfig paramDeserializationConfig, DeserializerProvider paramDeserializerProvider, JavaType paramJavaType, BeanProperty paramBeanProperty)
{
return paramDeserializerProvider.findValueDeserializer(paramDeserializationConfig, paramJavaType, paramBeanProperty);
}
示例7: resolve
import org.codehaus.jackson.map.DeserializerProvider; //导入方法依赖的package包/类
public void resolve(DeserializationConfig paramDeserializationConfig, DeserializerProvider paramDeserializerProvider)
{
this._valueDeserializer = paramDeserializerProvider.findValueDeserializer(paramDeserializationConfig, this._referencedType, this._property);
}
示例8: a
import org.codehaus.jackson.map.DeserializerProvider; //导入方法依赖的package包/类
private static JsonDeserializer<?> a(JsonDeserializer<?> paramJsonDeserializer, DeserializationConfig paramDeserializationConfig, DeserializerProvider paramDeserializerProvider, BeanProperty paramBeanProperty, JavaType paramJavaType)
{
if (paramJsonDeserializer == null)
paramJsonDeserializer = paramDeserializerProvider.findValueDeserializer(paramDeserializationConfig, paramJavaType.getContentType(), paramBeanProperty);
return paramJsonDeserializer;
}