Package org.apache.tapestry5.ioc.services

Examples of org.apache.tapestry5.ioc.services.FieldValueConduit


    @Primary
    private StackTraceElementAnalyzer frameAnalyzer;

    void setupRender()
    {
        ExceptionAnalysis analysis = analyzer.analyze(exception);

        stack = analysis.getExceptionInfos();

        toggleId = renderSupport.allocateClientId("toggleStack");
    }
View Full Code Here


            public FieldConduit<Object> get(InstanceContext context)
            {
                ComponentResources resources = context.get(ComponentResources.class);

                FieldValueConduit fieldValueConduit = conduitProvider.get(resources);

                return toFieldConduit(fieldValueConduit);
            }
View Full Code Here

            public FieldConduit<?> get(InstanceContext context)
            {
                ComponentResources resources = context.get(ComponentResources.class);

                FieldValueConduit fieldValueConduit = conduitProvider.get(resources);

                return toFieldConduit(fieldValueConduit);
            }
View Full Code Here

    @SuppressWarnings("unchecked")
    private void transform(ClassTransformation transformation, TransformField field, final boolean create)
    {
        final Class fieldClass = componentClassCache.forName(field.getType());

        field.replaceAccess(new FieldValueConduit()
        {
            public void set(Object newValue)
            {
                applicationStateManager.set(fieldClass, newValue);
            }
View Full Code Here

        {
            final PersistenceContext annotation = field.getAnnotation(PersistenceContext.class);

            field.claim(annotation);

            field.replaceAccess(new FieldValueConduit()
            {

                public Object get()
                {
                    return JpaInternalUtils.getEntityManager(entityManagerManager, annotation);
View Full Code Here

    @SuppressWarnings("unchecked")
    private void transform(ClassTransformation transformation, TransformField field, final boolean create)
    {
        final Class fieldClass = componentClassCache.forName(field.getType());

        field.replaceAccess(new FieldValueConduit()
        {
            public void set(Object newValue)
            {
                applicationStateManager.set(fieldClass, newValue);
            }
View Full Code Here

    @Test
    public void unknown_validator_type()
    {
        ValidationMessagesSource messagesSource = mockValidationMessagesSource();
        Validator validator = mockValidator();
        TypeCoercer coercer = mockTypeCoercer();
        FieldComponent field = newFieldComponent();
        ComponentResources resources = mockComponentResources();
        Messages containerMessages = mockMessages();
        Map<String, Validator> map = newMap();
View Full Code Here

    @Test
    public void validator_with_no_constraint() throws Exception
    {
        ValidationMessagesSource messagesSource = mockValidationMessagesSource();
        Validator validator = mockValidator();
        TypeCoercer coercer = mockTypeCoercer();
        FieldComponent field = newFieldComponent();
        Messages messages = mockMessages();
        MessageFormatter formatter = mockMessageFormatter();
        Object inputValue = new Object();
        ComponentResources resources = mockComponentResources();
View Full Code Here

    @Test
    public void component_messages_overrides_validator_messages() throws Exception
    {
        ValidationMessagesSource messagesSource = mockValidationMessagesSource();
        Validator validator = mockValidator();
        TypeCoercer coercer = mockTypeCoercer();
        FieldComponent field = newFieldComponent();
        MessageFormatter formatter = mockMessageFormatter();
        Object inputValue = new Object();
        ComponentResources resources = mockComponentResources();
        Messages containerMessages = mockMessages();
View Full Code Here

    @Test
    public void component_messages_overrides_validator_messages_per_form() throws Exception
    {
        ValidationMessagesSource messagesSource = mockValidationMessagesSource();
        Validator validator = mockValidator();
        TypeCoercer coercer = mockTypeCoercer();
        FieldComponent field = newFieldComponent();
        MessageFormatter formatter = mockMessageFormatter();
        Object inputValue = new Object();
        ComponentResources resources = mockComponentResources();
        Messages containerMessages = mockMessages();
View Full Code Here

TOP

Related Classes of org.apache.tapestry5.ioc.services.FieldValueConduit

Copyright © 2018 www.massapicom. 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.