source: launchers/macosx/RouterTask.h @ 7a72049

Last change on this file since 7a72049 was 7a72049, checked in by meeh <meeh@…>, 23 months ago

Mac OS X Launcher:

  • Bugfixes as always
  • Added Sparkle (native updater, https://sparkle-project.org/ )
  • The launcher will now extract and overwrite older versions if found
  • Rewrite of the java extraction part (to enable overwrite)
  • Move more functionality to use EventManager? as it works quite well
  • Added check for updates menu item
  • Property mode set to 100644
File size: 1.2 KB
Line 
1#pragma once
2
3#include <dispatch/dispatch.h>
4#include <memory.h>
5
6#include <Cocoa/Cocoa.h>
7#import <AppKit/AppKit.h>
8
9#ifdef __cplusplus
10#include <vector>
11#include <string>
12
13const std::vector<NSString*> defaultStartupFlags {
14  @"-Xmx512M",
15  @"-Xms128m",
16  @"-Djava.awt.headless=true",
17  @"-Dwrapper.logfile=/tmp/router.log",
18  @"-Dwrapper.logfile.loglevel=DEBUG",
19  @"-Dwrapper.java.pidfile=/tmp/routerjvm.pid",
20  @"-Dwrapper.console.loglevel=DEBUG"
21};
22
23const std::vector<std::string> defaultFlagsForExtractorJob {
24  "-Xmx512M",
25  "-Xms128m",
26  "-Djava.awt.headless=true"
27};
28
29#endif
30
31
32@class RTaskOptions;
33@interface RTaskOptions : NSObject
34@property (strong) NSString* binPath;
35@property (strong) NSArray<NSString *>* arguments;
36@property (strong) NSString* i2pBaseDir;
37@end
38
39@class I2PRouterTask;
40@interface I2PRouterTask : NSObject
41@property (strong) NSTask* routerTask;
42@property (strong) NSPipe *processPipe;
43@property (atomic) BOOL isRouterRunning;
44@property (atomic) BOOL userRequestedRestart;
45- (instancetype) initWithOptions : (RTaskOptions*) options;
46- (int) execute;
47- (void) requestShutdown;
48- (void) requestRestart;
49- (BOOL) isRunning;
50- (int) getPID;
51- (void)routerStdoutData:(NSNotification *)notification;
52@end
53
54
55
56
57
58
Note: See TracBrowser for help on using the repository browser.