Sha256: 86094a5e9170203b0e9ce4ae30fe4de6524098c95f4fa38e2d4826e5748f4e2b

Contents?: true

Size: 1.42 KB

Versions: 164

Compression:

Stored size: 1.42 KB

Contents

package sh.calaba.org.codehaus.jackson.map.deser.impl;

import java.io.IOException;

import sh.calaba.org.codehaus.jackson.map.BeanProperty;
import sh.calaba.org.codehaus.jackson.map.DeserializationContext;
import sh.calaba.org.codehaus.jackson.map.introspect.AnnotatedMember;
import sh.calaba.org.codehaus.jackson.map.util.Annotations;
import sh.calaba.org.codehaus.jackson.type.JavaType;

/**
 * Class that encapsulates details of value injection that occurs before
 * deserialization of a POJO. Details include information needed to find
 * injectable value (logical id) as well as method used for assigning
 * value (setter or field)
 * 
 * @since 1.9
 */
public class ValueInjector
    extends BeanProperty.Std
{
    /**
     * Identifier used for looking up value to inject
     */
    protected final Object _valueId;

    public ValueInjector(String propertyName, JavaType type,
            Annotations contextAnnotations, AnnotatedMember mutator,
            Object valueId)
    {
        super(propertyName, type, contextAnnotations, mutator);
        _valueId = valueId;
    }

    public Object findValue(DeserializationContext context, Object beanInstance)
    {
        return context.findInjectableValue(_valueId, this, beanInstance);
    }
    
    public void inject(DeserializationContext context, Object beanInstance)
        throws IOException
    {
        _member.setValue(beanInstance, findValue(context, beanInstance));
    }
}

Version data entries

164 entries across 164 versions & 2 rubygems

Version Path
calabash-android-0.4.20.1 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.5.2 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.5.2.pre1 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.5.1 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.5.0 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.5.0.pre2 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.5.0.pre1 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.4.22.pre4 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.4.22.pre3 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.4.22.pre1 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.4.21 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.4.20 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.4.19 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.4.19.pre4 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.4.19.pre3 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.4.19.pre2 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.4.19.pre1 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.4.18 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.4.16 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java
calabash-android-0.4.15.pre2 test-server/instrumentation-backend/src/sh/calaba/org/codehaus/jackson/map/deser/impl/ValueInjector.java