public async Task Connect(VpnConnectionRequest request) { Ensure.NotNull(request, nameof(request)); var contract = Map(request); await _vpnService.Connect(contract); }
private VpnConnectionRequestContract Map(VpnConnectionRequest request) { return(new VpnConnectionRequestContract { Servers = Map(request.Servers), Protocol = Map(request.Protocol), VpnConfig = Map(request.Config), Credentials = Map(request.Credentials), Settings = _settingsContractProvider.GetSettingsContract() }); }
public async Task Connect(VpnConnectionRequest connectionRequest) { await InvokeAction(() => _decorated.Connect(connectionRequest)); }