Tabnine Logo
ConnectionManager.connectTo
Code IndexAdd Tabnine to your IDE (free)

How to use
connectTo
method
in
org.netbeans.modules.nativeexecution.api.util.ConnectionManager

Best Java code snippets using org.netbeans.modules.nativeexecution.api.util.ConnectionManager.connectTo (Showing top 7 results out of 315)

origin: org.netbeans.modules/org-netbeans-modules-cnd-makeproject

  @Override
  public void run() {
    try {
      ConnectionManager.getInstance().connectTo(env);
      ServerRecord rec = ServerList.get(env);
      if (rec != null) {
        rec.checkSetupAfterConnection(null);
      }                            
    } catch (IOException ex) {
    } catch (CancellationException ex) {
      // don't log CancellationException
    }
  }
});
origin: org.netbeans.modules/org-netbeans-modules-cnd-makeproject

  ConnectionManager.getInstance().connectTo(execEnv);
} catch (IOException e) {
  e.printStackTrace(System.err);
origin: org.netbeans.modules/org-netbeans-modules-cnd

protected static boolean checkConnection(ExecutionEnvironment execEnv) {
  if (execEnv.isRemote()) {
    try {
      ConnectionManager.getInstance().connectTo(execEnv);
      ServerRecord record = ServerList.get(execEnv);
      if (record.isOffline()) {
        record.validate(true);
      }
      return record.isOnline();
    } catch (IOException ex) {
      return false;
    } catch (CancellationException ex) {
      return false;
    }
  } else {
    return true;
  }
}
origin: org.netbeans.modules/org-netbeans-modules-cnd-makeproject

public static boolean checkConnection(ExecutionEnvironment execEnv) {
  if (execEnv.isRemote()) {
    try {
      ConnectionManager.getInstance().connectTo(execEnv);
      ServerRecord record = ServerList.get(execEnv);
      if (record.isOffline()) {
        record.validate(true);
      }
      return record.isOnline();
    } catch (IOException ex) {
      return false;
    } catch (CancellationException ex) {
      return false;
    }
  } else {
    return true;
  }
}
origin: org.netbeans.modules/org-netbeans-modules-cnd-makeproject

try {
  if (!ConnectionManager.getInstance().isConnectedTo(execEnv)) {
    ConnectionManager.getInstance().connectTo(execEnv);
origin: org.netbeans.modules/org-netbeans-modules-cnd-makeproject

  @Override
  public void runImpl() {
    try {
      if (!ConnectionManager.getInstance().isConnectedTo(record.getExecutionEnvironment())) {
        ConnectionManager.getInstance().connectTo(record.getExecutionEnvironment());
      }
      record.validate(true);
      // initialize compiler sets for remote host if needed
      CompilerSetManager csm = CompilerSetManager.get(record.getExecutionEnvironment());
      csm.initialize(true, true, null);
    } catch (CancellationException ex) {
      cancel();
    } catch (Exception e) {
      e.printStackTrace(System.err);
      final String message = MessageFormat.format(getString("ERR_Cant_Connect"), record.getDisplayName()); //NOI18N
      final String title = getString("DLG_TITLE_Cant_Connect"); //NOI18N
      SwingUtilities.invokeLater(new Runnable() {
        @Override
        public void run() {
          JOptionPane.showMessageDialog(WindowManager.getDefault().getMainWindow(),
              message, title, JOptionPane.ERROR_MESSAGE);
        }
      });
    }
    if (record.isOnline()) {
      actionWorker.run();
    }
  }
};
origin: org.netbeans.modules/org-netbeans-modules-cnd

} else {
  try {
    ConnectionManager.getInstance().connectTo(execEnv);
  } catch (IOException ex) {
    StatusDisplayer.getDefault().setStatusText(NbBundle.getMessage(CompileAction.class, "Status.Error", execEnv.getDisplayName(), ex.getLocalizedMessage()));
org.netbeans.modules.nativeexecution.api.utilConnectionManagerconnectTo

Popular methods of ConnectionManager

  • getInstance
  • isConnectedTo
  • connect
  • getConnectToAction
  • addConnectionListener

Popular in Java

  • Making http requests using okhttp
  • getResourceAsStream (ClassLoader)
  • scheduleAtFixedRate (ScheduledExecutorService)
  • compareTo (BigDecimal)
  • RandomAccessFile (java.io)
    Allows reading from and writing to a file in a random-access manner. This is different from the uni-
  • Enumeration (java.util)
    A legacy iteration interface.New code should use Iterator instead. Iterator replaces the enumeration
  • ExecutorService (java.util.concurrent)
    An Executor that provides methods to manage termination and methods that can produce a Future for tr
  • Semaphore (java.util.concurrent)
    A counting semaphore. Conceptually, a semaphore maintains a set of permits. Each #acquire blocks if
  • Manifest (java.util.jar)
    The Manifest class is used to obtain attribute information for a JarFile and its entries.
  • LoggerFactory (org.slf4j)
    The LoggerFactory is a utility class producing Loggers for various logging APIs, most notably for lo
  • CodeWhisperer alternatives
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now