Examples of CallbackWireObjectFactory


Examples of org.apache.tuscany.sca.core.invocation.CallbackWireObjectFactory

                        businessInterface =
                            JavaIntrospectionHelper.getBusinessInterface(element.getType(), element.getGenericType());
                        factory =
                            new CallbackReferenceObjectFactory(businessInterface, proxyFactory, wires);
                    } else {
                        factory = new CallbackWireObjectFactory(businessInterface, proxyFactory, wires);
                    }
                    if (!(element.getAnchor() instanceof Constructor)) {
                        callbackInjectionList.add(element);
                    }
                    instanceFactoryProvider.setObjectFactory(element, factory);
View Full Code Here

Examples of org.apache.tuscany.sca.core.invocation.CallbackWireObjectFactory

        Foo foo = new Foo() {
        };
        EasyMock.expect(service.createCallbackProxy(EasyMock.eq(Foo.class), EasyMock.isA(List.class))).andReturn(foo);
        EasyMock.replay(service);
        List<RuntimeWire> wires = new ArrayList<RuntimeWire>();
        CallbackWireObjectFactory factory = new CallbackWireObjectFactory(Foo.class, service, wires);
        assertEquals(foo, factory.getInstance());
        EasyMock.verify(service);
    }
View Full Code Here

Examples of org.apache.tuscany.sca.core.invocation.CallbackWireObjectFactory

                    // this can happen when there are no client wires to a
                    // component that has a callback
                    continue;
                }
                for(JavaElementImpl element : entry.getValue()) {
                    ObjectFactory<?> factory = new CallbackWireObjectFactory(element.getType(), proxyFactory, wires);
                    if (!(element.getAnchor() instanceof Constructor)) {
                        injectionSites.add(element);
                    }
                    factories.put(element, factory);
                }
View Full Code Here

Examples of org.apache.tuscany.sca.core.invocation.CallbackWireObjectFactory

                    // this can happen when there are no client wires to a
                    // component that has a callback
                    continue;
                }
                JavaElementImpl element = entry.getValue();
                ObjectFactory<?> factory = new CallbackWireObjectFactory(element.getType(), proxyService, wires);
                if (!(element.getAnchor() instanceof Constructor)) {
                    configuration.getInjectionSites().add(element);
                }
                configuration.setObjectFactory(element, factory);
            }
View Full Code Here

Examples of org.apache.tuscany.sca.core.invocation.CallbackWireObjectFactory

                        businessInterface =
                            JavaIntrospectionHelper.getBusinessInterface(element.getType(), element.getGenericType());
                        factory =
                            new CallbackReferenceObjectFactory(businessInterface, proxyFactory, wires);
                    } else {
                        factory = new CallbackWireObjectFactory(businessInterface, proxyFactory, wires);
                    }
                    if (!(element.getAnchor() instanceof Constructor)) {
                        instanceFactoryProvider.getInjectionSites().add(element);
                    }
                    instanceFactoryProvider.setObjectFactory(element, factory);
View Full Code Here

Examples of org.apache.tuscany.sca.core.invocation.CallbackWireObjectFactory

            return null;
        }
        JavaInterface javaInterface = (JavaInterface) callbackReference.getInterfaceContract().getInterface();
        Class<CB> javaClass = (Class<CB>)javaInterface.getJavaClass();
        List<RuntimeWire> wires = callbackReference.getRuntimeWires();
        CallbackWireObjectFactory factory = new CallbackWireObjectFactory(javaClass, proxyFactory, wires);
        factory.resolveTarget();
        factory.attachCallbackID(ThreadMessageContext.getMessageContext().getCorrelationID());
        return factory;
    }
View Full Code Here

Examples of org.apache.tuscany.sca.core.invocation.CallbackWireObjectFactory

                    // this can happen when there are no client wires to a
                    // component that has a callback
                    continue;
                }
                JavaElementImpl element = entry.getValue();
                ObjectFactory<?> factory = new CallbackWireObjectFactory(element.getType(), proxyFactory, wires);
                if (!(element.getAnchor() instanceof Constructor)) {
                    instanceFactoryProvider.getInjectionSites().add(element);
                }
                instanceFactoryProvider.setObjectFactory(element, factory);
            }
View Full Code Here

Examples of org.apache.tuscany.sca.core.invocation.CallbackWireObjectFactory

                        businessInterface =
                            JavaIntrospectionHelper.getBusinessInterface(element.getType(), element.getGenericType());
                        factory =
                            new CallbackReferenceObjectFactory(businessInterface, proxyFactory, wires);
                    } else {
                        factory = new CallbackWireObjectFactory(businessInterface, proxyFactory, wires);
                    }
                    if (!(element.getAnchor() instanceof Constructor)) {
                        instanceFactoryProvider.getInjectionSites().add(element);
                    }
                    instanceFactoryProvider.setObjectFactory(element, factory);
View Full Code Here

Examples of org.apache.tuscany.sca.core.invocation.CallbackWireObjectFactory

                        businessInterface =
                            JavaIntrospectionHelper.getBusinessInterface(element.getType(), element.getGenericType());
                        factory =
                            new CallbackReferenceObjectFactory(businessInterface, proxyFactory, wires);
                    } else {
                        factory = new CallbackWireObjectFactory(businessInterface, proxyFactory, wires);
                    }
                    if (!(element.getAnchor() instanceof Constructor)) {
                        callbackInjectionList.add(element);
                    }
                    instanceFactoryProvider.setObjectFactory(element, factory);
View Full Code Here

Examples of org.apache.tuscany.sca.core.invocation.CallbackWireObjectFactory

                    // this can happen when there are no client wires to a
                    // component that has a callback
                    continue;
                }
                JavaElementImpl element = entry.getValue();
                ObjectFactory<?> factory = new CallbackWireObjectFactory(element.getType(), proxyService, wires);
                if (!(element.getAnchor() instanceof Constructor)) {
                    configuration.getInjectionSites().add(element);
                }
                configuration.setObjectFactory(element, factory);
            }
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.