=== Summary: 675 files | 7 generated | 484 fresh | 4605 untracked | 4268 adopted | 355 marked | 466 validated-ok | 2+0 stale (sig+body) | 0 skipped | 0 failed | elapsed 11:08:11.442 (40091.44s) ===

This commit is contained in:
julian
2026-06-28 02:50:05 -07:00
parent a19fb90902
commit 586f02a2ca
654 changed files with 5260 additions and 0 deletions
@@ -13,18 +13,21 @@ public interface ICalculatedObservations
/// <param name="obs">The source patient observation to be mapped.</param>
/// <param name="onlyByName">When set to <c>true</c>, the mapping is performed considering only the observation name; otherwise, additional mapping criteria are applied. Defaults to <c>false</c>.</param>
/// <returns>A <see cref="Task{T}"/> that represents the asynchronous mapping operation. The result is the mapped observation of type <typeparamref name="T"/>, or <c>null</c> when no matching mapping is found.</returns>
/// <!-- aidoc:v1 sig=7c2c1e5 -->
Task<T?> Map<T>(T obs, bool onlyByName = false) where T : BasePatientObservation;
/// <summary>
/// Asynchronously maps the specified <paramref name="treatment"/> to a <see cref="PatientTreatment"/> result.
/// </summary>
/// <param name="treatment">The patient treatment instance to map.</param>
/// <returns>A task that represents the asynchronous mapping operation. The task result contains the mapped <see cref="PatientTreatment"/>.</returns>
/// <!-- aidoc:v1 sig=be008d3 -->
Task<PatientTreatment> Map(PatientTreatment treatment);
/// <summary>
/// Asynchronously maps a <see cref="PatientDiagnosis"/> to a <see cref="PatientDiagnosis"/> representation.
/// </summary>
/// <param name="diagnosis">The patient diagnosis to be mapped.</param>
/// <returns>A task that represents the asynchronous mapping operation, containing the mapped <see cref="PatientDiagnosis"/>.</returns>
/// <!-- aidoc:v1 sig=b4c53f0 -->
Task<PatientDiagnosis> Map(PatientDiagnosis diagnosis);
/// <summary>
@@ -32,6 +35,7 @@ public interface ICalculatedObservations
/// </summary>
/// <param name="pumpObservation">The <see cref="PumpObservation"/> to be mapped.</param>
/// <returns>A <see cref="Task{TResult}"/> representing the asynchronous operation, containing the mapped <see cref="PumpObservation"/>.</returns>
/// <!-- aidoc:v1 sig=47d6f99 -->
Task<PumpObservation> Map(PumpObservation pumpObservation);
/// <summary>
@@ -39,12 +43,14 @@ public interface ICalculatedObservations
/// </summary>
/// <param name="activeMedicines">The list of medicines currently active for the patient.</param>
/// <param name="patientId">The unique identifier of the patient whose observation is being calculated.</param>
/// <!-- aidoc:v1 sig=341d0d1 -->
Task CalculateMedicineObservation(List<Medicine> activeMedicines, ObjectId patientId);
/// <summary>
/// Calculates the active bolus for the specified patient.
/// </summary>
/// <param name="patientId">The unique identifier of the patient whose active bolus is to be calculated.</param>
/// <!-- aidoc:v1 sig=db92fab -->
Task CalculateActiveBolus(ObjectId patientId);
/// <summary>
@@ -52,6 +58,7 @@ public interface ICalculatedObservations
/// </summary>
/// <param name="id">The unique identifier of the patient whose active treatments are being queried.</param>
/// <returns>A task that represents the asynchronous operation, containing a collection of nullable <see cref="PatientTreatment"/> entries that represent the active treatments for the specified patient.</returns>
/// <!-- aidoc:v1 sig=9eb0d98 -->
Task<IEnumerable<PatientTreatment?>> GetActiveTreatmentsByPatient(ObjectId id);
/// <summary>
@@ -59,12 +66,14 @@ public interface ICalculatedObservations
/// </summary>
/// <param name="newObservation">The new patient observation to validate and reconcile against the previous observation's time information.</param>
/// <returns>A task that yields the fixed <see cref="PatientObservation"/>, or <c>null</c> when no time inconsistency is detected or no correction is required.</returns>
/// <!-- aidoc:v1 sig=ae6ddc1 -->
Task<PatientObservation?> FixTimeInconsistencyWithLast(PatientObservation newObservation);
/// <summary>
/// Performs pre-insertion mapping on a list of patient observations, transforming or preparing the data before it is persisted.
/// </summary>
/// <param name="listToInsert">The list of patient observations to be pre-mapped prior to insertion.</param>
/// <returns>A task that represents the asynchronous operation, containing the mapped list of patient observations.</returns>
/// <!-- aidoc:v1 sig=c6d4218 -->
Task<List<PatientObservation>> PreMapList(List<PatientObservation> listToInsert);
/// <summary>
/// Maps the source alarm onto the specified patient observation and returns the resulting observation.
@@ -72,6 +81,7 @@ public interface ICalculatedObservations
/// <param name="obs">The patient observation to which the source alarm will be mapped.</param>
/// <param name="alarmToInsert">The patient observation alarm to insert and map as the source alarm.</param>
/// <returns>A task representing the asynchronous operation, containing the patient observation with the source alarm mapped.</returns>
/// <!-- aidoc:v1 sig=c22dba5 -->
Task<PatientObservation> MapSourceAlarm(PatientObservation obs, PatientObservationAlarm alarmToInsert);
/// <summary>
@@ -80,5 +90,7 @@ public interface ICalculatedObservations
/// <param name="obs">The patient observation that triggered the alarm.</param>
/// <param name="name">The name associated with the alarm.</param>
/// <param name="code">An optional alarm code categorizing the type of alarm to send.</param>
/// <!-- aidoc-review:v1 severity=medium kind=missing_returns
/// "Method returns Task but no <returns> tag documents the async return value or what completion of the task represents." -->
Task SendAlarm(PatientObservation obs, string name, AlarmEnum.Name? code);
}