Examples of Invokable


Examples of org.apache.tapestry5.ioc.Invokable

    @Test
    public void exception_thrown_by_invocation()
    {
        ParallelExecutor parallelExecutor = getService(ParallelExecutor.class);

        Invokable inv = new Invokable()
        {
            public Object invoke()
            {
                throw new RuntimeException("Future failure!");
            }
View Full Code Here

Examples of org.apache.tapestry5.ioc.Invokable

        expect(resources.invoke(EasyMock.isA(String.class), EasyMock.isA(Invokable.class))).andAnswer(new IAnswer<Object>()
        {
            public Object answer() throws Throwable
            {
                Invokable inv = (Invokable) EasyMock.getCurrentArguments()[1];

                return inv.invoke();
            }
        });

        return resources;
    }
View Full Code Here

Examples of org.apache.tapestry5.ioc.Invokable

        expect(resources.invoke(EasyMock.isA(String.class), EasyMock.isA(Invokable.class))).andAnswer(new IAnswer<Object>()
        {
            public Object answer() throws Throwable
            {
                Invokable inv = (Invokable) EasyMock.getCurrentArguments()[1];

                return inv.invoke();
            }
        });

        return resources;
    }
View Full Code Here

Examples of org.jmock.api.Invokable

    private Invocation invocation;


    @Before
    public void setUp() throws Exception {
        invokable = new Invokable() {
            @Override
            public Object invoke(Invocation invocation) throws Throwable {
                JavassistImposteriserTest.this.invocation = invocation;
                return "result";
            }
View Full Code Here

Examples of org.jmock.api.Invokable


    // See issue JMOCK-256 (Github #36)
    @Test
    public void doesntDelegateFinalizeMethod() throws Exception {
        Invokable failIfInvokedAction = new Invokable() {
            @Override
            public Object invoke(Invocation invocation) throws Throwable {
                fail("invocation should not have happened");
                return null;
            }
View Full Code Here

Examples of org.jmock.api.Invokable

        }

    }

    public Invokable synchroniseAccessTo(final Invokable mockObject) {
        return new Invokable() {
            public Object invoke(Invocation invocation) throws Throwable {
                return synchroniseInvocation(mockObject, invocation);
            }
        };
    }
View Full Code Here

Examples of r.ifc.Interop.Invokable

* Interface to the rest of the Java world. This class supports the registration of Java methods as R functions.
**/
public class Interop {

    public static void initialize() {
        register(new Invokable() {
            public String name() {
                return "jan";
            }

            public String[] parameters() {
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.