Ignore:
Timestamp:
Sep 20, 2018 3:20:39 AM (20 months ago)
Author:
meeh <meeh@…>
Branches:
master
Children:
85ebb2f
Parents:
3c0a8cf
Message:

Mac OS X Launcher: more cleanup and some bugfixes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • launchers/macosx/RouterTask.h

    r3c0a8cf re8decff5  
    33#include <dispatch/dispatch.h>
    44#include <memory.h>
    5 #include <string.h>
    65
    76#include <Cocoa/Cocoa.h>
     
    98
    109#ifdef __cplusplus
    11 #include "include/subprocess.hpp"
    12 
    13 using namespace subprocess;
    14 class JavaRunner;
    15 
    16 typedef std::function<void(void)> fp_t;
    17 typedef std::function<void(JavaRunner *ptr)> fp_proc_t;
     10#include <vector>
     11#include <string>
    1812
    1913const std::vector<NSString*> defaultStartupFlags {
     
    3125  "-Xms128m",
    3226  "-Djava.awt.headless=true"
    33 };
    34 
    35 /**
    36  *
    37  * class JavaRunner
    38  *
    39  **/
    40 class JavaRunner
    41 {
    42 public:
    43   // copy fn
    44   JavaRunner(std::string& javaBin, std::string& arguments, std::string& i2pBaseDir, const fp_proc_t& executingFn, const fp_t& cb);
    45   ~JavaRunner() = default;
    46  
    47   void requestRouterShutdown();
    48  
    49   std::future<int> execute();
    50   std::shared_ptr<subprocess::Popen> javaProcess;
    51   std::string javaBinaryPath;
    52   std::string javaRouterArgs;
    53   std::string execLine;
    54   std::string _i2pBaseDir;
    55 private:
    56   const fp_proc_t& executingFn;
    57   const fp_t& exitCallbackFn;
    5827};
    5928
Note: See TracChangeset for help on using the changeset viewer.