本文整理匯總了Java中com.fasterxml.jackson.databind.BeanProperty.getMember方法的典型用法代碼示例。如果您正苦於以下問題:Java BeanProperty.getMember方法的具體用法?Java BeanProperty.getMember怎麽用?Java BeanProperty.getMember使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.fasterxml.jackson.databind.BeanProperty
的用法示例。
在下文中一共展示了BeanProperty.getMember方法的12個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: createContextual
import com.fasterxml.jackson.databind.BeanProperty; //導入方法依賴的package包/類
@Override
public JsonSerializer<?> createContextual(SerializerProvider prov, BeanProperty property) throws JsonMappingException {
if (property != null) {
Annotated annotated = property.getMember();
if (annotated instanceof AnnotatedField || annotated instanceof AnnotatedMethod) {
IndexableProperty indexableProperty = annotated.getAnnotation(IndexableProperty.class);
if (indexableProperty != null && !indexableProperty.format().isEmpty()) {
formatString = indexableProperty.format();
}
}
}
return this;
}
示例2: createContextual
import com.fasterxml.jackson.databind.BeanProperty; //導入方法依賴的package包/類
@Override
public JsonDeserializer<?> createContextual(DeserializationContext ctxt, BeanProperty property) throws JsonMappingException {
if (property != null) {
Annotated annotated = property.getMember();
if (annotated instanceof AnnotatedField || annotated instanceof AnnotatedMethod) {
IndexableProperty indexableProperty = annotated.getAnnotation(IndexableProperty.class);
if (indexableProperty != null && !indexableProperty.format().isEmpty()) {
formatString = indexableProperty.format();
}
}
}
return this;
}
示例3: createContextual
import com.fasterxml.jackson.databind.BeanProperty; //導入方法依賴的package包/類
public JsonSerializer<?> createContextual(SerializerProvider paramSerializerProvider, BeanProperty paramBeanProperty)
{
TypeSerializer localTypeSerializer1 = this._valueTypeSerializer;
TypeSerializer localTypeSerializer2 = localTypeSerializer1;
if (localTypeSerializer1 != null)
localTypeSerializer2 = localTypeSerializer2.forProperty(paramBeanProperty);
JsonSerializer localJsonSerializer1 = null;
if (paramBeanProperty != null)
{
AnnotatedMember localAnnotatedMember = paramBeanProperty.getMember();
localJsonSerializer1 = null;
if (localAnnotatedMember != null)
{
Object localObject = paramSerializerProvider.getAnnotationIntrospector().findContentSerializer(localAnnotatedMember);
localJsonSerializer1 = null;
if (localObject != null)
localJsonSerializer1 = paramSerializerProvider.serializerInstance(localAnnotatedMember, localObject);
}
}
if (localJsonSerializer1 == null)
localJsonSerializer1 = this._elementSerializer;
JsonSerializer localJsonSerializer2 = findConvertingContentSerializer(paramSerializerProvider, paramBeanProperty, localJsonSerializer1);
JsonSerializer localJsonSerializer3 = localJsonSerializer2;
if (localJsonSerializer2 == null)
{
if ((this._elementType != null) && ((this._staticTyping) || (hasContentTypeAnnotation(paramSerializerProvider, paramBeanProperty))))
localJsonSerializer3 = paramSerializerProvider.findValueSerializer(this._elementType, paramBeanProperty);
}
else if ((localJsonSerializer3 instanceof ContextualSerializer))
localJsonSerializer3 = ((ContextualSerializer)localJsonSerializer3).createContextual(paramSerializerProvider, paramBeanProperty);
return withResolved(paramBeanProperty, localTypeSerializer2, localJsonSerializer3);
}
示例4: createContextual
import com.fasterxml.jackson.databind.BeanProperty; //導入方法依賴的package包/類
public JsonSerializer<?> createContextual(SerializerProvider paramSerializerProvider, BeanProperty paramBeanProperty)
{
TypeSerializer localTypeSerializer1 = this._valueTypeSerializer;
TypeSerializer localTypeSerializer2 = localTypeSerializer1;
if (localTypeSerializer1 != null)
localTypeSerializer2 = localTypeSerializer2.forProperty(paramBeanProperty);
JsonSerializer localJsonSerializer1 = null;
if (paramBeanProperty != null)
{
AnnotatedMember localAnnotatedMember = paramBeanProperty.getMember();
localJsonSerializer1 = null;
if (localAnnotatedMember != null)
{
Object localObject = paramSerializerProvider.getAnnotationIntrospector().findContentSerializer(localAnnotatedMember);
localJsonSerializer1 = null;
if (localObject != null)
localJsonSerializer1 = paramSerializerProvider.serializerInstance(localAnnotatedMember, localObject);
}
}
if (localJsonSerializer1 == null)
localJsonSerializer1 = this._elementSerializer;
JsonSerializer localJsonSerializer2 = findConvertingContentSerializer(paramSerializerProvider, paramBeanProperty, localJsonSerializer1);
JsonSerializer localJsonSerializer3 = localJsonSerializer2;
if (localJsonSerializer2 == null)
{
if ((localJsonSerializer3 == null) && (this._elementType != null) && ((this._staticTyping) || (hasContentTypeAnnotation(paramSerializerProvider, paramBeanProperty))))
localJsonSerializer3 = paramSerializerProvider.findValueSerializer(this._elementType, paramBeanProperty);
}
else if ((localJsonSerializer3 instanceof ContextualSerializer))
localJsonSerializer3 = ((ContextualSerializer)localJsonSerializer3).createContextual(paramSerializerProvider, paramBeanProperty);
if ((localJsonSerializer3 != this._elementSerializer) || (paramBeanProperty != this._property) || (this._valueTypeSerializer != localTypeSerializer2))
return withResolved(paramBeanProperty, localTypeSerializer2, localJsonSerializer3);
return this;
}
示例5: createContextual
import com.fasterxml.jackson.databind.BeanProperty; //導入方法依賴的package包/類
public JsonSerializer<?> createContextual(SerializerProvider paramSerializerProvider, BeanProperty paramBeanProperty)
{
JsonSerializer localJsonSerializer1 = null;
if (paramBeanProperty != null)
{
AnnotatedMember localAnnotatedMember = paramBeanProperty.getMember();
localJsonSerializer1 = null;
if (localAnnotatedMember != null)
{
Object localObject = paramSerializerProvider.getAnnotationIntrospector().findContentSerializer(localAnnotatedMember);
localJsonSerializer1 = null;
if (localObject != null)
localJsonSerializer1 = paramSerializerProvider.serializerInstance(localAnnotatedMember, localObject);
}
}
if (localJsonSerializer1 == null)
localJsonSerializer1 = this._valueSerializer;
JsonSerializer localJsonSerializer2 = findConvertingContentSerializer(paramSerializerProvider, paramBeanProperty, localJsonSerializer1);
JsonSerializer localJsonSerializer3 = localJsonSerializer2;
if (localJsonSerializer2 == null)
{
if (this._staticTyping)
return withValueSerializer(paramBeanProperty, paramSerializerProvider.findValueSerializer(this._valueType, paramBeanProperty));
}
else if ((this._valueSerializer instanceof ContextualSerializer))
localJsonSerializer3 = ((ContextualSerializer)localJsonSerializer3).createContextual(paramSerializerProvider, paramBeanProperty);
if (localJsonSerializer3 != this._valueSerializer)
return withValueSerializer(paramBeanProperty, localJsonSerializer3);
return this;
}
示例6: createContextual
import com.fasterxml.jackson.databind.BeanProperty; //導入方法依賴的package包/類
public final JsonSerializer<?> createContextual(SerializerProvider paramSerializerProvider, BeanProperty paramBeanProperty)
{
JsonSerializer localJsonSerializer1 = null;
if (paramBeanProperty != null)
{
AnnotatedMember localAnnotatedMember = paramBeanProperty.getMember();
localJsonSerializer1 = null;
if (localAnnotatedMember != null)
{
Object localObject = paramSerializerProvider.getAnnotationIntrospector().findContentSerializer(localAnnotatedMember);
localJsonSerializer1 = null;
if (localObject != null)
localJsonSerializer1 = paramSerializerProvider.serializerInstance(localAnnotatedMember, localObject);
}
}
if (localJsonSerializer1 == null)
localJsonSerializer1 = this._serializer;
JsonSerializer localJsonSerializer2 = findConvertingContentSerializer(paramSerializerProvider, paramBeanProperty, localJsonSerializer1);
JsonSerializer localJsonSerializer3 = localJsonSerializer2;
if (localJsonSerializer2 == null)
localJsonSerializer3 = paramSerializerProvider.findValueSerializer(String.class, paramBeanProperty);
else if ((localJsonSerializer3 instanceof ContextualSerializer))
localJsonSerializer3 = ((ContextualSerializer)localJsonSerializer3).createContextual(paramSerializerProvider, paramBeanProperty);
if (isDefaultSerializer(localJsonSerializer3))
localJsonSerializer3 = null;
if (localJsonSerializer3 == this._serializer)
return this;
return new IndexedStringListSerializer(localJsonSerializer3);
}
示例7: createContextual
import com.fasterxml.jackson.databind.BeanProperty; //導入方法依賴的package包/類
public JsonSerializer<?> createContextual(SerializerProvider paramSerializerProvider, BeanProperty paramBeanProperty)
{
JsonSerializer localJsonSerializer1 = null;
if (paramBeanProperty != null)
{
AnnotatedMember localAnnotatedMember = paramBeanProperty.getMember();
localJsonSerializer1 = null;
if (localAnnotatedMember != null)
{
Object localObject = paramSerializerProvider.getAnnotationIntrospector().findContentSerializer(localAnnotatedMember);
localJsonSerializer1 = null;
if (localObject != null)
localJsonSerializer1 = paramSerializerProvider.serializerInstance(localAnnotatedMember, localObject);
}
}
if (localJsonSerializer1 == null)
localJsonSerializer1 = this._serializer;
JsonSerializer localJsonSerializer2 = findConvertingContentSerializer(paramSerializerProvider, paramBeanProperty, localJsonSerializer1);
JsonSerializer localJsonSerializer3 = localJsonSerializer2;
if (localJsonSerializer2 == null)
localJsonSerializer3 = paramSerializerProvider.findValueSerializer(String.class, paramBeanProperty);
else if ((localJsonSerializer3 instanceof ContextualSerializer))
localJsonSerializer3 = ((ContextualSerializer)localJsonSerializer3).createContextual(paramSerializerProvider, paramBeanProperty);
if (isDefaultSerializer(localJsonSerializer3))
localJsonSerializer3 = null;
if (localJsonSerializer3 == this._serializer)
return this;
return new StringCollectionSerializer(localJsonSerializer3);
}
示例8: createContextual
import com.fasterxml.jackson.databind.BeanProperty; //導入方法依賴的package包/類
public JsonSerializer<?> createContextual(SerializerProvider paramSerializerProvider, BeanProperty paramBeanProperty)
{
JsonSerializer localJsonSerializer1 = null;
if (paramBeanProperty != null)
{
AnnotatedMember localAnnotatedMember = paramBeanProperty.getMember();
localJsonSerializer1 = null;
if (localAnnotatedMember != null)
{
Object localObject = paramSerializerProvider.getAnnotationIntrospector().findContentSerializer(localAnnotatedMember);
localJsonSerializer1 = null;
if (localObject != null)
localJsonSerializer1 = paramSerializerProvider.serializerInstance(localAnnotatedMember, localObject);
}
}
if (localJsonSerializer1 == null)
localJsonSerializer1 = this._elementSerializer;
JsonSerializer localJsonSerializer2 = findConvertingContentSerializer(paramSerializerProvider, paramBeanProperty, localJsonSerializer1);
JsonSerializer localJsonSerializer3 = localJsonSerializer2;
if (localJsonSerializer2 == null)
localJsonSerializer3 = paramSerializerProvider.findValueSerializer(String.class, paramBeanProperty);
else if ((localJsonSerializer3 instanceof ContextualSerializer))
localJsonSerializer3 = ((ContextualSerializer)localJsonSerializer3).createContextual(paramSerializerProvider, paramBeanProperty);
if (isDefaultSerializer(localJsonSerializer3))
localJsonSerializer3 = null;
if (localJsonSerializer3 == this._elementSerializer)
return this;
return new StringArraySerializer(this, paramBeanProperty, localJsonSerializer3);
}
示例9: createContextual
import com.fasterxml.jackson.databind.BeanProperty; //導入方法依賴的package包/類
@Override
public JsonSerializer<?> createContextual(SerializerProvider prov, BeanProperty property) throws JsonMappingException {
if (property != null) {
Annotated annotated = property.getMember();
if (annotated instanceof AnnotatedField || annotated instanceof AnnotatedMethod) {
IndexableProperty indexableProperty = annotated.getAnnotation(IndexableProperty.class);
if (indexableProperty != null && !indexableProperty.format().isEmpty()) {
formatString = indexableProperty.format();
}
}
}
return this;
}
示例10: createContextual
import com.fasterxml.jackson.databind.BeanProperty; //導入方法依賴的package包/類
@Override
public JsonDeserializer<?> createContextual(DeserializationContext ctxt, BeanProperty property) throws JsonMappingException {
if (property != null) {
Annotated annotated = property.getMember();
if (annotated instanceof AnnotatedField || annotated instanceof AnnotatedMethod) {
IndexableProperty indexableProperty = annotated.getAnnotation(IndexableProperty.class);
if (indexableProperty != null && !indexableProperty.format().isEmpty()) {
formatString = indexableProperty.format();
}
}
}
return this;
}
示例11: createContextual
import com.fasterxml.jackson.databind.BeanProperty; //導入方法依賴的package包/類
public JsonSerializer<?> createContextual(SerializerProvider paramSerializerProvider, BeanProperty paramBeanProperty)
{
JsonSerializer localJsonSerializer1 = null;
JsonSerializer localJsonSerializer2 = null;
if (paramBeanProperty != null)
{
AnnotatedMember localAnnotatedMember = paramBeanProperty.getMember();
localJsonSerializer1 = null;
localJsonSerializer2 = null;
if (localAnnotatedMember != null)
{
AnnotationIntrospector localAnnotationIntrospector2 = paramSerializerProvider.getAnnotationIntrospector();
Object localObject2 = localAnnotationIntrospector2.findKeySerializer(localAnnotatedMember);
localJsonSerializer2 = null;
if (localObject2 != null)
localJsonSerializer2 = paramSerializerProvider.serializerInstance(localAnnotatedMember, localObject2);
Object localObject3 = localAnnotationIntrospector2.findContentSerializer(localAnnotatedMember);
localJsonSerializer1 = null;
if (localObject3 != null)
localJsonSerializer1 = paramSerializerProvider.serializerInstance(localAnnotatedMember, localObject3);
}
}
if (localJsonSerializer1 == null)
localJsonSerializer1 = this._valueSerializer;
JsonSerializer localJsonSerializer3 = findConvertingContentSerializer(paramSerializerProvider, paramBeanProperty, localJsonSerializer1);
JsonSerializer localJsonSerializer4 = localJsonSerializer3;
if (localJsonSerializer3 == null)
{
if (((this._valueTypeIsStatic) && (this._valueType.getRawClass() != Object.class)) || (hasContentTypeAnnotation(paramSerializerProvider, paramBeanProperty)))
localJsonSerializer4 = paramSerializerProvider.findValueSerializer(this._valueType, paramBeanProperty);
}
else if ((localJsonSerializer4 instanceof ContextualSerializer))
localJsonSerializer4 = ((ContextualSerializer)localJsonSerializer4).createContextual(paramSerializerProvider, paramBeanProperty);
if (localJsonSerializer2 == null)
localJsonSerializer2 = this._keySerializer;
if (localJsonSerializer2 == null)
localJsonSerializer2 = paramSerializerProvider.findKeySerializer(this._keyType, paramBeanProperty);
else if ((localJsonSerializer2 instanceof ContextualSerializer))
localJsonSerializer2 = ((ContextualSerializer)localJsonSerializer2).createContextual(paramSerializerProvider, paramBeanProperty);
Object localObject1 = this._ignoredEntries;
AnnotationIntrospector localAnnotationIntrospector1 = paramSerializerProvider.getAnnotationIntrospector();
if ((localAnnotationIntrospector1 != null) && (paramBeanProperty != null))
{
String[] arrayOfString = localAnnotationIntrospector1.findPropertiesToIgnore(paramBeanProperty.getMember());
if (arrayOfString != null)
{
HashSet localHashSet;
if (localObject1 == null)
localHashSet = new HashSet();
else
localHashSet = new HashSet((Collection)localObject1);
localObject1 = localHashSet;
int i = arrayOfString.length;
for (int j = 0; j < i; j++)
((HashSet)localObject1).add(arrayOfString[j]);
}
}
return withResolved(paramBeanProperty, localJsonSerializer2, localJsonSerializer4, (HashSet)localObject1);
}
示例12: createContextual
import com.fasterxml.jackson.databind.BeanProperty; //導入方法依賴的package包/類
public JsonDeserializer<?> createContextual(DeserializationContext paramDeserializationContext, BeanProperty paramBeanProperty)
{
ObjectIdReader localObjectIdReader = this._objectIdReader;
AnnotationIntrospector localAnnotationIntrospector = paramDeserializationContext.getAnnotationIntrospector();
AnnotatedMember localAnnotatedMember;
if ((paramBeanProperty == null) || (localAnnotationIntrospector == null))
localAnnotatedMember = null;
else
localAnnotatedMember = paramBeanProperty.getMember();
String[] arrayOfString = null;
if (paramBeanProperty != null)
{
arrayOfString = null;
if (localAnnotationIntrospector != null)
{
arrayOfString = localAnnotationIntrospector.findPropertiesToIgnore(localAnnotatedMember);
ObjectIdInfo localObjectIdInfo1 = localAnnotationIntrospector.findObjectIdInfo(localAnnotatedMember);
if (localObjectIdInfo1 != null)
{
ObjectIdInfo localObjectIdInfo2 = localAnnotationIntrospector.findObjectReferenceInfo(localAnnotatedMember, localObjectIdInfo1);
Class localClass = localObjectIdInfo2.getGeneratorType();
SettableBeanProperty localSettableBeanProperty1;
JavaType localJavaType2;
Object localObject;
if (localClass == ObjectIdGenerators.PropertyGenerator.class)
{
String str = localObjectIdInfo2.getPropertyName();
SettableBeanProperty localSettableBeanProperty2 = findProperty(str);
localSettableBeanProperty1 = localSettableBeanProperty2;
if (localSettableBeanProperty2 == null)
throw new IllegalArgumentException("Invalid Object Id definition for " + getBeanClass().getName() + ": can not find property with name '" + str + "'");
localJavaType2 = localSettableBeanProperty1.getType();
localObject = new PropertyBasedObjectIdGenerator(localObjectIdInfo2.getScope());
}
else
{
JavaType localJavaType1 = paramDeserializationContext.constructType(localClass);
localJavaType2 = paramDeserializationContext.getTypeFactory().findTypeParameters(localJavaType1, ObjectIdGenerator.class)[0];
localSettableBeanProperty1 = null;
localObject = paramDeserializationContext.objectIdGeneratorInstance(localAnnotatedMember, localObjectIdInfo2);
}
JsonDeserializer localJsonDeserializer = paramDeserializationContext.findRootValueDeserializer(localJavaType2);
localObjectIdReader = ObjectIdReader.construct(localJavaType2, localObjectIdInfo2.getPropertyName(), (ObjectIdGenerator)localObject, localJsonDeserializer, localSettableBeanProperty1);
}
}
}
BeanDeserializerBase localBeanDeserializerBase = this;
if ((localObjectIdReader != null) && (localObjectIdReader != this._objectIdReader))
localBeanDeserializerBase = localBeanDeserializerBase.withObjectIdReader(localObjectIdReader);
if ((arrayOfString != null) && (arrayOfString.length != 0))
localBeanDeserializerBase = localBeanDeserializerBase.withIgnorableProperties(ArrayBuilders.setAndArray(localBeanDeserializerBase._ignorableProps, arrayOfString));
JsonFormat.Shape localShape = null;
if (localAnnotatedMember != null)
{
JsonFormat.Value localValue = localAnnotationIntrospector.findFormat(localAnnotatedMember);
localShape = null;
if (localValue != null)
localShape = localValue.getShape();
}
if (localShape == null)
localShape = this._serializationShape;
if (localShape == JsonFormat.Shape.ARRAY)
localBeanDeserializerBase = localBeanDeserializerBase.asArrayDeserializer();
return localBeanDeserializerBase;
}