Package me.mabra.hellonzb.httpserver

Examples of me.mabra.hellonzb.httpserver.HelloNzbHttpSrvMgr


      yesQuit = true; // don't show popup, quit in any case
   
    if(yesQuit)
    {
      // shutdown built-in HTTP(S) server
      HelloNzbHttpSrvMgr httpServer = HelloNzbHttpSrvMgr.instance();
      if(httpServer != null)
        httpServer.shutdown();
     
      // shutdown task manager
      if(taskMgr != null)
        taskMgr.shutdown();
     
View Full Code Here


      String title = mainApp.getLocaler().getBundleText("PopupErrorTitle");
      JOptionPane.showMessageDialog(mainApp.getJFrame(), msg, title, JOptionPane.ERROR_MESSAGE);
      return;
    }

    HelloNzbHttpSrvMgr server = HelloNzbHttpSrvMgr.instance(logger);

    if(btn.isSelected())
    {
      // start built-in HTTP(S) server
      try
      {
        server.startServer(username, password, host, portNum, https);
      }
      catch(Exception ex)
      {
        server.shutdown();
       
        String msg = mainApp.getLocaler().getBundleText("PopupErrorFailedToStartHttpServer") + " " + ex.getMessage();
        String title = mainApp.getLocaler().getBundleText("PopupErrorTitle");
        JOptionPane.showMessageDialog(mainApp.getJFrame(), msg, title, JOptionPane.ERROR_MESSAGE);   
      }
    }
    else
    {
      // shutdown built-in HTTP(S) server
      server.shutdown();
    }
  }
View Full Code Here

TOP

Related Classes of me.mabra.hellonzb.httpserver.HelloNzbHttpSrvMgr

Copyright © 2018 www.massapicom. 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.