Examples of Action


Examples of org.jmock.api.Action

            one(standardOutputCaptureMock).start();
            inSequence(sequence);

            one(scriptMock).run();
            inSequence(sequence);
            will(doAll(new Action() {
                public void describeTo(Description description) {
                    description.appendValue("check context classloader");
                }

                public Object invoke(Invocation invocation) throws Throwable {
View Full Code Here

Examples of org.jrest4guice.dao.actions.Action

    return (T) Proxy.newProxyInstance(daoClazz.getClassLoader(), new Class[] { daoClazz }, this);
  }

  @SuppressWarnings("unchecked")
  public Object invoke(Object proxy, Method method, Object[] args) throws Throwable {
    Action action = getAction(method);
    if (action == null) {
      String msg = "无法获取" + proxy.getClass() + "." + method.getName() + "方法声明的Action实例。";
      log.error(msg);
      throw new RejectedExecutionException(msg);
    } else {
      ActionContext context = action.getContext();
      context.setAction(action);
      return context.execute(method, args);
    }
  }
View Full Code Here

Examples of org.jwall.app.Action

  public PolicyEditorView(Application app) {
    super(app);
    setLayout(new BorderLayout());

    actions.add(new Action(this, Action.NEW_FILE, "File/New", 10.0d, true,
        true, KeyStroke.getKeyStroke(KeyEvent.VK_N, Toolkit
            .getDefaultToolkit().getMenuShortcutKeyMask())));
    actions.add(new Action(this, Action.LOAD_FILE, "File/Open", 20.0d,
        true, true, KeyStroke.getKeyStroke(KeyEvent.VK_O, Toolkit
            .getDefaultToolkit().getMenuShortcutKeyMask())));

    actions.add(new Action(this, Action.SAVE_FILE, "File/Save", 30.0d,
        true, false, KeyStroke.getKeyStroke(KeyEvent.VK_S, Toolkit
            .getDefaultToolkit().getMenuShortcutKeyMask())));
    actions.add(new Action(this, Action.SAVE_AS_FILE, "File/Save As",
        40.0d, false, false));

    actions.add(new Action(this, CompilerAction.COMPILE_PROFILE,
        "Policy/Compile", 10.0d, true, file != null));

    rtview = new ResourceTreeView();
    ctview = new ClassTreeView();
    ptListView = new ParameterTypeListView();
View Full Code Here

Examples of org.jwildfire.script.Action

  public void revertScriptAction() {
    String actionStr = null;
    int row = actionTable.getSelectedRow();
    if ((row >= 0) && (row < actionList.size())) {
      Action action = actionList.get(row);
      StringBuffer b = new StringBuffer();
      action.saveToBuffer(b, "\n");
      actionStr = b.toString();
      envelopeController.setCurrAction(action);
    }
    else {
      envelopeController.setCurrAction(null);
View Full Code Here

Examples of org.mojavemvc.annotations.Action

        for (int i = 0; i < methods.length; i++) {

            Annotation ann = methods[i].getAnnotation(Action.class);
            if (ann != null) {
                Action actionAnn = (Action) ann;
                String action = actionAnn.value();
                if (action == null || action.trim().length() == 0) {
                    /*
                     * if no value is provided in the annotation, map the action
                     * to its method name
                     */
 
View Full Code Here

Examples of org.mokai.Action

        return;
      }

      // retrieve the action
      Action action = actions.get(index);

      // inject the Execution interface implementation (ie. an instance of this class)
      ActionsExecutor executor = new ActionsExecutor(producerTemplate, index + 1);
      ResourceInjector.inject(action, executor);

      // execute the message, notice that the execution could be stopped or new messages routed
      action.execute(message);

      // if the action stopped the execution ...
      if (executor.isStopped()) {
        return;
      }
View Full Code Here

Examples of org.nasutekds.guitools.controlpanel.datamodel.Action

           * {@inheritDoc}
           */
          public void actionPerformed(ActionEvent ev)
          {
            // Constructs the panels using reflection.
            Action action = b.getActionObject();
            GenericFrame frame = frames.get(action);
            if (frame == null)
            {
              Class<? extends StatusGenericPanel> panelClass =
                action.getAssociatedPanelClass();
              try
              {
                Constructor<? extends StatusGenericPanel> constructor =
                  panelClass.getDeclaredConstructor();
                StatusGenericPanel panel = constructor.newInstance();
View Full Code Here

Examples of org.netbeans.jemmy.Action

     */

    public void scrollTo(final ScrollAdjuster adj) {

  produceTimeRestricted(new Action() {

    public Object launch(Object obj) {

        driver.scroll(ScrollPaneOperator.this, adj);

View Full Code Here

Examples of org.nfctools.ndef.wkt.records.Action

public class ActionRecordDecoder implements WellKnownRecordPayloadDecoder {

  @Override
  public WellKnownRecord decodePayload(byte[] payload, NdefMessageDecoder messageDecoder) {
    Action action = Action.getActionByValue(payload[0]);
    return new ActionRecord(action);
  }
View Full Code Here

Examples of org.ogce.schemas.gfac.inca.faults.ActionDocument.Action

    public void setFaultCode(String faultCode) {
        this.faultCode = faultCode;
    }
    public ActionDocument createFaultData(XmlObject fault,String api,Throwable e){
        ActionDocument document = ActionDocument.Factory.newInstance();
        Action type = document.addNewAction();
        type.setId("");
        type.setApplication("lead");
        type.setApi(api);
       
        if(fault instanceof DataTransfer){
            type.setDataTransferArray(new DataTransfer[]{(DataTransfer)fault});
        }else if(fault instanceof Job){
            type.setJobArray(new Job[]{(Job)fault});
        }else if(fault instanceof Job){
            type.setFileSystemArray(new FileSystem[]{(FileSystem)fault});
        }else if(fault instanceof Application){
            type.setCmdapplicationArray(new Application[]{(Application)fault});           
        }
        type.setEndTime(formatter.format(new Date()));
        Throwable cause = e;
        while(cause.getCause() != null){
            cause = cause.getCause();
        }
        return document;
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.