Examples of execute()


Examples of com.opengamma.util.db.tool.DbTool.execute()

    dbTool.setUser(props.getProperty(DB_USERNAME_KEY, ""));
    dbTool.setPassword(props.getProperty(DB_PASSWORD_KEY, ""));
    dbTool.setCreate(true);
    dbTool.setDrop(true);
    dbTool.setCreateTables(true);
    dbTool.execute();
  }

  private static Properties loadProperties(String configResourceLocation) throws IOException {
    Resource resource = ResourceUtils.createResource(configResourceLocation);
    Properties props = new Properties();
View Full Code Here

Examples of com.opengamma.util.db.tool.DbUpgradeOperation.execute()

  //-------------------------------------------------------------------------
  @Override
  protected void doRun(boolean write, File outputFile) throws Exception {
    DbUpgradeOperation upgradeOp = new DbUpgradeOperation(getDbToolContext(), write, outputFile);
    upgradeOp.execute();
    if (!upgradeOp.isUpgradeRequired()) {
      System.out.println("Database up-to-date");
    }
  }
 
View Full Code Here

Examples of com.opensymphony.xwork.ActionProxy.execute()

            contextMap.put(PORTLET_DISPATCHER, this);

            try {
                ActionProxy proxy = ActionProxyFactory.getFactory().createActionProxy(nameSpace, actionName, contextMap);
                proxy.execute();
                PortletContext.getContext().setActionExecuted(null);

            } catch (Throwable e) {
                e.printStackTrace();
            }
View Full Code Here

Examples of com.opensymphony.xwork.Result.execute()

            // if the ActionMapping says to go straight to a result, do it!
            if (mapping.getResult() != null)
            {
                Result result = mapping.getResult();
                result.execute(proxy.getInvocation());
            }
            else
            {
                proxy.execute();
            }
View Full Code Here

Examples of com.opensymphony.xwork2.ActionProxy.execute()

        HashMap<String, Object> extraContext = new HashMap<String, Object>();
        extraContext.put(ActionContext.PARAMETERS, params);

        ActionProxy proxy = actionProxyFactory.createActionProxy("", MockConfigurationProvider.MODEL_DRIVEN_PARAM_TEST, extraContext);
        assertEquals(Action.SUCCESS, proxy.execute());

        ModelDrivenAction action = (ModelDrivenAction) proxy.getAction();
        TestBean model = (TestBean) action.getModel();

        String property = System.getProperty("xwork.security.test");
View Full Code Here

Examples of com.opensymphony.xwork2.Result.execute()

        ctx.put(ServletActionContext.HTTP_REQUEST, request);
        StrutsMockHttpServletResponse response = new StrutsMockHttpServletResponse();
        ctx.put(ServletActionContext.HTTP_RESPONSE, response);
        invMock.expectAndReturn("getInvocationContext", ctx);
        invMock.expectAndReturn("getStack", ctx.getValueStack());
        result.execute(inv);
        assertEquals("http://www.google.com", response.getRedirectURL());
        //TODO: need to test location but there's noaccess to the property/method, unless we use reflection
    }

    public void testRedirectActionPrefix() throws Exception {
View Full Code Here

Examples of com.orientechnologies.orient.core.command.OCommandExecutor.execute()

  public Object command(final OCommandRequestText iCommand) {
    final OCommandExecutor executor = OCommandManager.instance().getExecutor(iCommand);
    executor.setProgressListener(iCommand.getProgressListener());
    executor.parse(iCommand);
    try {
      return executor.execute(iCommand.getParameters());
    } catch (OException e) {
      // PASS THROUGHT
      throw e;
    } catch (Exception e) {
      throw new OCommandExecutionException("Error on execution of command: " + iCommand, e);
View Full Code Here

Examples of com.orientechnologies.orient.core.command.OCommandRequest.execute()

          cmd += "create edge from $a to " + superNode.getIdentity() + ";";
          cmd += "commit retry " + MAX_RETRIES + ";";
          cmd += "return $transactionRetries;";

          final OCommandRequest command = graph.command(new OCommandScript("sql", cmd));
          final Object res = command.execute();
          if (res instanceof Integer) {
            int retries = (Integer) res;

            counter.incrementAndGet();
View Full Code Here

Examples of com.orientechnologies.orient.core.command.OCommandRequestText.execute()

    // final OCommandRequestText cmd = iReadOnly ? new OSQLSynchQuery<OIdentifiable>(command.toString()) : new OCommandSQL(
    // command.toString());

    final String returnVariable = getFieldOfClass(iContext, iConfig, "return", String.class);
    if (returnVariable != null) {
      final List<?> result = cmd.execute();
      debug(iContext, "Returned %d records", result.size());
      return result;
    }

    return cmd;
View Full Code Here

Examples of com.orientechnologies.orient.core.command.script.OCommandExecutorScript.execute()

    final OCommandExecutorScript cmd = new OCommandExecutorScript();
    cmd.parse(new OCommandScript("Javascript", iText));

    long start = System.currentTimeMillis();

    final Object result = cmd.execute(null);

    float elapsedSeconds = getElapsedSecs(start);

    if (OMultiValue.isMultiValue(result)) {
      if (result instanceof List<?>)
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.