-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
Signed-off-by: Neil South <[email protected]>
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
/* | ||
* Copyright 2022 MONAI Consortium | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
using System; | ||
using System.Text.Json; | ||
using System.Text.Json.Serialization; | ||
|
||
namespace Monai.Deploy.InformaticsGateway.Common | ||
{ | ||
public class PatientDetails | ||
{ | ||
[JsonPropertyName("patient_id")] | ||
public string? PatientId { get; set; } | ||
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScu, ef)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebExport, ef)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / integration-test (AcrApi, ef)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / integration-test (Fhir, mongodb)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebStow, ef)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScp, ef)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / integration-test (HealthLevel7, mongodb)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / integration-test (RemoteAppExecutionPlugIn, mongodb)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebStow, mongodb)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / integration-test (HealthLevel7, ef)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebExport, mongodb)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / integration-test (RemoteAppExecutionPlugIn, ef)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / integration-test (Fhir, ef)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / integration-test (AcrApi, mongodb)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScu, mongodb)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScp, mongodb)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / build (ubuntu-latest)
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / analyze
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / unit-test
Check warning on line 26 in src/Common/PatientDetails.cs GitHub Actions / docs
|
||
|
||
[JsonPropertyName("patient_name")] | ||
public string? PatientName { get; set; } | ||
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScu, ef)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebExport, ef)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / integration-test (AcrApi, ef)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / integration-test (Fhir, mongodb)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebStow, ef)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScp, ef)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / integration-test (HealthLevel7, mongodb)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / integration-test (RemoteAppExecutionPlugIn, mongodb)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebStow, mongodb)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / integration-test (HealthLevel7, ef)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebExport, mongodb)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / integration-test (RemoteAppExecutionPlugIn, ef)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / integration-test (Fhir, ef)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / integration-test (AcrApi, mongodb)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScu, mongodb)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScp, mongodb)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / build (ubuntu-latest)
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / analyze
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / unit-test
Check warning on line 29 in src/Common/PatientDetails.cs GitHub Actions / docs
|
||
|
||
[JsonPropertyName("patient_sex")] | ||
public string? PatientSex { get; set; } | ||
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScu, ef)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebExport, ef)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / integration-test (AcrApi, ef)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / integration-test (Fhir, mongodb)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebStow, ef)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScp, ef)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / integration-test (HealthLevel7, mongodb)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / integration-test (RemoteAppExecutionPlugIn, mongodb)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebStow, mongodb)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / integration-test (HealthLevel7, ef)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebExport, mongodb)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / integration-test (RemoteAppExecutionPlugIn, ef)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / integration-test (Fhir, ef)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / integration-test (AcrApi, mongodb)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScu, mongodb)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScp, mongodb)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / build (ubuntu-latest)
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / analyze
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / unit-test
Check warning on line 32 in src/Common/PatientDetails.cs GitHub Actions / docs
|
||
|
||
[JsonPropertyName("patient_dob")] | ||
public DateTime? PatientDob { get; set; } | ||
|
||
[JsonPropertyName("patient_age")] | ||
public string? PatientAge { get; set; } | ||
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScu, ef)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebExport, ef)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / integration-test (AcrApi, ef)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / integration-test (Fhir, mongodb)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebStow, ef)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScp, ef)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / integration-test (HealthLevel7, mongodb)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / integration-test (RemoteAppExecutionPlugIn, mongodb)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebStow, mongodb)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / integration-test (HealthLevel7, ef)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebExport, mongodb)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / integration-test (RemoteAppExecutionPlugIn, ef)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / integration-test (Fhir, ef)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / integration-test (AcrApi, mongodb)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScu, mongodb)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScp, mongodb)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / build (ubuntu-latest)
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / analyze
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / unit-test
Check warning on line 38 in src/Common/PatientDetails.cs GitHub Actions / docs
|
||
|
||
[JsonPropertyName("patient_hospital_id")] | ||
public string? PatientHospitalId { get; set; } | ||
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScu, ef)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebExport, ef)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / integration-test (AcrApi, ef)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / integration-test (Fhir, mongodb)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebStow, ef)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScp, ef)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / integration-test (HealthLevel7, mongodb)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / integration-test (RemoteAppExecutionPlugIn, mongodb)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebStow, mongodb)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / integration-test (HealthLevel7, ef)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebExport, mongodb)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / integration-test (RemoteAppExecutionPlugIn, ef)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / integration-test (Fhir, ef)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / integration-test (AcrApi, mongodb)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScu, mongodb)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScp, mongodb)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / build (ubuntu-latest)
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / analyze
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / unit-test
Check warning on line 41 in src/Common/PatientDetails.cs GitHub Actions / docs
|
||
|
||
public override string ToString() | ||
{ | ||
return JsonSerializer.Serialize(this); | ||
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScu, ef)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebExport, ef)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / integration-test (AcrApi, ef)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / integration-test (Fhir, mongodb)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebStow, ef)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScp, ef)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / integration-test (HealthLevel7, mongodb)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / integration-test (RemoteAppExecutionPlugIn, mongodb)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebStow, mongodb)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / integration-test (HealthLevel7, ef)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomWebExport, mongodb)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / integration-test (RemoteAppExecutionPlugIn, ef)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / integration-test (Fhir, ef)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / integration-test (AcrApi, mongodb)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScu, mongodb)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / integration-test (DicomDimseScp, mongodb)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / build (ubuntu-latest)
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / analyze
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / unit-test
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / docs
Check warning on line 45 in src/Common/PatientDetails.cs GitHub Actions / CodeQL-Analyze
|
||
} | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
using System; | ||
using Microsoft.Extensions.Logging; | ||
|
||
namespace Monai.Deploy.InformaticsGateway.Logging | ||
{ | ||
public static partial class Log | ||
{ | ||
[LoggerMessage(EventId = 6000, Level = LogLevel.Error, Message = "Failed to get DICOM tag {dicomTag} in bucket {bucketId}. Payload: {payloadId}")] | ||
public static partial void FailedToGetDicomTagFromPayload(this ILogger logger, string payloadId, string dicomTag, string bucketId, Exception ex); | ||
|
||
[LoggerMessage(EventId = 6001, Level = LogLevel.Information, Message = "Attempted to retrieve Patient Name from DCM file, result: {name}")] | ||
public static partial void GetPatientName(this ILogger logger, string name); | ||
|
||
[LoggerMessage(EventId = 6002, Level = LogLevel.Information, Message = "Unsupported Type '{vr}' {vrFull} with value: {value} result: '{result}'")] | ||
public static partial void UnsupportedType(this ILogger logger, string vr, string vrFull, string value, string result); | ||
|
||
[LoggerMessage(EventId = 6003, Level = LogLevel.Information, Message = "Decoding supported type '{vr}' {vrFull} with value: {value} result: '{result}'")] | ||
public static partial void SupportedType(this ILogger logger, string vr, string vrFull, string value, string result); | ||
|
||
[LoggerMessage(EventId = 6004, Level = LogLevel.Error, Message = "Failed trying to cast Dicom Value to string {value}")] | ||
public static partial void UnableToCastDicomValueToString(this ILogger logger, string value, Exception ex); | ||
|
||
[LoggerMessage(EventId = 6005, Level = LogLevel.Debug, Message = "Dicom export marked as succeeded with {fileStatusCount} files marked as exported.")] | ||
public static partial void DicomExportSucceeded(this ILogger logger, string fileStatusCount); | ||
|
||
[LoggerMessage(EventId = 6006, Level = LogLevel.Debug, Message = "Dicom export marked as failed with {fileStatusCount} files marked as exported.")] | ||
public static partial void DicomExportFailed(this ILogger logger, string fileStatusCount); | ||
} | ||
} |