| 181 | |
| 182 | |
| 183 | bool ServerApplication::registerService(Exception& ex) { |
| 184 | WinService service(file().name()); |
| 185 | if (_displayName.empty()) |
| 186 | service.registerService(ex,file().path()); |
| 187 | else |
| 188 | service.registerService(ex, file().path(), _displayName); |
| 189 | if (ex) |
| 190 | return false; |
| 191 | if (_startup == "auto") |
| 192 | service.setStartup(ex,WinService::AUTO_START); |
| 193 | else if (_startup == "manual") |
| 194 | service.setStartup(ex,WinService::MANUAL_START); |
| 195 | if (!_description.empty()) |
| 196 | service.setDescription(ex, _description); |
| 197 | return true; |
| 198 | } |
| 199 | |
| 200 | |
| 201 | bool ServerApplication::unregisterService(Exception& ex) { |
nothing calls this directly
no test coverage detected