Skip to content
This repository has been archived by the owner on Apr 12, 2023. It is now read-only.

Commit

Permalink
Merge pull request #1133 from cocoa-mhlw/feature/disable-exposure-check
Browse files Browse the repository at this point in the history
接触確認の処理を実施しないようにする
  • Loading branch information
cocoa-dev004 authored Sep 13, 2022
2 parents 867ce4d + 8d9e8a6 commit a77e403
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 81 deletions.
37 changes: 0 additions & 37 deletions Covid19Radar/Covid19Radar.Android/MainApplication.cs
Original file line number Diff line number Diff line change
Expand Up @@ -151,42 +151,5 @@ public Task<ExposureConfiguration> GetExposureConfigurationAsync()
{
return Task.FromResult(new ExposureConfiguration());
}

public async Task PreExposureDetectedAsync(ExposureConfiguration exposureConfiguration)
{
long enVersion = await GetEnClient().GetVersionAsync();
_exposureDetectionService.Value.PreExposureDetected(exposureConfiguration, enVersion);
}

public async Task ExposureDetectedAsync(IList<DailySummary> dailySummaries, IList<ExposureWindow> exposureWindows, ExposureConfiguration exposureConfiguration)
{
long enVersion = await GetEnClient().GetVersionAsync();
await _exposureDetectionService.Value.ExposureDetectedAsync(exposureConfiguration, enVersion, dailySummaries, exposureWindows);
}

public async Task ExposureDetectedAsync(ExposureSummary exposureSummary, IList<ExposureInformation> exposureInformations, ExposureConfiguration exposureConfiguration)
{
long enVersion = await GetEnClient().GetVersionAsync();
await _exposureDetectionService.Value.ExposureDetectedAsync(exposureConfiguration, enVersion, exposureSummary, exposureInformations);
}

public async Task ExposureNotDetectedAsync(ExposureConfiguration exposureConfiguration)
{
long enVersion = await GetEnClient().GetVersionAsync();
await _exposureDetectionService.Value.ExposureNotDetectedAsync(exposureConfiguration, enVersion);
}

public Task ExceptionOccurredAsync(ENException exception)
{
_loggerService.Value.Exception($"ENExcepiton occurred, Code:{exception.Code}, Message:{exception.Message}", exception);
return Task.CompletedTask;
}

public Task ExceptionOccurredAsync(Exception exception)
{
_loggerService.Value.Exception("ENExcepiton occurred", exception);
return Task.CompletedTask;
}

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ public override Result DoWork()

try
{
backgroundService.ExposureDetectionAsync().GetAwaiter().GetResult();

return Result.InvokeSuccess();
}
catch (IOException exception)
Expand Down
42 changes: 0 additions & 42 deletions Covid19Radar/Covid19Radar.iOS/AppDelegate.cs
Original file line number Diff line number Diff line change
Expand Up @@ -292,48 +292,6 @@ public Task<ExposureConfiguration> GetExposureConfigurationAsync()
{
return Task.FromResult(new ExposureConfiguration());
}

public Task DiagnosisKeysDataMappingAppliedAsync()
{
_exposureDetectionService.Value.DiagnosisKeysDataMappingApplied();
return Task.CompletedTask;
}

public async Task PreExposureDetectedAsync(ExposureConfiguration exposureConfiguration)
{
long enVersion = await GetEnClient().GetVersionAsync();
_exposureDetectionService.Value.PreExposureDetected(exposureConfiguration, enVersion);
}

public async Task ExposureDetectedAsync(IList<DailySummary> dailySummaries, IList<ExposureWindow> exposureWindows, ExposureConfiguration exposureConfiguration)
{
long enVersion = await GetEnClient().GetVersionAsync();
await _exposureDetectionService.Value.ExposureDetectedAsync(exposureConfiguration, enVersion, dailySummaries, exposureWindows);
}

public async Task ExposureDetectedAsync(ExposureSummary exposureSummary, IList<ExposureInformation> exposureInformations, ExposureConfiguration exposureConfiguration)
{
long enVersion = await GetEnClient().GetVersionAsync();
await _exposureDetectionService.Value.ExposureDetectedAsync(exposureConfiguration, enVersion, exposureSummary, exposureInformations);
}

public async Task ExposureNotDetectedAsync(ExposureConfiguration exposureConfiguration)
{
long enVersion = await GetEnClient().GetVersionAsync();
await _exposureDetectionService.Value.ExposureNotDetectedAsync(exposureConfiguration, enVersion);
}

public Task ExceptionOccurredAsync(ENException exception)
{
_loggerService.Value.Exception($"ENExcepiton occurred, Code:{exception.Code}, Message:{exception.Message}", exception);
return Task.CompletedTask;
}

public Task ExceptionOccurredAsync(Exception exception)
{
_loggerService.Value.Exception("ENExcepiton occurred", exception);
return Task.CompletedTask;
}
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public override void Schedule()
{
try
{
await ExposureDetectionAsync(cancellationTokenSource);
task.SetTaskCompleted(true);
}
catch (OperationCanceledException exception)
Expand Down

0 comments on commit a77e403

Please sign in to comment.