Examples of invoke()


Examples of org.luaj.vm2.LuaValue.invoke()

  public void testLuaErrorCause() {
    String script = "luajava.bindClass( \""+SomeClass.class.getName()+"\"):someMethod()";
    LuaValue chunk = _G.get("loadstring").call(LuaValue.valueOf(script));
    try {
      chunk.invoke(LuaValue.NONE);
      fail( "call should not have succeeded" );
    } catch ( LuaError lee ) {
      Throwable c = lee.getCause();
      assertEquals( SomeException.class, c.getClass() );
    }
View Full Code Here

Examples of org.mc4j.ems.connection.bean.operation.EmsOperation.invoke()

                ((String)notifHash.get(NOTIFICATION_TYPE)),
                timestamp,
                EventSeverity.WARN,
                ((String)notifHash.get(NOTIFICATION_MESSAGE)));
              EmsOperation clear = emsbean.getOperation(CLEAR_ALERT_OPERATION);
              clear.invoke();
              events.add(event);
            }
           }
         } catch (Exception e) {
           e.printStackTrace();
View Full Code Here

Examples of org.milyn.scribe.reflection.EntityMethod.invoke()

  public Object update(final Object entity) {
    final EntityMethod method = daoRuntimeInfo.getDefaultUpdateMethod();

    assertMethod(method, Update.class);

    return method.invoke(dao, entity);
  }

  /* (non-Javadoc)
   * @see org.milyn.scribe.invoker.DaoInvoker#update(java.lang.String, java.lang.Object)
   */
 
View Full Code Here

Examples of org.milyn.scribe.reflection.FlushMethod.invoke()

  public void flush() {
    final FlushMethod method = daoRuntimeInfo.getFlushMethod();

    assertMethod(method, Flush.class);

    method.invoke(dao);
  }

  /* (non-Javadoc)
   * @see org.milyn.scribe.invoker.DAOInvoker#merge(java.lang.Object)
   */
 
View Full Code Here

Examples of org.milyn.scribe.reflection.LookupMethod.invoke()

    final LookupMethod method = daoRuntimeInfo.getLookupWithNamedParametersMethod(name);

    assertMethod(method, name, Lookup.class);

    return method.invoke(dao, parameters);

  }

  /* (non-Javadoc)
   * @see org.milyn.scribe.invoker.DAOInvoker#findBy(java.lang.String, java.util.Map)
View Full Code Here

Examples of org.milyn.scribe.reflection.LookupWithNamedQueryMethod.invoke()

    if(method == null) {
      throw new NoMethodWithAnnotationFoundException("No method found in DAO class '" + dao.getClass().getName() + "' that is annotated " +
          "with '" + LookupByQuery.class.getSimpleName() + "' annotation and has a Map argument for the named parameters.");
    }

    return method.invoke(dao, query, parameters);
  }

  /* (non-Javadoc)
   * @see org.milyn.scribe.invoker.DAOInvoker#findBy(java.lang.String, java.util.Map)
   */
 
View Full Code Here

Examples of org.milyn.scribe.reflection.LookupWithPositionalQueryMethod.invoke()

    if(method == null) {
      throw new NoMethodWithAnnotationFoundException("No method found in DAO class '" + dao.getClass().getName() + "' that is annotated " +
          "with '" + LookupByQuery.class.getSimpleName() + "' annotation and has an Array argument for the positional parameters.");
    }

    return method.invoke(dao, query, parameters);

  }

  /* (non-Javadoc)
   * @see org.milyn.scribe.invoker.DAOInvoker#findByQuery(java.lang.String, java.util.Map)
View Full Code Here

Examples of org.mockito.internal.invocation.realmethod.CleanTraceRealMethod.invoke()

                return new Foo().throwSomething();
            }});
       
        //when
        try {
            realMethod.invoke(null, null);
            fail();
        //then
        } catch (Exception e) {
            assertThat(e, hasMethodInStackTraceAt(0, "throwSomething"));
            assertThat(e, hasMethodInStackTraceAt(1, "invoke"));
View Full Code Here

Examples of org.mule.api.component.LifecycleAdapter.invoke()

    {
        LifecycleAdapter componentLifecycleAdapter = null;
        try
        {
            componentLifecycleAdapter = borrowComponentLifecycleAdaptor();
            return componentLifecycleAdapter.invoke(event);
        }
        finally
        {
            if (componentLifecycleAdapter != null)
            {
View Full Code Here

Examples of org.mule.api.model.EntryPointResolver.invoke()

    protected InvocationResult invokeResolver(String methodName, MuleEventContext eventContext) throws Exception
    {
        EntryPointResolver resolver = getResolver();
        eventContext.getMessage().setInvocationProperty(MuleProperties.MULE_METHOD_PROPERTY, methodName);
        InvocationResult result = resolver.invoke(getComponent(), eventContext);
        if (InvocationResult.State.SUCCESSFUL == result.getState())
        {
            assertNotNull("The result of invoking the component should not be null", result.getResult());
            assertNull(result.getErrorMessage());
            assertFalse(result.hasError());
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.