Examples of ValueEncoder


Examples of org.apache.tapestry5.ValueEncoder

        final ClassPropertyAdapter classPropertyAdapter = this.propertyAccess.getAdapter(object);

        final PropertyAdapter propertyAdapter = classPropertyAdapter
                .getPropertyAdapter(labelProperty);

        final ValueEncoder encoder = this.valueEncoderSource.getValueEncoder(propertyAdapter
                .getType());

        final Object label = propertyAdapter.get(object);

        return encoder.toClient(label);
    }
View Full Code Here

Examples of org.apache.tapestry5.ValueEncoder

        // Assumption: the field type is not one that's loaded by the component class loader, so it's safe
        // to convert to a hard type during class transformation.

        Class fieldType = classCache.forName(field.getTypeName());

        ValueEncoder encoder = valueEncoderSource.getValueEncoder(fieldType);

        FieldHandle handle = field.getHandle();

        String fieldName = String.format("%s.%s", field.getPlasticClass().getClassName(), field.getName());
View Full Code Here

Examples of org.apache.tapestry5.ValueEncoder

    public String toClient(Object value)
    {
        Defense.notNull(value, "value");

        ValueEncoder encoder = valueEncoderSource.getValueEncoder(value.getClass());

        return encoder.toClient(value);
    }
View Full Code Here

Examples of org.apache.tapestry5.ValueEncoder

public class ContextValueEncoderImplTest extends InternalBaseTestCase
{
    @Test
    public void to_client()
    {
        ValueEncoder valueEncoder = mockValueEncoder();
        ValueEncoderSource source = mockValueEncoderSource();

        Long value = 23L;
        String encoded = "twentythree";
View Full Code Here

Examples of org.apache.tapestry5.ValueEncoder


    @Test
    public void to_value()
    {
        ValueEncoder valueEncoder = mockValueEncoder();
        ValueEncoderSource source = mockValueEncoderSource();

        Long value = 23L;
        String clientValue = "twentythree";
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.