Examples of invoke()


Examples of com.intellij.codeInsight.intention.IntentionAction.invoke()

  private void doTest(/*@Language("BNF")*/ String text, /*@Language("BNF")*/ String expected) throws IOException {
    myFixture.configureByText("a.bnf", text);
    IntentionAction action = new BnfFlipChoiceIntention();
    assertTrue("intention not available", action.isAvailable(getProject(), myFixture.getEditor(), myFixture.getFile()));
    action.invoke(getProject(), myFixture.getEditor(), myFixture.getFile());
    assertSameLines(expected, myFixture.getFile().getText());
  }
}
View Full Code Here

Examples of com.intellij.ide.util.gotoByName.ChooseByNamePopup.invoke()

        } else {
            GoToDatabaseObjectModel model = new GoToDatabaseObjectModel(project, connectionHandler, selectedSchema);
            String predefinedText = getPredefinedText(project);

            ChooseByNamePopup popup = ChooseByNamePopup.createPopup(project, model, getPsiContext(e), predefinedText);
            popup.invoke(new Callback(model), ModalityState.current(), false);
        }
    }

    private String getPredefinedText(Project project) {
        String predefinedText = null;
View Full Code Here

Examples of com.jacob.activeX.ActiveXComponent.invoke()

          + Dispatch.get(a1, "Value"));
      System.out.println("Retrieved a2 from excel:"
          + Dispatch.get(a2, "Value"));
      Variant f = new Variant(false);
      Dispatch.call(workbook, "Close", f);
      axc.invoke("Quit", new Variant[] {});

    } catch (ComException cfe) {
      cfe.printStackTrace();
      fail("Failed to attach to " + excelApplicationProgramId + ": "
          + cfe.getMessage());
View Full Code Here

Examples of com.java7developer.chapter5.ThreadPoolManager.CancelProxy.invoke()

  private void cancelUsingProxy(ScheduledFuture<?> hndl) {
    CancelProxy proxy = manager.makeProxy();

    System.out.println("With Proxy");
    proxy.invoke(manager, hndl);
  }

  private void cancelUsingMH(ScheduledFuture<?> hndl) {
    MethodHandle mh = manager.makeMh();
View Full Code Here

Examples of com.jetbrains.lang.dart.ide.refactoring.extract.DartExtractMethodHandler.invoke()

  }

  private void doTestImpl() {
    final DartExtractMethodHandler extractMethodHandler = new DartExtractMethodHandler();
    //noinspection NullableProblems
    extractMethodHandler.invoke(myFixture.getProject(), myFixture.getEditor(), myFixture.getFile(), null);
    myFixture.checkResultByFile(getTestName(true) + "_expected.dart");
  }

  public void testExtract1() throws Throwable {
    doTest();
View Full Code Here

Examples of com.jme3.app.AppTask.invoke()

        while (task != null) {
            while (task.isCancelled()) {
                task = pQueue.poll();
            }
            try {
                task.invoke();
            } catch (Exception ex) {
                logger.log(Level.SEVERE, null, ex);
            }
            task = pQueue.poll();
        }
View Full Code Here

Examples of com.linkedin.helix.participant.HelixCustomCodeRunner.invoke()

        {
          Thread.sleep(2000);
        }

        HelixCustomCodeRunner customCodeRunner = new HelixCustomCodeRunner(manager, ZK_ADDR);
        customCodeRunner.invoke(_callback)
                         .on(ChangeType.LIVE_INSTANCE)
                         .usingLeaderStandbyModel("TestParticLeader")
                         .start();
      } catch (Exception e)
      {
View Full Code Here

Examples of com.linkedin.restli.internal.server.RestLiMethodInvoker.invoke()

      expect(mockBuilder.buildArguments(requestData, routingResult)).andReturn(argsArray);
      expect(resource.get(eq(1L))).andReturn(null).once();
      mockCallback.onSuccess(eq(null), anyObject(RequestExecutionReport.class));
    }
    replay(resource, mockRegistry, mockBuilder, mockFilterContext, mockFilter, mockCallback);
    invokerWithFilters.invoke(routingResult, request, mockCallback, false, mockFilterContext);
    verify(resource, mockRegistry, mockBuilder, mockFilterContext, mockFilter);
    if (throwExceptionFromFirstFilter)
    {
      assertEquals(requestData.getKey(), "Key");
    }
View Full Code Here

Examples of com.m3.methodcache.interceptor.MemcachedCacheResultInterceptor.invoke()

  public void invoke_A$MethodInvocation() throws Throwable {
    MemcachedCacheResultInterceptor interceptor = new MemcachedCacheResultInterceptor();
    MethodInvocation invocation = mock(MethodInvocation.class);
        when(invocation.getMethod()).thenReturn(Foo.class.getDeclaredMethod("doSomething"));
        when(invocation.proceed()).thenReturn("foo");
    Object result = interceptor.invoke(invocation);
    Object expected = "foo";
    assertThat(result, is(equalTo(expected)));
  }

}
View Full Code Here

Examples of com.mxgraph.util.mxEventSource.mxIEventListener.invoke()

    view.getGraph().getView().addListener(mxEvent.SCALE, scaleTracker);
    view.getGraph().getView().addListener(mxEvent.SCALE_AND_TRANSLATE,
        scaleTracker);

    // Invokes once to sync with the actual zoom value
    scaleTracker.invoke(null, null);

    zoomCombo.addActionListener(new ActionListener()
    {
      /**
       *
 
View Full Code Here
TOP
Copyright © 2015 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.