=== 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:
@@ -8,10 +8,12 @@ public interface IApiRequestService
|
||||
/// Asynchronously persists the specified <see cref="ApiRequest"/>.
|
||||
/// </summary>
|
||||
/// <param name="apiRequest">The API request to be saved.</param>
|
||||
/// <!-- aidoc:v1 sig=24f178e -->
|
||||
Task SaveRequestAsync(ApiRequest apiRequest);
|
||||
/// <summary>
|
||||
/// Asynchronously saves the specified API request.
|
||||
/// </summary>
|
||||
/// <param name="apiRequest">The API request to persist.</param>
|
||||
/// <!-- aidoc:v1 sig=274a023 -->
|
||||
Task SaveRequest(ApiRequest apiRequest);
|
||||
}
|
||||
@@ -13,12 +13,14 @@ public interface IAdminPanelService
|
||||
/// </summary>
|
||||
/// <param name="unitId">The unique identifier of the unit to delete.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result is <c>true</c> if the unit was successfully deleted; otherwise, <c>false</c> if the unit was not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=3dcac9a -->
|
||||
Task<bool> DeleteUnitById(ObjectId unitId);
|
||||
/// <summary>
|
||||
/// Inserts a new <see cref="Unit"/> into the data store and returns the inserted entity.
|
||||
/// </summary>
|
||||
/// <param name="unit">The <see cref="Unit"/> to insert.</param>
|
||||
/// <returns>A <see cref="Task{T}"/> that resolves to the inserted <see cref="Unit"/>, or <see langword="null"/> if the insert could not be completed.</returns>
|
||||
/// <!-- aidoc:v1 sig=9d5e322 -->
|
||||
Task<Unit?> InsertUnit(Unit unit);
|
||||
|
||||
#region Patient
|
||||
@@ -28,18 +30,21 @@ public interface IAdminPanelService
|
||||
/// </summary>
|
||||
/// <param name="apiRequest">The admin panel request containing the data needed to create the patient.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the created <see cref="Patient"/>, or <c>null</c> if no patient was created.</returns>
|
||||
/// <!-- aidoc:v1 sig=9a79f3c -->
|
||||
Task<Patient?> CreatePatient(AdmPanelRequest apiRequest);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the patient associated with the specified location.
|
||||
/// </summary>
|
||||
/// <param name="location">The location used to look up the associated patient.</param>
|
||||
/// <returns>A task that resolves to the <see cref="Patient"/> found at the given location, or <c>null</c> if no patient is associated with that location.</returns>
|
||||
/// <!-- aidoc:v1 sig=bfbcfb4 -->
|
||||
Task<Patient?> FindPatientByLocation(PatientLocation location);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a <see cref="Patient"/> by their unique patient number.
|
||||
/// </summary>
|
||||
/// <param name="patientNumber">The unique identifier of the patient to look up.</param>
|
||||
/// <returns>A <see cref="Task{TResult}"/> that yields the matching <see cref="Patient"/>, or <c>null</c> if no patient is found with the specified number.</returns>
|
||||
/// <!-- aidoc:v1 sig=088434b -->
|
||||
Task<Patient?> FindPatientByPatientNumber(string patientNumber);
|
||||
|
||||
/// <summary>
|
||||
@@ -48,6 +53,7 @@ public interface IAdminPanelService
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the patient to retrieve.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the patient if found; otherwise, null.</returns>
|
||||
/// <!-- aidoc:v1 sig=0210ac7 -->
|
||||
Task<Patient?> FindPatientById(ObjectId id);
|
||||
|
||||
//List<person> FindAllPatient();
|
||||
@@ -57,6 +63,7 @@ public interface IAdminPanelService
|
||||
/// </summary>
|
||||
/// <param name="request">The admission panel request containing the search criteria used to locate the patient.</param>
|
||||
/// <returns>A <see cref="Task{TResult}"/> that yields the matching <see cref="Patient"/> if found, or <c>null</c> otherwise.</returns>
|
||||
/// <!-- aidoc:v1 sig=c3d3d62 -->
|
||||
Task<Patient?> FindPatient(AdmPanelRequest request);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the dependency information DTO for the specified <paramref name="unit"/>.
|
||||
@@ -64,6 +71,7 @@ public interface IAdminPanelService
|
||||
/// </summary>
|
||||
/// <param name="unit">The unit for which to retrieve dependency information.</param>
|
||||
/// <returns>A <see cref="Task{UnitInfoDto}"/> that yields the unit dependency DTO, or <c>null</c> if none is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=4a1eecb -->
|
||||
Task<UnitInfoDto?> GetUnitDependencyDto(Unit unit);
|
||||
|
||||
/// <summary>
|
||||
@@ -71,6 +79,7 @@ public interface IAdminPanelService
|
||||
/// </summary>
|
||||
/// <param name="request">The admission panel request containing the patient location details to update.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result is <c>true</c> if the update was successful; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=82018b5 -->
|
||||
Task<bool> UpdatePatientLocation(AdmPanelRequest request);
|
||||
/// <summary>
|
||||
/// Updates the patient data based on the provided admission panel request, using the existing patient record as a reference.
|
||||
@@ -78,12 +87,14 @@ public interface IAdminPanelService
|
||||
/// <param name="request">The admission panel request containing the updated patient data.</param>
|
||||
/// <param name="oldPatient">The existing patient record to be updated.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result is <c>true</c> if the patient data was successfully updated; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=72c8ec4 -->
|
||||
Task<bool> UpdatePatientData(AdmPanelRequest request, Patient oldPatient);
|
||||
/// <summary>
|
||||
/// Archives the specified patient, marking them as inactive while preserving their record.
|
||||
/// </summary>
|
||||
/// <param name="patient">The patient to be archived.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains <c>true</c> if the patient was successfully archived; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=9285b16 -->
|
||||
Task<bool> ArchivePatient(Patient patient);
|
||||
|
||||
#endregion
|
||||
@@ -94,18 +105,21 @@ public interface IAdminPanelService
|
||||
/// </summary>
|
||||
/// <param name="configObservation">The observation data used to create the configuration.</param>
|
||||
/// <returns>A task that represents the asynchronous create operation, containing a value indicating whether the configuration was created successfully.</returns>
|
||||
/// <!-- aidoc:v1 sig=067bf2d -->
|
||||
Task<bool> CreateConfig(ConfigObservation configObservation);
|
||||
/// <summary>
|
||||
/// Asynchronously updates the configuration based on the provided <see cref="ConfigObservation"/>, applying any required changes derived from the observation data.
|
||||
/// </summary>
|
||||
/// <param name="configObservation">The observation data used to determine and apply configuration updates.</param>
|
||||
/// <returns>A <see cref="Task{Boolean}"/> that represents the asynchronous update operation, containing a value indicating whether the configuration was successfully updated.</returns>
|
||||
/// <!-- aidoc:v1 sig=e4c099d -->
|
||||
Task<bool> UpdateConfig(ConfigObservation configObservation);
|
||||
/// <summary>
|
||||
/// Deletes the configuration observation item identified by the specified identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the configuration observation item to delete.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result is <c>true</c> if the item was successfully deleted; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=e7902ac -->
|
||||
Task<bool> DeleteConfigObservationItem(ObjectId id);
|
||||
|
||||
#endregion
|
||||
@@ -118,24 +132,28 @@ public interface IAdminPanelService
|
||||
/// </summary>
|
||||
/// <param name="medicineId">The unique <see cref="ObjectId"/> of the medicine to look up.</param>
|
||||
/// <returns>A <see cref="Task{Medicine}"/> that resolves to the matching <see cref="Medicine"/>, or <c>null</c> if not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=a87fd1e -->
|
||||
Task<Medicine?> GetMedicineById(ObjectId medicineId);
|
||||
/// <summary>
|
||||
/// Asynchronously creates and persists a new medicine record.
|
||||
/// </summary>
|
||||
/// <param name="medicine">The medicine entity to be created and posted.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the newly created <see cref="Medicine"/>, or <c>null</c> if the operation fails.</returns>
|
||||
/// <!-- aidoc:v1 sig=9decc93 -->
|
||||
Task<Medicine?> PostMedicine(Medicine medicine);
|
||||
/// <summary>
|
||||
/// Updates an existing medicine record in the system.
|
||||
/// </summary>
|
||||
/// <param name="medicine">The medicine entity containing the updated information to be persisted.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the updated <see cref="Medicine"/> if found, or <c>null</c> if the medicine does not exist.</returns>
|
||||
/// <!-- aidoc:v1 sig=2ae8490 -->
|
||||
Task<Medicine?> UpdateMedicine(Medicine medicine);
|
||||
/// <summary>
|
||||
/// Deletes a medicine identified by its unique identifier.
|
||||
/// </summary>
|
||||
/// <param name="medicineId">The unique identifier of the medicine to delete.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains <c>true</c> if the medicine was successfully deleted; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=fe8649a -->
|
||||
Task<bool> DeleteMedicineById(string medicineId);
|
||||
|
||||
#endregion
|
||||
|
||||
@@ -14,21 +14,25 @@ public interface IAdmissionService : IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="admissionId">The unique identifier of the admission to retrieve.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the <see cref="Admission"/> if found, or <c>null</c> if no admission matches the specified identifier.</returns>
|
||||
/// <!-- aidoc:v1 sig=11f3852 -->
|
||||
Task<Admission?> GetAdmissionByIdAsync(ObjectId admissionId);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes an admission record identified by the specified admission ID.
|
||||
/// </summary>
|
||||
/// <param name="admissionId">The unique identifier of the admission to delete.</param>
|
||||
/// <!-- aidoc:v1 sig=33e47dc -->
|
||||
Task DeleteAdmissionByIdAsync(ObjectId admissionId);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes the specified admission record.
|
||||
/// </summary>
|
||||
/// <param name="admission">The admission entity to remove.</param>
|
||||
/// <!-- aidoc:v1 sig=f6c9117 -->
|
||||
Task DeleteAdmissionAsync(Admission admission);
|
||||
/// <summary>
|
||||
/// Deletes all admissions associated with the specified unit identifier.
|
||||
/// </summary>
|
||||
/// <param name="unitId">The identifier of the unit whose admissions will be deleted.</param>
|
||||
/// <!-- aidoc:v1 sig=94c7556 -->
|
||||
Task DeleteAdmissionsByUnitId(ObjectId unitId);
|
||||
|
||||
/// <summary>
|
||||
@@ -36,46 +40,54 @@ public interface IAdmissionService : IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="admission">The admission entity containing the updated data to be persisted.</param>
|
||||
/// <returns>A task that represents the asynchronous update operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=4327caa -->
|
||||
Task UpdateAdmissionAsync(Admission admission);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a collection of admissions.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains an enumerable collection of <see cref="Admission"/> objects.</returns>
|
||||
/// <!-- aidoc:v1 sig=a1ad970 -->
|
||||
Task<IEnumerable<Admission>> GetAdmissionsAsync();
|
||||
/// <summary>
|
||||
/// Asynchronously inserts a new admission record and returns the created entry, or <see langword="null"/> if the insertion was not performed.
|
||||
/// </summary>
|
||||
/// <param name="admission">The admission entity to be inserted into the data store.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the inserted <see cref="Admission"/>, or <see langword="null"/> when no record is produced.</returns>
|
||||
/// <!-- aidoc:v1 sig=d13b5c5 -->
|
||||
Task<Admission?> InsertAdmission(Admission admission);
|
||||
/// <summary>
|
||||
/// Admits a patient based on the provided admission details, optionally registering the patient as new.
|
||||
/// </summary>
|
||||
/// <param name="admission">The admission information used to process the patient admission.</param>
|
||||
/// <param name="isNew">Indicates whether the patient is being admitted for the first time. Defaults to <c>false</c>.</param>
|
||||
/// <!-- aidoc:v1 sig=9f57e3f -->
|
||||
Task AdmitPatient(Admission admission, bool isNew = false);
|
||||
/// <summary>
|
||||
/// Processes the return of a patient to the admissions workflow, typically used when a patient needs to be re-queued or reinstated for admission processing.
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient to be returned to admissions.</param>
|
||||
/// <!-- aidoc:v1 sig=4258668 -->
|
||||
Task ReturnPatientToAdmissions(ObjectId patientId);
|
||||
/// <summary>
|
||||
/// Asynchronously returns a patient to the admissions workflow using the specified admission record.
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient being returned to admissions.</param>
|
||||
/// <param name="adm">The admission record associated with the patient being returned.</param>
|
||||
/// <!-- aidoc:v1 sig=d4a135f -->
|
||||
Task ReturnPatientToAdmissions(ObjectId patientId, Admission adm);
|
||||
/// <summary>
|
||||
/// Retrieves a list of admissions associated with the specified patient location.
|
||||
/// </summary>
|
||||
/// <param name="location">The patient location used to filter the admissions.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of admissions for the given location.</returns>
|
||||
/// <!-- aidoc:v1 sig=b81f02e -->
|
||||
Task<List<Admission>> GetAdmissionByLocation(PatientLocation location);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the list of admissions associated with the specified point of care identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The <see cref="ObjectId"/> of the point of care used to filter the admissions.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of <see cref="Admission"/> objects matching the specified point of care id, or an empty list if no admissions are found.</returns>
|
||||
/// <!-- aidoc:v1 sig=dc63c5a -->
|
||||
Task<List<Admission>> GetAdmissionByPointOfCareId(ObjectId id);
|
||||
/// <summary>
|
||||
/// Retrieves the list of admissions associated with the specified point of care, localized for the given locale.
|
||||
@@ -83,18 +95,21 @@ public interface IAdmissionService : IApiRequestService
|
||||
/// <param name="pocId">The identifier of the point of care whose admissions are being queried.</param>
|
||||
/// <param name="locale">The locale used to localize the returned admission data.</param>
|
||||
/// <returns>A task that resolves to the list of admissions matching the point of care and locale; an empty list when no matches are found.</returns>
|
||||
/// <!-- aidoc:v1 sig=9479688 -->
|
||||
Task<List<Admission>> GetAdmissionByPointOfCareIdAndLocale(ObjectId pocId, LocaleEnum locale);
|
||||
/// <summary>
|
||||
/// Retrieves a list of admissions associated with the specified unit identifier, excluding any Point of Care (PoC) related admissions.
|
||||
/// </summary>
|
||||
/// <param name="unitId">The unique identifier of the unit whose admissions should be retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of admissions for the specified unit, excluding PoC admissions.</returns>
|
||||
/// <!-- aidoc:v1 sig=609220d -->
|
||||
Task<List<Admission>> GetAdmissionByUnitIdWithOutPoC(ObjectId unitId);
|
||||
/// <summary>
|
||||
/// Asynchronously counts the number of admissions associated with the specified unit identifier.
|
||||
/// </summary>
|
||||
/// <param name="unitId">The MongoDB ObjectId of the unit whose admissions should be counted.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the total count of admissions for the given unit.</returns>
|
||||
/// <!-- aidoc:v1 sig=d273b51 -->
|
||||
Task<long> CountAdmissionsByUnitId(ObjectId unitId);
|
||||
|
||||
/// <summary>
|
||||
@@ -103,12 +118,14 @@ public interface IAdmissionService : IApiRequestService
|
||||
/// <param name="patientNumber">The patient number used to identify the patient.</param>
|
||||
/// <param name="unitId">The identifier of the unit in which the patient is being searched.</param>
|
||||
/// <returns>A task that returns the matching <see cref="PatientSearch"/> if found; otherwise, null.</returns>
|
||||
/// <!-- aidoc:v1 sig=3a4d9fd -->
|
||||
Task<PatientSearch?> SearchByPatientNumberAndDistinctUnit(string patientNumber, ObjectId unitId);
|
||||
/// <summary>
|
||||
/// Retrieves the admission record associated with the specified patient number, returning <c>null</c> when no matching admission is found.
|
||||
/// </summary>
|
||||
/// <param name="patientNumber">The unique patient number used to look up the admission.</param>
|
||||
/// <returns>A task that resolves to the matching <see cref="Admission"/>, or <c>null</c> if no admission exists for the given patient number.</returns>
|
||||
/// <!-- aidoc:v1 sig=c602701 -->
|
||||
Task<Admission?> GetAdmissionByPatientNumber(string patientNumber);
|
||||
|
||||
/// <summary>
|
||||
@@ -118,6 +135,7 @@ public interface IAdmissionService : IApiRequestService
|
||||
/// <param name="unitList">The collection of units associated with the master list item change.</param>
|
||||
/// <param name="typeName">The name of the type used to identify the master list item category.</param>
|
||||
/// <returns>A task that represents the asynchronous update operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=6d7dd8e -->
|
||||
Task UpdatePatientMasterListItemChange(UpdateOptionMasterListDto opt, IEnumerable<Unit> unitList, string typeName);
|
||||
/// <summary>
|
||||
/// Deletes a patient master list item identified by the specified options, units, and type name.
|
||||
@@ -125,5 +143,6 @@ public interface IAdmissionService : IApiRequestService
|
||||
/// <param name="opt">The option list used to identify the master list item to delete.</param>
|
||||
/// <param name="unitList">The collection of units associated with the master list item.</param>
|
||||
/// <param name="typeName">The name of the type associated with the master list item.</param>
|
||||
/// <!-- aidoc:v1 sig=bbc71d1 -->
|
||||
Task DeletePatientMasterListItem(OptionList opt, IEnumerable<Unit> unitList, string typeName);
|
||||
}
|
||||
@@ -14,6 +14,7 @@ public interface IAlarmService : IApiRequestService
|
||||
/// <param name="patientId">The identifier of the patient whose last observations should be retrieved.</param>
|
||||
/// <param name="filterObservations">An optional list of fields to restrict the returned observations; when null, no field filter is applied.</param>
|
||||
/// <returns>A task that resolves to the list of the patient's most recent <see cref="PatientObservationAlarm"/> records.</returns>
|
||||
/// <!-- aidoc:v1 sig=db70ab6 -->
|
||||
public Task<List<PatientObservationAlarm>> FindLastObservationsByField(ObjectId patientId,
|
||||
List<Field>? filterObservations = null);
|
||||
|
||||
@@ -24,6 +25,7 @@ public interface IAlarmService : IApiRequestService
|
||||
/// <param name="dataAlarmfields">The list of fields used to identify and filter the patient observation alarm data.</param>
|
||||
/// <param name="configAlarm">The list of configuration observations that define the alarm criteria, including expiration rules.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the list of the latest non-expired <see cref="PatientObservationAlarm"/> entries for the patient.</returns>
|
||||
/// <!-- aidoc:v1 sig=cee772b -->
|
||||
Task<List<PatientObservationAlarm>> FindLastValuesNotExpired(ObjectId patientId, List<Field> dataAlarmfields,
|
||||
List<ConfigObservation> configAlarm);
|
||||
|
||||
@@ -33,12 +35,14 @@ public interface IAlarmService : IApiRequestService
|
||||
/// <param name="obs">The patient observation alarm to be mapped.</param>
|
||||
/// <param name="onlyByName">When true, limits the mapping to lookups performed by name only.</param>
|
||||
/// <returns>A task that resolves to the mapped patient observation alarm, or null if no corresponding alarm is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=a6ed4ac -->
|
||||
public Task<PatientObservationAlarm?> MapObservation(PatientObservationAlarm obs, bool onlyByName = false);
|
||||
/// <summary>
|
||||
/// Maps the given patient observation alarm to a corresponding record by name, returning a null result when no matching observation is found.
|
||||
/// </summary>
|
||||
/// <param name="obs">The patient observation alarm to be mapped by name.</param>
|
||||
/// <returns>A task containing the mapped <see cref="PatientObservationAlarm"/>, or <c>null</c> if no matching observation exists.</returns>
|
||||
/// <!-- aidoc:v1 sig=bc68e0c -->
|
||||
public Task<PatientObservationAlarm?> MapObservationsByName(PatientObservationAlarm obs);
|
||||
|
||||
/// <summary>
|
||||
@@ -46,6 +50,7 @@ public interface IAlarmService : IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="source">The base patient observation value used as input for the alarm evaluation.</param>
|
||||
/// <param name="name">The name that identifies the alarm test to be calculated.</param>
|
||||
/// <!-- aidoc:v1 sig=6689f69 -->
|
||||
Task CalculateAlarmTest(BasePatientObservationValue source, string name);
|
||||
|
||||
/// <summary>
|
||||
@@ -57,6 +62,7 @@ public interface IAlarmService : IApiRequestService
|
||||
/// <param name="severity">The severity level assigned to the alarm.</param>
|
||||
/// <param name="type">The type category of the alarm.</param>
|
||||
/// <returns>A task that represents the asynchronous alarm sending operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=1e4624b -->
|
||||
Task SendAlarm(PatientObservation obs, string name, AlarmEnum.Name? code, AlarmEnum.Severity severity,
|
||||
AlarmEnum.Type type);
|
||||
|
||||
@@ -64,6 +70,7 @@ public interface IAlarmService : IApiRequestService
|
||||
/// Asynchronously checks the observation alarm for the specified patient observation.
|
||||
/// </summary>
|
||||
/// <param name="obs4">The patient observation to evaluate for alarm conditions.</param>
|
||||
/// <!-- aidoc:v1 sig=db0bd32 -->
|
||||
Task CheckObservationAlarm(PatientObservation obs4);
|
||||
|
||||
/// <summary>
|
||||
@@ -74,6 +81,7 @@ public interface IAlarmService : IApiRequestService
|
||||
/// <param name="patient">The patient to whom the observations and alarms belong.</param>
|
||||
/// <param name="messageTime">The timestamp associated with the message being processed.</param>
|
||||
/// <param name="observationData">Optional additional observation data used during processing.</param>
|
||||
/// <!-- aidoc:v1 sig=b10b184 -->
|
||||
Task ProcessAlarmObservations(List<PatientObservationAlarm> alarmObservations,
|
||||
List<PatientObservation> observations, Patient patient,
|
||||
DateTime messageTime, ObservationData? observationData = null);
|
||||
|
||||
@@ -11,5 +11,6 @@ public interface IAlertValuesService
|
||||
/// </summary>
|
||||
/// <param name="key">The identifier of the configuration observation to look up.</param>
|
||||
/// <returns>A task that yields the matching <see cref="ConfigObservation"/>, or <c>null</c> if no record is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=938830c -->
|
||||
Task<ConfigObservation?> FindByKey(ObjectId key);
|
||||
}
|
||||
@@ -12,12 +12,14 @@ public interface IAppointmentService : IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="location">The patient location used to filter and locate the relevant appointments.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="PatientAppointment"/> items matching the given location.</returns>
|
||||
/// <!-- aidoc:v1 sig=8d1c435 -->
|
||||
Task<List<PatientAppointment>> FindByLocation(PatientLocation location);
|
||||
/// <summary>
|
||||
/// Retrieves all appointments associated with the specified patient asynchronously.
|
||||
/// </summary>
|
||||
/// <param name="patientId">The identifier of the patient whose appointments are being retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="PatientAppointment"/> entries for the patient.</returns>
|
||||
/// <!-- aidoc:v1 sig=44280ba -->
|
||||
Task<List<PatientAppointment>> GetByPatient(ObjectId patientId);
|
||||
/// <summary>
|
||||
/// Retrieves the list of patient appointments scheduled for today for the specified patient.
|
||||
@@ -25,6 +27,7 @@ public interface IAppointmentService : IApiRequestService
|
||||
/// <param name="patientId">The unique identifier of the patient whose appointments are being queried.</param>
|
||||
/// <param name="ct">A cancellation token to observe while waiting for the task to complete.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="PatientAppointment"/> entries for the given patient for the current day.</returns>
|
||||
/// <!-- aidoc:v1 sig=4fb06f0 -->
|
||||
Task<List<PatientAppointment>> GetTodayByPatient(ObjectId patientId, CancellationToken ct = default);
|
||||
/// <summary>
|
||||
/// Retrieves the list of patient appointments scheduled for today at the specified point of care.
|
||||
@@ -32,33 +35,39 @@ public interface IAppointmentService : IApiRequestService
|
||||
/// <param name="pocId">The identifier of the point of care whose appointments will be returned.</param>
|
||||
/// <param name="ct">The cancellation token used to cancel the asynchronous operation.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of today's patient appointments for the specified point of care.</returns>
|
||||
/// <!-- aidoc:v1 sig=b1e7397 -->
|
||||
Task<List<PatientAppointment>> GetTodayByPoc(ObjectId pocId, CancellationToken ct = default);
|
||||
/// <summary>
|
||||
/// Asynchronously finds all <see cref="PatientAppointment"/> records associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose appointments are being retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing an <see cref="IAsyncCursor{TDocument}"/> for iterating over the matching <see cref="PatientAppointment"/> documents.</returns>
|
||||
/// <!-- aidoc:v1 sig=2d5cd9f -->
|
||||
Task<IAsyncCursor<PatientAppointment>> FindByPatientIdAsync(ObjectId patientId);
|
||||
/// <summary>
|
||||
/// Asynchronously archives the specified patient, marking the record as archived in the system.
|
||||
/// </summary>
|
||||
/// <param name="patient">The patient whose record should be archived.</param>
|
||||
/// <!-- aidoc:v1 sig=52c2373 -->
|
||||
Task Archive(Patient patient);
|
||||
/// <summary>
|
||||
/// Asynchronously archives records associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The <see cref="ObjectId"/> of the patient whose related records should be archived.</param>
|
||||
/// <!-- aidoc:v1 sig=e5916ec -->
|
||||
Task ArchiveByPatientId(ObjectId id);
|
||||
/// <summary>
|
||||
/// Deletes a record associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The <see cref="ObjectId"/> of the patient whose related record should be removed.</param>
|
||||
/// <!-- aidoc:v1 sig=d457cb9 -->
|
||||
Task DeleteByPatientId(ObjectId id);
|
||||
/// <summary>
|
||||
/// Processes an incoming API request in the context of the specified patient, handling the required business logic and returning when the processing completes.
|
||||
/// </summary>
|
||||
/// <param name="apiRequest">The API request to be processed.</param>
|
||||
/// <param name="patient">The patient associated with the API request.</param>
|
||||
/// <!-- aidoc:v1 sig=eae6711 -->
|
||||
Task ProcessApiRequest(ApiRequest apiRequest, Patient patient);
|
||||
/// <summary>
|
||||
/// Updates multiple records by replacing the old <see cref="ObjectId"/> with the new one for the field identified by <paramref name="nameId"/>.
|
||||
@@ -66,5 +75,6 @@ public interface IAppointmentService : IApiRequestService
|
||||
/// <param name="nameId">The name of the field whose <see cref="ObjectId"/> value should be updated.</param>
|
||||
/// <param name="id">The new <see cref="ObjectId"/> value to set on matching records.</param>
|
||||
/// <param name="oldId">The existing <see cref="ObjectId"/> value to be replaced.</param>
|
||||
/// <!-- aidoc:v1 sig=24ef97c -->
|
||||
Task UpdateManyObjectId(string nameId, ObjectId id, ObjectId oldId);
|
||||
}
|
||||
@@ -10,24 +10,28 @@ public interface IArchivePatientCarePlanService
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the patient whose care plans are being retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of <see cref="PatientCarePlan"/> objects if found, or <c>null</c> if no care plans exist for the patient.</returns>
|
||||
/// <!-- aidoc:v1 sig=e64875e -->
|
||||
Task<List<PatientCarePlan>?> FindByPatientId(ObjectId id);
|
||||
/// <summary>
|
||||
/// Retrieves the list of care plans associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the patient whose care plans should be retrieved.</param>
|
||||
/// <returns>A task that returns a list of <see cref="PatientCarePlan"/> records for the patient, or <c>null</c> if no care plans are found.</returns>
|
||||
/// <!-- aidoc:v1 sig=2001a29 -->
|
||||
Task<List<PatientCarePlan>?> FindByPatientId(string id);
|
||||
/// <summary>
|
||||
/// Retrieves a list of patient care plans associated with the specified patient number.
|
||||
/// </summary>
|
||||
/// <param name="id">The patient number used to locate the associated care plans.</param>
|
||||
/// <returns>A task that returns a list of <see cref="PatientCarePlan"/> for the given patient number, or <c>null</c> if no care plans are found.</returns>
|
||||
/// <!-- aidoc:v1 sig=da83156 -->
|
||||
Task<List<PatientCarePlan>?> FindByPatientNumber(string id);
|
||||
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves all patient care plans.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="PatientCarePlan"/> objects.</returns>
|
||||
/// <!-- aidoc:v1 sig=83af170 -->
|
||||
Task<List<PatientCarePlan>> FindAll();
|
||||
|
||||
// Task<PatientCarePlan?> UpdateTreatment(PatientCarePlan patientCarePla, List<OptionList> options);
|
||||
@@ -37,11 +41,13 @@ public interface IArchivePatientCarePlanService
|
||||
/// </summary>
|
||||
/// <param name="patientCarePla">The patient care plan to insert.</param>
|
||||
/// <returns>A <see cref="Task{PatientCarePlan}"/> that represents the asynchronous insert operation, containing the inserted <see cref="PatientCarePlan"/> or null if no entity was returned.</returns>
|
||||
/// <!-- aidoc:v1 sig=a99067e -->
|
||||
Task<PatientCarePlan?> InsertOneAsync(PatientCarePlan patientCarePla);
|
||||
/// <summary>
|
||||
/// Asynchronously inserts a collection of patient care plans into the data store in a single bulk operation.
|
||||
/// </summary>
|
||||
/// <param name="patientCarePla">The list of <see cref="PatientCarePlan"/> entities to be inserted.</param>
|
||||
/// <!-- aidoc:v1 sig=fea7cc8 -->
|
||||
Task InsertManyAsync(List<PatientCarePlan> patientCarePla);
|
||||
|
||||
// Task Update(PatientCarePlan oldPatientCarePla, PatientCarePlan newPatientCarePla);
|
||||
|
||||
@@ -10,5 +10,6 @@ public interface IArchivedPatientObservationService
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose archived observations are to be retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="PatientObservation"/> objects representing the archived observations for the patient.</returns>
|
||||
/// <!-- aidoc:v1 sig=cedb842 -->
|
||||
public Task<List<PatientObservation>> FindArchivedPatientObservationsFromPatient(ObjectId patientId);
|
||||
}
|
||||
@@ -8,5 +8,6 @@ public interface IArchivedPatientService
|
||||
/// Asynchronously retrieves all patients from the data store.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of all patients.</returns>
|
||||
/// <!-- aidoc:v1 sig=3685411 -->
|
||||
public Task<List<Patient>> FindAllPatients();
|
||||
}
|
||||
@@ -10,5 +10,6 @@ public interface IArchivedPatientTreatmentService
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose treatments are being retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="PatientTreatment"/> records for the given patient.</returns>
|
||||
/// <!-- aidoc:v1 sig=17e4911 -->
|
||||
Task<List<PatientTreatment>> FindAllPatientTreatmentsByPatient(ObjectId patientId);
|
||||
}
|
||||
@@ -10,34 +10,40 @@ public interface IAuthService
|
||||
/// Asynchronously retrieves the current login response, returning <c>null</c> when no login state is available.
|
||||
/// </summary>
|
||||
/// <returns>A <see cref="Task{TResult}"/> that resolves to the current <see cref="LoginResponse"/>, or <c>null</c> if no login response exists.</returns>
|
||||
/// <!-- aidoc:v1 sig=17789be -->
|
||||
Task<LoginResponse?> GetLoginResponse();
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a token.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the retrieved token string.</returns>
|
||||
/// <!-- aidoc:v1 sig=288a8f8 -->
|
||||
Task<string> GetToken();
|
||||
/// <summary>
|
||||
/// Retrieves a list of authorizations associated with the specified unit identifier.
|
||||
/// </summary>
|
||||
/// <param name="unitId">The unique identifier of the unit whose authorizations are being queried.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="Authorization"/> objects matching the provided unit identifier.</returns>
|
||||
/// <!-- aidoc:v1 sig=82be9e3 -->
|
||||
Task<List<Authorization>> GetByUnitId(ObjectId unitId);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes the record identified by the specified display identifier.
|
||||
/// </summary>
|
||||
/// <param name="displayId">The display identifier of the record to delete.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a value indicating whether the record was successfully deleted.</returns>
|
||||
/// <!-- aidoc:v1 sig=9bea906 -->
|
||||
Task<bool> DeleteByDisplayId(ObjectId displayId);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes the entity associated with the specified unit identifier.
|
||||
/// </summary>
|
||||
/// <param name="unitId">The unique identifier of the unit whose associated entity should be deleted.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a value indicating whether the deletion was successful.</returns>
|
||||
/// <!-- aidoc:v1 sig=7032be4 -->
|
||||
Task<bool> DeleteByUnitId(ObjectId unitId);
|
||||
/// <summary>
|
||||
/// Retrieves the list of authorizations associated with the specified user identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the user whose authorizations are being retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the list of authorizations for the user.</returns>
|
||||
/// <!-- aidoc:v1 sig=884297c -->
|
||||
Task<List<Authorization>> GetUserAuthorities(ObjectId id);
|
||||
}
|
||||
@@ -11,12 +11,14 @@ namespace adas_core.Application.Services.Interfaces
|
||||
/// </summary>
|
||||
/// <param name="key">The identifier used to associate the value.</param>
|
||||
/// <param name="value">The value to store for the specified key.</param>
|
||||
/// <!-- aidoc:v1 sig=a3acfbd -->
|
||||
void SetValue(string key, string value);
|
||||
/// <summary>
|
||||
/// Retrieves the string value associated with the specified key.
|
||||
/// </summary>
|
||||
/// <param name="key">The key used to look up the value.</param>
|
||||
/// <returns>The value associated with the key, or <c>null</c> if the key is not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=09e20ab -->
|
||||
string? GetValue(string key);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves an object associated with the specified <paramref name="key"/>, returning null if no entry is found.
|
||||
@@ -25,6 +27,7 @@ namespace adas_core.Application.Services.Interfaces
|
||||
/// <param name="key">The unique identifier of the object to retrieve.</param>
|
||||
/// <param name="updateExpiration">Indicates whether the expiration of the entry should be extended when it is successfully retrieved. Defaults to true.</param>
|
||||
/// <returns>A task that represents the asynchronous retrieval operation. The task result contains the object of type <typeparamref name="T"/> associated with the key, or null if no matching entry exists.</returns>
|
||||
/// <!-- aidoc:v1 sig=a85ace8 -->
|
||||
Task<T?> GetObjectAsync<T>(string key, bool updateExpiration = true);
|
||||
/// <summary>
|
||||
/// Asynchronously stores an object of type <typeparamref name="T"/> using the specified key, optionally updating its expiration time.
|
||||
@@ -33,6 +36,7 @@ namespace adas_core.Application.Services.Interfaces
|
||||
/// <param name="key">The identifier under which the object will be stored.</param>
|
||||
/// <param name="obj">The object to be stored.</param>
|
||||
/// <param name="updateExpiration">Specifies whether the expiration time of the entry should be refreshed. Defaults to true.</param>
|
||||
/// <!-- aidoc:v1 sig=af94cc4 -->
|
||||
Task SetObjectAsync<T>(string key, T obj, bool updateExpiration = true);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves an object of type <typeparamref name="T"/> associated with the specified <paramref name="key"/>.
|
||||
@@ -43,6 +47,7 @@ namespace adas_core.Application.Services.Interfaces
|
||||
/// <param name="ttlOverride">An optional time-to-live value that overrides the default expiration period; if <see langword="null"/>, the default TTL is used.</param>
|
||||
/// <param name="updateExpiration">A value indicating whether the object's expiration should be extended when it is successfully retrieved.</param>
|
||||
/// <returns>A <see cref="Task{T}"/> that represents the asynchronous operation, containing the retrieved object of type <typeparamref name="T"/>, or <see langword="null"/> if the object is not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=ef3aa47 -->
|
||||
Task<T?> GetObjectAsync<T>(string key, TimeSpan? ttlOverride, bool updateExpiration);
|
||||
/// <summary>
|
||||
/// Asynchronously stores the specified object associated with the given key, using an optional time-to-live override and expiration update behavior.
|
||||
@@ -52,21 +57,25 @@ namespace adas_core.Application.Services.Interfaces
|
||||
/// <param name="ttlOverride">An optional <see cref="TimeSpan"/> that overrides the default time-to-live for the stored object.</param>
|
||||
/// <param name="updateExpiration">A value indicating whether the expiration of the stored object should be updated based on the provided TTL.</param>
|
||||
/// <returns>A <see cref="Task"/> that represents the asynchronous storage operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=85ff65d -->
|
||||
Task SetObjectAsync<T>(string key, T obj, TimeSpan? ttlOverride, bool updateExpiration);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes an object identified by the specified key.
|
||||
/// </summary>
|
||||
/// <param name="key">The unique identifier of the object to delete.</param>
|
||||
/// <!-- aidoc:v1 sig=a568485 -->
|
||||
Task DeleteObjectAsync(string key);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes entries matching the specified pattern and returns the number of deleted items.
|
||||
/// </summary>
|
||||
/// <param name="pattern">The pattern used to match the entries to be deleted.</param>
|
||||
/// <returns>A task that represents the asynchronous delete operation. The task result contains the total number of entries that were deleted.</returns>
|
||||
/// <!-- aidoc:v1 sig=d0828a6 -->
|
||||
Task<long> DeleteByPatternAsync(string pattern);
|
||||
/// <summary>
|
||||
/// Clears the application cache, removing all cached entries.
|
||||
/// </summary>
|
||||
/// <!-- aidoc:v1 sig=fe89cd5 -->
|
||||
void CleanCache();
|
||||
|
||||
|
||||
@@ -80,6 +89,7 @@ namespace adas_core.Application.Services.Interfaces
|
||||
/// <param name="loader">The asynchronous function invoked to produce the value when no cached entry exists for the specified key.</param>
|
||||
/// <param name="ttlOverride">An optional time-to-live duration that overrides the default expiration for the cached entry; when <c>null</c>, the default TTL is used.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The result is the cached or freshly loaded string value, or <c>null</c> when no value is available.</returns>
|
||||
/// <!-- aidoc:v1 sig=9201892 -->
|
||||
Task<string?> GetOrSetValueAsync(string key, Func<Task<string>> loader, TimeSpan? ttlOverride = null);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves an object associated with the specified key from the cache, or invokes the factory to create and cache a new one when the key is not found.
|
||||
@@ -89,6 +99,7 @@ namespace adas_core.Application.Services.Interfaces
|
||||
/// <param name="ttl">The optional expiration period for the cached entry; if null, the default cache lifetime is applied.</param>
|
||||
/// <param name="cancellationToken">The token used to cancel the asynchronous operation.</param>
|
||||
/// <returns>A task that resolves to the cached or newly created object of type <typeparamref name="T"/>.</returns>
|
||||
/// <!-- aidoc:v1 sig=3a49f2f -->
|
||||
Task<T> GetOrSetObjectAsync<T>(
|
||||
string key,
|
||||
Func<Task<T>> factory,
|
||||
@@ -105,6 +116,7 @@ namespace adas_core.Application.Services.Interfaces
|
||||
/// <param name="ttl">The optional time-to-live duration applied to the cached entry.</param>
|
||||
/// <param name="cancellationToken">The token to monitor for cancellation requests.</param>
|
||||
/// <returns>A task containing the cached or newly created object of type <typeparamref name="T"/>.</returns>
|
||||
/// <!-- aidoc:v1 sig=b6c9631 -->
|
||||
Task<T> GetOrSetObjectAsync<T>(
|
||||
GroupedField groupedField,
|
||||
ObjectId patientId,
|
||||
|
||||
@@ -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);
|
||||
}
|
||||
@@ -12,6 +12,7 @@ public interface ICalculatedObservationsService
|
||||
/// <param name="obs">The source <see cref="PatientObservation"/> to be mapped.</param>
|
||||
/// <param name="onlyByName">When <c>true</c>, restricts the mapping to be performed by name only; otherwise, additional criteria are used.</param>
|
||||
/// <returns>A <see cref="Task{PatientObservation}"/> that resolves to the mapped <see cref="PatientObservation"/>, or <c>null</c> if no match is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=41cebf4 -->
|
||||
Task<PatientObservation?> Map(PatientObservation obs, bool onlyByName = false);
|
||||
/// <summary>
|
||||
/// Asynchronously maps a <see cref="PatientObservationAlarm"/> instance, optionally performing the mapping
|
||||
@@ -23,41 +24,48 @@ public interface ICalculatedObservationsService
|
||||
/// full mapping logic is applied. Defaults to <c>false</c>.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the mapped
|
||||
/// <see cref="PatientObservationAlarm"/>, or <c>null</c> if no mapping is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=2a563ad -->
|
||||
Task<PatientObservationAlarm?> Map(PatientObservationAlarm obs, bool onlyByName = false);
|
||||
/// <summary>
|
||||
/// Maps a <see cref="PatientTreatment"/> instance to a projected <see cref="PatientTreatment"/> representation asynchronously.
|
||||
/// </summary>
|
||||
/// <param name="treatment">The source <see cref="PatientTreatment"/> to be mapped.</param>
|
||||
/// <returns>A <see cref="Task{PatientTreatment}"/> that represents the asynchronous mapping operation. The result is the mapped <see cref="PatientTreatment"/>, or <see langword="null"/> if no mapping could be produced.</returns>
|
||||
/// <!-- aidoc:v1 sig=05e1494 -->
|
||||
Task<PatientTreatment?> Map(PatientTreatment treatment);
|
||||
/// <summary>
|
||||
/// Maps the provided <see cref="PumpObservation"/> to a <see cref="PumpObservation"/> result, returning <see langword="null"/> when no mapping is produced.
|
||||
/// </summary>
|
||||
/// <param name="obs">The source <see cref="PumpObservation"/> to be mapped.</param>
|
||||
/// <returns>A <see cref="Task{TResult}"/> containing the mapped <see cref="PumpObservation"/>, or <see langword="null"/> if the mapping yields no result.</returns>
|
||||
/// <!-- aidoc:v1 sig=919e4c3 -->
|
||||
Task<PumpObservation?> Map(PumpObservation obs);
|
||||
/// <summary>
|
||||
/// Asynchronously maps the specified <see cref="PatientRecordingAlert"/> to a resulting <see cref="PatientRecordingAlert"/>, returning <see langword="null"/> when no mapping is produced.
|
||||
/// </summary>
|
||||
/// <param name="obs">The source <see cref="PatientRecordingAlert"/> instance to map.</param>
|
||||
/// <returns>A <see cref="Task{TResult}"/> that contains the mapped <see cref="PatientRecordingAlert"/>, or <see langword="null"/> if the source cannot be mapped.</returns>
|
||||
/// <!-- aidoc:v1 sig=2805400 -->
|
||||
Task<PatientRecordingAlert?> Map(PatientRecordingAlert obs);
|
||||
/// <summary>
|
||||
/// Maps a <see cref="PatientDiagnosis"/> instance to its corresponding representation, returning <see langword="null"/> when no mapping is available.
|
||||
/// </summary>
|
||||
/// <param name="obs">The source <see cref="PatientDiagnosis"/> to map.</param>
|
||||
/// <returns>A <see cref="Task{T}"/> containing the mapped <see cref="PatientDiagnosis"/>, or <see langword="null"/> if the source cannot be mapped.</returns>
|
||||
/// <!-- aidoc:v1 sig=c9284b0 -->
|
||||
Task<PatientDiagnosis?> Map(PatientDiagnosis obs);
|
||||
/// <summary>
|
||||
/// Maps a list of patient observations for insertion, returning the transformed list asynchronously.
|
||||
/// </summary>
|
||||
/// <param name="listToInsert">The list of patient observations to be mapped for insertion.</param>
|
||||
/// <returns>A task representing the asynchronous operation, containing the mapped list of patient observations.</returns>
|
||||
/// <!-- aidoc:v1 sig=619bfe1 -->
|
||||
Task<List<PatientObservation>> MapList(List<PatientObservation> listToInsert);
|
||||
/// <summary>
|
||||
/// Asynchronously calculates the bolus dose of opiates for the specified patient.
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient for whom the bolus opiates calculation is performed.</param>
|
||||
/// <!-- aidoc:v1 sig=859008a -->
|
||||
Task CalculateBolusOpiates(ObjectId patientId);
|
||||
/// <summary>
|
||||
/// Asynchronously calculates medicine observations for a patient based on their active medicines.
|
||||
@@ -65,12 +73,14 @@ public interface ICalculatedObservationsService
|
||||
/// <param name="activeMedicines">The list of medicines currently active for the patient.</param>
|
||||
/// <param name="patientId">The unique identifier of the patient.</param>
|
||||
/// <returns>A task that represents the asynchronous calculation operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=341d0d1 -->
|
||||
Task CalculateMedicineObservation(List<Medicine> activeMedicines, ObjectId patientId);
|
||||
/// <summary>
|
||||
/// Retrieves the active patient treatments associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the patient whose active treatments are being requested.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing an enumerable collection of active PatientTreatment entries for the patient.</returns>
|
||||
/// <!-- aidoc:v1 sig=9eb0d98 -->
|
||||
Task<IEnumerable<PatientTreatment?>> GetActiveTreatmentsByPatient(ObjectId id);
|
||||
/// <summary>
|
||||
/// Maps a source alarm from a <see cref="PatientObservationAlarm"/> onto a <see cref="PatientObservation"/>, producing an observation enriched with the corresponding alarm information.
|
||||
@@ -78,5 +88,6 @@ public interface ICalculatedObservationsService
|
||||
/// <param name="observation">The patient observation that serves as the base for the mapping.</param>
|
||||
/// <param name="observationAlarm">The source alarm whose data is mapped onto the observation.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the <see cref="PatientObservation"/> populated with the mapped alarm data.</returns>
|
||||
/// <!-- aidoc:v1 sig=1c0c4ce -->
|
||||
Task<PatientObservation> MapSourceAlarm(PatientObservation observation, PatientObservationAlarm observationAlarm);
|
||||
}
|
||||
@@ -12,24 +12,28 @@ public interface ICameraService
|
||||
/// </summary>
|
||||
/// <param name="relayId">The unique identifier of the relay used to look up the camera.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the <see cref="Camera"/> if a matching record is found; otherwise, <c>null</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=dcfdfde -->
|
||||
Task<Camera?> GetById(ObjectId relayId);
|
||||
/// <summary>
|
||||
/// Retrieves the list of cameras associated with the specified configuration relay identifiers.
|
||||
/// </summary>
|
||||
/// <param name="configurationRelayList">The list of configuration relay object identifiers used to look up the associated cameras.</param>
|
||||
/// <returns>A list of cameras that correspond to the provided configuration relay identifiers.</returns>
|
||||
/// <!-- aidoc:v1 sig=4523ee6 -->
|
||||
List<Camera> GetCameraInList(List<ObjectId> configurationRelayList);
|
||||
/// <summary>
|
||||
/// Retrieves a paginated list of cameras based on the provided pagination filter.
|
||||
/// </summary>
|
||||
/// <param name="request">The pagination filter containing the page size, page number, and optional search criteria used to query cameras.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a <see cref="PaginationResponse{Camera}"/> with the requested page of cameras and pagination metadata.</returns>
|
||||
/// <!-- aidoc:v1 sig=3886498 -->
|
||||
Task<PaginationResponse<Camera>> GetPaginatedCameras(PaginationFilter request);
|
||||
/// <summary>
|
||||
/// Inserts a new camera into the system asynchronously.
|
||||
/// </summary>
|
||||
/// <param name="camera">The camera entity to insert.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the inserted camera with its generated identifier, or <c>null</c> if the camera could not be inserted.</returns>
|
||||
/// <!-- aidoc:v1 sig=7c18638 -->
|
||||
Task<Camera?> InsertCamera(Camera camera);
|
||||
/// <summary>
|
||||
/// Updates an existing camera identified by the specified object identifier with the provided camera data.
|
||||
@@ -38,17 +42,20 @@ public interface ICameraService
|
||||
/// <param name="objectId">The unique identifier of the camera to update.</param>
|
||||
/// <param name="camera">The camera data containing the updated values to apply.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the updated camera, or <see langword="null"/> if the camera was not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=cb8ad73 -->
|
||||
Task<Camera?> UpdateCameraById(ObjectId objectId, Camera camera);
|
||||
/// <summary>
|
||||
/// Deletes a camera identified by the specified object identifier.
|
||||
/// </summary>
|
||||
/// <param name="objectId">The unique identifier of the camera to delete.</param>
|
||||
/// <returns>A task that represents the asynchronous delete operation. The result is <c>true</c> if the camera was successfully deleted; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=7b8b4e5 -->
|
||||
Task<bool> DeleteCamera(ObjectId objectId);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a list of cameras whose names match the specified search text.
|
||||
/// </summary>
|
||||
/// <param name="textToSearch">The text used to search camera names.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of <see cref="Camera"/> objects matching the search criteria; an empty list is returned if no matches are found.</returns>
|
||||
/// <!-- aidoc:v1 sig=b1c98a2 -->
|
||||
Task<List<Camera>> GetSearchByNameCameras(string textToSearch);
|
||||
}
|
||||
@@ -13,6 +13,7 @@ public interface IClientMessageService
|
||||
/// <param name="type">The optional operation type used to classify the message.</param>
|
||||
/// <param name="msg">The optional message payload to be sent.</param>
|
||||
/// <returns>A task that represents the asynchronous send operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=3c62336 -->
|
||||
Task SendAsync(string receiverId, OperationType? type, object? msg);
|
||||
/// <summary>
|
||||
/// Asynchronously broadcasts a message of the specified operation type to all connected recipients.
|
||||
@@ -20,16 +21,20 @@ public interface IClientMessageService
|
||||
/// <param name="type">The operation type that classifies the broadcast message.</param>
|
||||
/// <param name="msg">The message payload to send, or <c>null</c> when no payload is required.</param>
|
||||
/// <returns>A task that represents the asynchronous broadcast operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=e5d4ff6 -->
|
||||
Task SendToAllAsync(OperationType type, object? msg);
|
||||
/// <summary>
|
||||
/// Processes an incoming message within the context of the specified connection.
|
||||
/// </summary>
|
||||
/// <param name="msg">The message to be processed.</param>
|
||||
/// <param name="contextConnectionId">The identifier of the connection context associated with the message.</param>
|
||||
/// <!-- aidoc-review:v1 severity=medium kind=missing_returns
|
||||
/// "Method returns Task (indicating asynchronous processing) but no <returns> tag is present to describe the returned task." -->
|
||||
Task ProcessMessage(Message msg, string contextConnectionId);
|
||||
/// <summary>
|
||||
/// Sends an update message to the specified list of patient location boxes.
|
||||
/// </summary>
|
||||
/// <param name="boxes">The list of patient locations that will receive the update message.</param>
|
||||
/// <!-- aidoc:v1 sig=4a52d06 -->
|
||||
void SendUpdateMessageToBoxes(List<PatientLocation> boxes);
|
||||
}
|
||||
@@ -19,6 +19,7 @@ public interface IConfigObservationService
|
||||
/// <param name="codingSystem">The coding system used to identify the configuration observation (e.g., ICD, SNOMED).</param>
|
||||
/// <param name="code">The code within the given coding system that uniquely identifies the configuration observation.</param>
|
||||
/// <returns>A <see cref="ConfigObservation"/> if a match is found; otherwise, <c>null</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=b4251de -->
|
||||
Task<ConfigObservation?> GetByCodeSysAndCode(string codingSystem, string code);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a <see cref="ConfigObservation"/> identified by the given name.
|
||||
@@ -26,6 +27,7 @@ public interface IConfigObservationService
|
||||
/// </summary>
|
||||
/// <param name="name">The name of the configuration observation to retrieve.</param>
|
||||
/// <returns>A <see cref="Task{TResult}"/> that yields the matching <see cref="ConfigObservation"/>, or <see langword="null"/> if no observation is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=f39308c -->
|
||||
Task<ConfigObservation?> Get(string name);
|
||||
|
||||
/// <summary>
|
||||
@@ -34,6 +36,7 @@ public interface IConfigObservationService
|
||||
/// <param name="obs">The patient observation whose corresponding configuration observation is being requested.</param>
|
||||
/// <param name="onlyByName">When <c>true</c>, limits the lookup to a name-based match; otherwise, other matching criteria may be applied.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the matching <see cref="ConfigObservation"/>, or <c>null</c> if no matching observation is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=5d51beb -->
|
||||
Task<ConfigObservation?> Get<T>(T obs, bool onlyByName = false) where T : BasePatientObservation;
|
||||
|
||||
/// <summary>
|
||||
@@ -41,6 +44,7 @@ public interface IConfigObservationService
|
||||
/// </summary>
|
||||
/// <param name="obs">The patient observation of type <typeparamref name="T"/> on which retention actions will be executed.</param>
|
||||
/// <returns>A task that represents the asynchronous retention operation. The task result contains the <see cref="ObservatitonRetentionResult"/> produced by the retention actions, or <c>null</c> when no retention result is produced.</returns>
|
||||
/// <!-- aidoc:v1 sig=67748d9 -->
|
||||
Task<ObservatitonRetentionResult?> RetentionActions<T>(T obs) where T : BasePatientObservation;
|
||||
/// <summary>
|
||||
/// Maps a patient observation to a corresponding target observation of the same type, optionally restricting the lookup to name-based matching only.
|
||||
@@ -48,12 +52,14 @@ public interface IConfigObservationService
|
||||
/// <param name="obs">The source patient observation to be mapped.</param>
|
||||
/// <param name="onlyByName">When set to <c>true</c>, the mapping is performed using the observation's name only; otherwise, additional matching criteria are considered. Defaults to <c>false</c>.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the mapped patient observation of type <typeparamref name="T"/>, or <c>null</c> if no matching observation is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=7c2c1e5 -->
|
||||
Task<T?> Map<T>(T obs, bool onlyByName = false) where T : BasePatientObservation;
|
||||
/// <summary>
|
||||
/// Asynchronously maps the specified <see cref="PatientTreatment"/> to a populated <see cref="PatientTreatment"/> instance, returning <see langword="null"/> when the treatment cannot be resolved.
|
||||
/// </summary>
|
||||
/// <param name="treatment">The <see cref="PatientTreatment"/> to be mapped.</param>
|
||||
/// <returns>A <see cref="Task{TResult}"/> that yields the mapped <see cref="PatientTreatment"/>, or <see langword="null"/> if no mapping result is available.</returns>
|
||||
/// <!-- aidoc:v1 sig=05e1494 -->
|
||||
Task<PatientTreatment?> Map(PatientTreatment treatment);
|
||||
|
||||
/// <summary>
|
||||
@@ -66,6 +72,7 @@ public interface IConfigObservationService
|
||||
/// <param name="min">The optional minimum threshold for the value.</param>
|
||||
/// <param name="max">The optional maximum threshold for the value.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the evaluated <see cref="StatusEnum.Type"/> for the grouped observation.</returns>
|
||||
/// <!-- aidoc:v1 sig=4f9fc90 -->
|
||||
Task<StatusEnum.Type> GroupedObservationStatus(GroupedField groupedField, GroupedObservationEnum.Result result,
|
||||
string name, object value, double? min, double? max);
|
||||
|
||||
@@ -74,64 +81,75 @@ public interface IConfigObservationService
|
||||
/// </summary>
|
||||
/// <param name="ct">The cancellation token used to cancel the asynchronous operation.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a collection of <see cref="ConfigObservation"/> objects representing all available configurations.</returns>
|
||||
/// <!-- aidoc:v1 sig=c9e275b -->
|
||||
Task<ICollection<ConfigObservation>> GetAllConfigs(CancellationToken ct = default);
|
||||
/// <summary>
|
||||
/// Retrieves a paginated collection of <see cref="ConfigObservation"/> items based on the supplied filter criteria.
|
||||
/// </summary>
|
||||
/// <param name="filter">The pagination filter that defines the page size, page number, and query criteria used to retrieve the configuration observations.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a <see cref="PaginationResponse{ConfigObservation}"/> with the requested items and pagination metadata.</returns>
|
||||
/// <!-- aidoc:v1 sig=2a96e75 -->
|
||||
Task<PaginationResponse<ConfigObservation>> GetPaginatedItems(PaginationFilter filter);
|
||||
/// <summary>
|
||||
/// Retrieves all configuration observations in a compact format.
|
||||
/// </summary>
|
||||
/// <returns>A task representing the asynchronous operation that returns a <see cref="ConfigObservationDto"/> containing the compact representation of all configuration observations.</returns>
|
||||
/// <!-- aidoc:v1 sig=474ef97 -->
|
||||
Task<ConfigObservationDto> GetAllCompact();
|
||||
/// <summary>
|
||||
/// Retrieves a configuration observation by its unique identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the configuration observation to retrieve.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the <see cref="ConfigObservation"/> if a matching record is found, or <c>null</c> if no configuration exists for the specified id.</returns>
|
||||
/// <!-- aidoc:v1 sig=aacda16 -->
|
||||
Task<ConfigObservation?> GetConfigById(ObjectId id);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a list of configuration names associated with the specified identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The identifier used to look up the associated configuration names.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of configuration names.</returns>
|
||||
/// <!-- aidoc:v1 sig=e20bf71 -->
|
||||
Task<List<string>> GetConfigNames(string id);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the list of available configuration names.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of configuration names.</returns>
|
||||
/// <!-- aidoc:v1 sig=45b7793 -->
|
||||
Task<List<string>> GetConfigNames();
|
||||
/// <summary>
|
||||
/// Updates an existing configuration observation and returns the updated result.
|
||||
/// </summary>
|
||||
/// <param name="configObservation">The configuration observation containing the data to update.</param>
|
||||
/// <returns>A task that resolves to the updated <see cref="ConfigObservation"/>, or <c>null</c> when no matching configuration is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=15fa841 -->
|
||||
Task<ConfigObservation?> UpdateConfig(ConfigObservation configObservation);
|
||||
/// <summary>
|
||||
/// Asynchronously creates a new configuration based on the provided observation data.
|
||||
/// </summary>
|
||||
/// <param name="configObservation">The observation data used to create the configuration.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the created <see cref="ConfigObservation"/>, or <c>null</c> if the configuration could not be created.</returns>
|
||||
/// <!-- aidoc:v1 sig=9317e04 -->
|
||||
Task<ConfigObservation?> CreateConfig(ConfigObservation configObservation);
|
||||
/// <summary>
|
||||
/// Asynchronously removes the configuration item with the specified name.
|
||||
/// </summary>
|
||||
/// <param name="itemName">The name of the configuration item to remove.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a <see cref="ConfigObservation"/> describing the removed item, or <c>null</c> if no matching item was found.</returns>
|
||||
/// <!-- aidoc:v1 sig=ce6276e -->
|
||||
Task<ConfigObservation?> RemoveConfigItem(string itemName);
|
||||
/// <summary>
|
||||
/// Asynchronously removes the configuration item identified by the specified identifier and returns the resulting observation.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the configuration item to remove.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the <see cref="ConfigObservation"/> describing the removed configuration item, or <c>null</c> if no matching item was found.</returns>
|
||||
/// <!-- aidoc:v1 sig=9730dbb -->
|
||||
Task<ConfigObservation?> RemoveConfigItem(ObjectId id);
|
||||
/// <summary>
|
||||
/// Retrieves the configuration observation items associated with the specified name.
|
||||
/// </summary>
|
||||
/// <param name="name">The name used to look up the configuration observation items.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The result contains a collection of <see cref="ConfigObservation"/> items matching the provided name, or <c>null</c> if no matching items are found.</returns>
|
||||
/// <!-- aidoc:v1 sig=3cb29fa -->
|
||||
Task<IEnumerable<ConfigObservation>?> GetConfigObservationItem(string name);
|
||||
|
||||
/// <summary>
|
||||
@@ -142,6 +160,7 @@ public interface IConfigObservationService
|
||||
/// <param name="name">The name of the configuration observation item.</param>
|
||||
/// <param name="originalName">The original name of the configuration observation item.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the matching <see cref="ConfigObservation"/>, or <c>null</c> if no item is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=2c7c75f -->
|
||||
Task<ConfigObservation?> GetSingleConfigObservationItem(string? code, string? codingSystem, string? name,
|
||||
string? originalName);
|
||||
|
||||
@@ -150,11 +169,13 @@ public interface IConfigObservationService
|
||||
/// </summary>
|
||||
/// <param name="configObservationItem">The configuration observation item to be deleted.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a boolean value indicating whether the deletion was successful.</returns>
|
||||
/// <!-- aidoc:v1 sig=1f61b9b -->
|
||||
Task<bool> DeleteSingleConfigObservationItem(ConfigObservation configObservationItem);
|
||||
/// <summary>
|
||||
/// Retrieves configuration observation items that match the specified name.
|
||||
/// </summary>
|
||||
/// <param name="name">The name used to filter the configuration observation items.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the collection of <see cref="ConfigObservation"/> items matching the specified name.</returns>
|
||||
/// <!-- aidoc:v1 sig=69b9196 -->
|
||||
Task<IEnumerable<ConfigObservation>> GetConfigObservationItemsByName(string name);
|
||||
}
|
||||
@@ -11,11 +11,13 @@ public interface IConfigPumpsService
|
||||
/// </summary>
|
||||
/// <param name="obs">The source PumpObservation to be mapped.</param>
|
||||
/// <returns>A task that represents the asynchronous mapping operation, containing the resulting PumpObservation.</returns>
|
||||
/// <!-- aidoc:v1 sig=e90f6a3 -->
|
||||
Task<PumpObservation> Map(PumpObservation obs);
|
||||
/// <summary>
|
||||
/// Retrieves all available pump configurations from the configuration store.
|
||||
/// </summary>
|
||||
/// <returns>A task containing a list of <see cref="ConfigPumps"/> with all pump configurations, or <c>null</c> if no configurations are available.</returns>
|
||||
/// <!-- aidoc:v1 sig=02da65c -->
|
||||
Task<List<ConfigPumps>?> GetAllPumpConfigs();
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the configuration pump items associated with the specified identifier.
|
||||
@@ -23,36 +25,42 @@ public interface IConfigPumpsService
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier used to look up the configuration items.</param>
|
||||
/// <returns>A task containing a list of ConfigPumpItem objects if found, or null if no items exist for the specified id.</returns>
|
||||
/// <!-- aidoc:v1 sig=f88a8a5 -->
|
||||
Task<List<ConfigPumpItem>?> GetConfigItems(string id);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the pump configuration that matches the specified identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the pump configuration to look up.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the matching <see cref="ConfigPumps"/> configuration if found; otherwise, <c>null</c> when no configuration exists for the given identifier.</returns>
|
||||
/// <!-- aidoc:v1 sig=6e00a1d -->
|
||||
Task<ConfigPumps?> GetPumpConfigById(string id);
|
||||
/// <summary>
|
||||
/// Updates the pump configuration asynchronously and returns the updated configuration.
|
||||
/// </summary>
|
||||
/// <param name="pumpConfig">The pump configuration to update.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the updated <see cref="ConfigPumps"/>, or <c>null</c> if the configuration was not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=8810f19 -->
|
||||
Task<ConfigPumps?> UpdatePumpConfig(ConfigPumps pumpConfig);
|
||||
/// <summary>
|
||||
/// Inserts a new pump configuration into the data store.
|
||||
/// </summary>
|
||||
/// <param name="pumpConfig">The pump configuration to insert.</param>
|
||||
/// <returns>The inserted <see cref="ConfigPumps"/> entity, or <c>null</c> if the insertion was not performed.</returns>
|
||||
/// <!-- aidoc:v1 sig=65d91df -->
|
||||
Task<ConfigPumps?> InsertPumpConfig(ConfigPumps pumpConfig);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes the specified pump configuration.
|
||||
/// </summary>
|
||||
/// <param name="config">The pump configuration to delete.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a boolean indicating whether the deletion was successful.</returns>
|
||||
/// <!-- aidoc:v1 sig=ce3f871 -->
|
||||
Task<bool> DeletePumpConfig(ConfigPumps config);
|
||||
/// <summary>
|
||||
/// Asynchronously evaluates and applies retention actions for a pump observation, returning the resulting retention outcome.
|
||||
/// </summary>
|
||||
/// <param name="obs">The pump observation to process for retention actions.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the retention result, or null if no retention action applies.</returns>
|
||||
/// <!-- aidoc:v1 sig=9f98a57 -->
|
||||
Task<ObservatitonRetentionResult?> RetentionActions(PumpObservation obs);
|
||||
|
||||
}
|
||||
@@ -11,11 +11,13 @@ public interface IConfigUnitsService
|
||||
/// <typeparam name="T">The specific patient observation type, constrained to <see cref="BasePatientObservation"/>.</typeparam>
|
||||
/// <param name="obs">The patient observation instance to be mapped.</param>
|
||||
/// <returns>A task that represents the asynchronous mapping operation, yielding the mapped patient observation.</returns>
|
||||
/// <!-- aidoc:v1 sig=f302314 -->
|
||||
Task<T> Map<T>(T obs) where T : BasePatientObservation;
|
||||
/// <summary>
|
||||
/// Asynchronously maps the specified <see cref="PumpObservation"/> to a resulting <see cref="PumpObservation"/>.
|
||||
/// </summary>
|
||||
/// <param name="obs">The pump observation to be mapped.</param>
|
||||
/// <returns>A task that represents the asynchronous mapping operation, containing the resulting <see cref="PumpObservation"/>.</returns>
|
||||
/// <!-- aidoc:v1 sig=e90f6a3 -->
|
||||
Task<PumpObservation> Map(PumpObservation obs);
|
||||
}
|
||||
@@ -11,18 +11,21 @@ public interface IDeviceService
|
||||
/// </summary>
|
||||
/// <param name="device">The data transfer object containing the information used to create the device.</param>
|
||||
/// <returns>A task that represents the asynchronous create operation. The task result contains the created <see cref="Device"/>, or <see langword="null"/> if the device could not be created.</returns>
|
||||
/// <!-- aidoc:v1 sig=f960817 -->
|
||||
Task<Device?> Create(DeviceDto device);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes the object identified by the specified identifier.
|
||||
/// </summary>
|
||||
/// <param name="objectId">The unique identifier of the object to delete.</param>
|
||||
/// <returns>A task that represents the asynchronous delete operation. The result is <c>true</c> if the object was deleted; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=9c1b1e3 -->
|
||||
Task<bool> Delete(ObjectId objectId);
|
||||
/// <summary>
|
||||
/// Updates an existing device using the provided data transfer object.
|
||||
/// </summary>
|
||||
/// <param name="device">The data transfer object containing the updated device information.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the updated device, or <c>null</c> if the device was not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=74ac7b4 -->
|
||||
Task<Device?> Update(DeviceDto device);
|
||||
/// <summary>
|
||||
/// Processes an incoming event for the specified device and returns the associated <see cref="Device"/>.
|
||||
@@ -30,5 +33,6 @@ public interface IDeviceService
|
||||
/// </summary>
|
||||
/// <param name="device">The device data transfer object carrying the event information to be processed.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the resolved <see cref="Device"/> or <c>null</c> if no matching device was found.</returns>
|
||||
/// <!-- aidoc:v1 sig=4985fb0 -->
|
||||
Task<Device?> ReceiveEvent(DeviceDto device);
|
||||
}
|
||||
@@ -11,33 +11,39 @@ public interface IDiagnosisService : IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose diagnoses are being retrieved.</param>
|
||||
/// <returns>A task representing the asynchronous operation, containing a list of <see cref="PatientDiagnosis"/> records for the specified patient; an empty list is returned if no diagnoses are found.</returns>
|
||||
/// <!-- aidoc:v1 sig=002b366 -->
|
||||
Task<List<PatientDiagnosis>> GetByPatientId(ObjectId patientId);
|
||||
/// <summary>
|
||||
/// Deletes records associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the patient whose related records should be removed.</param>
|
||||
/// <!-- aidoc:v1 sig=d457cb9 -->
|
||||
Task DeleteByPatientId(ObjectId id);
|
||||
/// <summary>
|
||||
/// Asynchronously archives the specified patient, marking the patient record as archived rather than permanently deleting it.
|
||||
/// </summary>
|
||||
/// <param name="patient">The patient to archive.</param>
|
||||
/// <!-- aidoc:v1 sig=52c2373 -->
|
||||
Task Archive(Patient patient);
|
||||
/// <summary>
|
||||
/// Archives the records associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the patient whose records will be archived.</param>
|
||||
/// <!-- aidoc:v1 sig=e5916ec -->
|
||||
Task ArchiveByPatientId(ObjectId id);
|
||||
/// <summary>
|
||||
/// Processes a diagnosis observation for the specified patient based on the supplied API request data.
|
||||
/// </summary>
|
||||
/// <param name="apiRequest">The API request containing the diagnosis observation payload and contextual information to process.</param>
|
||||
/// <param name="patient">The patient to whom the diagnosis observation pertains.</param>
|
||||
/// <!-- aidoc:v1 sig=c6a1fc2 -->
|
||||
Task ProcessDiagnosisObservation(ApiRequest apiRequest, Patient patient);
|
||||
/// <summary>
|
||||
/// Persists the specified API request along with its associated patient data.
|
||||
/// </summary>
|
||||
/// <param name="apiRequest">The API request to be saved.</param>
|
||||
/// <param name="patient">The patient associated with the API request.</param>
|
||||
/// <!-- aidoc:v1 sig=565473c -->
|
||||
Task SaveRequest(ApiRequest apiRequest, Patient patient);
|
||||
/// <summary>
|
||||
/// Processes the provided list of patient diagnoses for the specified patient at the given message time.
|
||||
@@ -45,6 +51,7 @@ public interface IDiagnosisService : IApiRequestService
|
||||
/// <param name="diagnosis">The list of patient diagnoses to be processed.</param>
|
||||
/// <param name="patient">The patient associated with the diagnoses.</param>
|
||||
/// <param name="messageTime">The timestamp of the message triggering the diagnosis processing.</param>
|
||||
/// <!-- aidoc:v1 sig=c62208b -->
|
||||
Task ProcessDiagnosis(List<PatientDiagnosis> diagnosis, Patient patient, DateTime messageTime);
|
||||
/// <summary>
|
||||
/// Updates multiple records by replacing the <paramref name="oldId"/> with the new <paramref name="id"/> in the field identified by <paramref name="nameId"/>.
|
||||
@@ -52,5 +59,6 @@ public interface IDiagnosisService : IApiRequestService
|
||||
/// <param name="nameId">The identifier of the field or property whose ObjectId values will be updated.</param>
|
||||
/// <param name="id">The new ObjectId value to assign to the matching records.</param>
|
||||
/// <param name="oldId">The existing ObjectId value to be replaced in the matching records.</param>
|
||||
/// <!-- aidoc:v1 sig=24ef97c -->
|
||||
Task UpdateManyObjectId(string nameId, ObjectId id, ObjectId oldId);
|
||||
}
|
||||
@@ -14,56 +14,66 @@ public interface IDischargeService : IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="dischargeId">The unique identifier of the discharge to look up.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the <see cref="Discharge"/> if found, or null when no record matches the provided identifier.</returns>
|
||||
/// <!-- aidoc:v1 sig=5d8f706 -->
|
||||
Task<Discharge?> GetDischargeByIdAsync(ObjectId dischargeId);
|
||||
/// <summary>
|
||||
/// Asynchronously counts the number of discharge records associated with the specified unit.
|
||||
/// </summary>
|
||||
/// <param name="unitId">The identifier of the unit whose discharges should be counted.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the total number of discharges for the specified unit.</returns>
|
||||
/// <!-- aidoc:v1 sig=f2e3592 -->
|
||||
Task<long> CountDischargesByUnitId(ObjectId unitId);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes a discharge record identified by the specified identifier.
|
||||
/// </summary>
|
||||
/// <param name="dischargeId">The unique identifier of the discharge to delete.</param>
|
||||
/// <!-- aidoc:v1 sig=717b98a -->
|
||||
Task DeleteDischargeByIdAsync(ObjectId dischargeId);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes the specified discharge record.
|
||||
/// </summary>
|
||||
/// <param name="discharge">The discharge entity to be removed.</param>
|
||||
/// <!-- aidoc:v1 sig=a368605 -->
|
||||
Task DeleteDischargeAsync(Discharge discharge);
|
||||
/// <summary>
|
||||
/// Asynchronously updates an existing discharge record in the data store.
|
||||
/// </summary>
|
||||
/// <param name="discharge">The <see cref="Discharge"/> entity containing the updated information to persist.</param>
|
||||
/// <!-- aidoc:v1 sig=5401c24 -->
|
||||
Task UpdateDischargeAsync(Discharge discharge);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a collection of discharge records.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains an enumerable collection of <see cref="Discharge"/> objects.</returns>
|
||||
/// <!-- aidoc:v1 sig=41d8002 -->
|
||||
Task<IEnumerable<Discharge>> GetDischargesAsync();
|
||||
/// <summary>
|
||||
/// Inserts a new discharge record into the data store. Returns the inserted <see cref="Discharge"/> entity, or <see langword="null"/> if the record could not be created.
|
||||
/// </summary>
|
||||
/// <param name="discharge">The <see cref="Discharge"/> entity containing the data to be inserted.</param>
|
||||
/// <returns>A <see cref="Task{T}"/> that resolves to the inserted <see cref="Discharge"/>, or <see langword="null"/> when the insertion does not produce a result.</returns>
|
||||
/// <!-- aidoc:v1 sig=b5ed14b -->
|
||||
Task<Discharge?> InsertDischarge(Discharge discharge);
|
||||
/// <summary>
|
||||
/// Retrieves the discharge record associated with the specified patient location, returning null if no matching discharge is found.
|
||||
/// </summary>
|
||||
/// <param name="location">The patient location used to look up the discharge record.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the matching <see cref="Discharge"/> if found, or null if no discharge is associated with the specified location.</returns>
|
||||
/// <!-- aidoc:v1 sig=8da289b -->
|
||||
Task<Discharge?> GetDischargeByLocation(PatientLocation location);
|
||||
/// <summary>
|
||||
/// Retrieves the discharge record associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose discharge record is being requested.</param>
|
||||
/// <returns>A <see cref="Task{Discharge}"/> that resolves to the matching <see cref="Discharge"/> if found; otherwise, <c>null</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=baed031 -->
|
||||
Task<Discharge?> GetDischargeByPatientId(ObjectId patientId);
|
||||
/// <summary>
|
||||
/// Retrieves a discharge record associated with the specified point of care location identifier.
|
||||
/// </summary>
|
||||
/// <param name="location">The ObjectId of the point of care location used to look up the discharge.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the matching <see cref="Discharge"/> if found, or <c>null</c> if no discharge exists for the specified point of care location.</returns>
|
||||
/// <!-- aidoc:v1 sig=fba113c -->
|
||||
Task<Discharge?> GetDischargeByPointOfCareId(ObjectId location);
|
||||
/// <summary>
|
||||
/// Retrieves the discharge associated with the specified point of care location, returning localized data for the requested locale.
|
||||
@@ -72,12 +82,14 @@ public interface IDischargeService : IApiRequestService
|
||||
/// <param name="location">The identifier of the point of care location whose discharge should be retrieved.</param>
|
||||
/// <param name="dataLocale">The locale used to determine the language of the returned discharge data.</param>
|
||||
/// <returns>A task containing the matching <see cref="Discharge"/>, or null if no discharge exists for the given location.</returns>
|
||||
/// <!-- aidoc:v1 sig=3b965d9 -->
|
||||
Task<Discharge?> GetDischargeByPointOfCareIdWithLocale(ObjectId location, LocaleEnum dataLocale);
|
||||
/// <summary>
|
||||
/// Sends a broadcast notification for the specified discharge based on the given operation type.
|
||||
/// </summary>
|
||||
/// <param name="discharge">The discharge entity to be included in the broadcast.</param>
|
||||
/// <param name="operation">The type of operation (e.g., create, update, delete) that determines the broadcast context.</param>
|
||||
/// <!-- aidoc:v1 sig=d7c2e1f -->
|
||||
void SendDischargeBroadcast(Discharge discharge, OperationType operation);
|
||||
/// <summary>
|
||||
/// Updates a patient master list item change using the provided update options, applying the change across the specified unit list and master list type.
|
||||
@@ -85,6 +97,7 @@ public interface IDischargeService : IApiRequestService
|
||||
/// <param name="opt">The update options describing the change to apply to the patient master list item.</param>
|
||||
/// <param name="unitList">The collection of units to which the master list item change should be applied.</param>
|
||||
/// <param name="typeName">The name of the master list type that identifies which list the item belongs to.</param>
|
||||
/// <!-- aidoc:v1 sig=6d7dd8e -->
|
||||
Task UpdatePatientMasterListItemChange(UpdateOptionMasterListDto opt, IEnumerable<Unit> unitList, string typeName);
|
||||
/// <summary>
|
||||
/// Deletes the specified patient master list item associated with the given option list and units.
|
||||
@@ -93,10 +106,12 @@ public interface IDischargeService : IApiRequestService
|
||||
/// <param name="unitList">The collection of units associated with the item to be deleted.</param>
|
||||
/// <param name="typeName">The name of the type used to identify the patient master list item.</param>
|
||||
/// <returns>A task that represents the asynchronous delete operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=bbc71d1 -->
|
||||
Task DeletePatientMasterListItem(OptionList opt, IEnumerable<Unit> unitList, string typeName);
|
||||
/// <summary>
|
||||
/// Deletes discharge records associated with the specified unit identifier.
|
||||
/// </summary>
|
||||
/// <param name="unitId">The unique identifier of the unit whose discharge records should be removed.</param>
|
||||
/// <!-- aidoc:v1 sig=df1942b -->
|
||||
Task DeleteDischargesByUnitId(ObjectId unitId);
|
||||
}
|
||||
@@ -14,24 +14,28 @@ public interface IDisplayConfigService
|
||||
/// Retrieves all display configurations asynchronously.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of all <see cref="DisplayConfig"/> entries.</returns>
|
||||
/// <!-- aidoc:v1 sig=0650c45 -->
|
||||
Task<List<DisplayConfig>> GetAll();
|
||||
/// <summary>
|
||||
/// Retrieves a paginated list of display configurations in a compact (minimal) representation.
|
||||
/// </summary>
|
||||
/// <param name="request">The pagination filter that controls page size, page number, and sorting criteria.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a <see cref="PaginationResponse{T}"/> with the compact display configuration entries.</returns>
|
||||
/// <!-- aidoc:v1 sig=1dc5924 -->
|
||||
Task<PaginationResponse<DisplayConfigMinimalResponse>> GetAllCompactPaginated(PaginationFilter request);
|
||||
/// <summary>
|
||||
/// Retrieves a list of display configurations filtered by the specified display type.
|
||||
/// </summary>
|
||||
/// <param name="type">The display type used to filter the configurations.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="DisplayConfig"/> objects matching the specified type.</returns>
|
||||
/// <!-- aidoc:v1 sig=2f20b32 -->
|
||||
Task<List<DisplayConfig>> GetByType(DisplayConfigEnums.DisplayType type);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a <see cref="DisplayConfig"/> by its identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the display configuration to retrieve.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the <see cref="DisplayConfig"/> matching the specified identifier.</returns>
|
||||
/// <!-- aidoc:v1 sig=fad8438 -->
|
||||
Task<DisplayConfig> GetById(ObjectId id);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a <see cref="DisplayConfig"/> identified by the specified configuration identifier, unit identifier, and display type.
|
||||
@@ -40,23 +44,27 @@ public interface IDisplayConfigService
|
||||
/// <param name="unitId">The identifier of the unit the display configuration belongs to.</param>
|
||||
/// <param name="displayType">The display type used to filter or scope the lookup.</param>
|
||||
/// <returns>A <see cref="Task{DisplayConfig}"/> that resolves to the matching <see cref="DisplayConfig"/>, or <c>null</c> if no configuration is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=fecb3b8 -->
|
||||
Task<DisplayConfig?> GetById(ObjectId? configId, ObjectId unitId, DisplayConfigEnums.DisplayType displayType);
|
||||
/// <summary>
|
||||
/// Inserts a single display configuration asynchronously and returns the resulting configuration, or null when no record is produced.
|
||||
/// </summary>
|
||||
/// <param name="config">The display configuration to insert.</param>
|
||||
/// <returns>A task that represents the asynchronous insert operation, containing the inserted <see cref="DisplayConfig"/> or null.</returns>
|
||||
/// <!-- aidoc:v1 sig=aa331a5 -->
|
||||
Task<DisplayConfig?> InsertOne(DisplayConfig config);
|
||||
/// <summary>
|
||||
/// Inserts a new display configuration in a minimal fashion and returns the created <see cref="DisplayConfig"/>, or <c>null</c> when no configuration could be produced.
|
||||
/// </summary>
|
||||
/// <param name="config">The data transfer object containing the values used to create the new display configuration.</param>
|
||||
/// <returns>A <see cref="Task{TResult}"/> that yields the created <see cref="DisplayConfig"/> when successful, or <c>null</c> when no result is available.</returns>
|
||||
/// <!-- aidoc:v1 sig=8e1aa52 -->
|
||||
Task<DisplayConfig?> InsertOneMinimal(CreateDisplayConfigDto config);
|
||||
/// <summary>
|
||||
/// Performs a test insertion operation that returns a <see cref="DisplayConfig"/> instance, used to validate insertion behavior.
|
||||
/// </summary>
|
||||
/// <returns>A <see cref="Task{DisplayConfig}"/> representing the asynchronous test insertion result.</returns>
|
||||
/// <!-- aidoc:v1 sig=0a20de7 -->
|
||||
Task<DisplayConfig> InsertOneTest();
|
||||
/// <summary>
|
||||
/// Updates the display configuration identified by the specified identifier with the provided new configuration data.
|
||||
@@ -64,6 +72,7 @@ public interface IDisplayConfigService
|
||||
/// <param name="displayConfigId">The unique identifier of the display configuration to update.</param>
|
||||
/// <param name="newDisplayConfig">The new display configuration data to apply to the existing configuration.</param>
|
||||
/// <returns>The updated <see cref="DisplayConfig"/>, or <c>null</c> if no display configuration with the specified identifier is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=aa86543 -->
|
||||
Task<DisplayConfig?> UpdateConfig(ObjectId displayConfigId, object newDisplayConfig);
|
||||
/// <summary>
|
||||
/// Updates the list of fields associated with the specified configuration display.
|
||||
@@ -71,6 +80,7 @@ public interface IDisplayConfigService
|
||||
/// <param name="objectIdConfigDisplay">The identifier of the configuration display whose field list will be updated.</param>
|
||||
/// <param name="fields">The list of fields to be applied to the configuration display.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a value indicating whether the update was successful.</returns>
|
||||
/// <!-- aidoc:v1 sig=62079e1 -->
|
||||
Task<bool> UpdateFieldList(ObjectId objectIdConfigDisplay, List<Field> fields);
|
||||
/// <summary>
|
||||
/// Updates the color configuration for the specified config display.
|
||||
@@ -78,6 +88,7 @@ public interface IDisplayConfigService
|
||||
/// <param name="objectIdConfigDisplay">The identifier of the config display whose color configuration will be updated.</param>
|
||||
/// <param name="colorConfigDto">The color configuration data to apply to the config display.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains <c>true</c> if the update was successful; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=965cbeb -->
|
||||
Task<bool> UpdateConfigColor(ObjectId objectIdConfigDisplay, ColorConfig colorConfigDto);
|
||||
/// <summary>
|
||||
/// Asynchronously updates the header configuration associated with the specified config display identifier.
|
||||
@@ -85,6 +96,7 @@ public interface IDisplayConfigService
|
||||
/// <param name="objectIdConfigDisplay">The identifier of the config display whose header configuration will be updated.</param>
|
||||
/// <param name="headerConfig">The new header configuration to apply.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains <c>true</c> if the update was successful; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=979f311 -->
|
||||
Task<bool> UpdateHeaderConfig(ObjectId objectIdConfigDisplay, HeaderConfig headerConfig);
|
||||
/// <summary>
|
||||
/// Updates the home banner configuration for the specified config display with the provided list of banner items.
|
||||
@@ -92,12 +104,14 @@ public interface IDisplayConfigService
|
||||
/// <param name="objectIdConfigDisplay">The identifier of the config display whose home banner will be updated.</param>
|
||||
/// <param name="bannerItems">The list of banner items to set as the home banner configuration.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains <c>true</c> if the home banner was updated successfully; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=a96cf5b -->
|
||||
Task<bool> UpdateSetHomeBanner(ObjectId objectIdConfigDisplay, List<BannerItem> bannerItems);
|
||||
/// <summary>
|
||||
/// Updates the base display configuration with the specified settings.
|
||||
/// </summary>
|
||||
/// <param name="baseConfig">The display configuration to apply as the new base configuration.</param>
|
||||
/// <returns>A task that represents the asynchronous update operation. The task result contains a boolean value indicating whether the update was successful.</returns>
|
||||
/// <!-- aidoc:v1 sig=ab543ce -->
|
||||
Task<bool> UpdateBaseConfig(DisplayConfig baseConfig);
|
||||
/// <summary>
|
||||
/// Asynchronously updates the hospital name associated with the specified display configuration.
|
||||
@@ -105,29 +119,34 @@ public interface IDisplayConfigService
|
||||
/// <param name="objectIdConfigDisplay">The identifier of the display configuration whose hospital name will be updated.</param>
|
||||
/// <param name="name">The new hospital name to apply to the display configuration.</param>
|
||||
/// <returns>A task that resolves to <c>true</c> if the update was applied successfully; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=519223f -->
|
||||
Task<bool> UpdateDisplayConfigHospitalName(ObjectId objectIdConfigDisplay, string name);
|
||||
/// <summary>
|
||||
/// Deletes a display configuration identified by the specified object identifier.
|
||||
/// </summary>
|
||||
/// <param name="objectIdConfigDisplay">The unique identifier of the display configuration to delete.</param>
|
||||
/// <returns>A task that represents the asynchronous delete operation. The task result contains a boolean value indicating whether the display configuration was successfully deleted.</returns>
|
||||
/// <!-- aidoc:v1 sig=8887abf -->
|
||||
Task<bool> DeleteDisplayConfig(ObjectId objectIdConfigDisplay);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the default display configuration for the specified display type.
|
||||
/// </summary>
|
||||
/// <param name="type">The display type used to look up the default configuration.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the default <see cref="DisplayConfig"/> for the given display type, or <c>null</c> if no default configuration is available.</returns>
|
||||
/// <!-- aidoc:v1 sig=4360847 -->
|
||||
Task<DisplayConfig?> GetDefaultConfig(DisplayConfigEnums.DisplayType type);
|
||||
/// <summary>
|
||||
/// Retrieves the list of display configuration locations associated with the specified configuration display identifier.
|
||||
/// </summary>
|
||||
/// <param name="objectIdConfigDisplay">The ObjectId of the configuration display whose locations are to be retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of DisplayConfigLocationDto objects for the specified configuration display.</returns>
|
||||
/// <!-- aidoc:v1 sig=38e01cc -->
|
||||
Task<List<DisplayConfigLocationDto>> GetDisplayConfigLocations(ObjectId objectIdConfigDisplay);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves all display configurations in a compact (minimal) representation.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of <see cref="DisplayConfigMinimalResponse"/> objects representing the compact display configurations.</returns>
|
||||
/// <!-- aidoc:v1 sig=784f030 -->
|
||||
Task<List<DisplayConfigMinimalResponse>> GetAllCompact();
|
||||
|
||||
/// <summary>
|
||||
@@ -137,6 +156,7 @@ public interface IDisplayConfigService
|
||||
/// <param name="configType">The type of display configuration template to use for the insertion.</param>
|
||||
/// <param name="configHospital">The optional hospital identifier used to scope the configuration; may be null when the configuration is not hospital-specific.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the inserted <see cref="DisplayConfig"/>, or null if the configuration could not be created.</returns>
|
||||
/// <!-- aidoc:v1 sig=fd98439 -->
|
||||
Task<DisplayConfig?> InsertOneWithTemplate(string objectId,
|
||||
DisplayConfigEnums.DisplayType configType, string? configHospital);
|
||||
|
||||
@@ -145,17 +165,20 @@ public interface IDisplayConfigService
|
||||
/// </summary>
|
||||
/// <param name="baseConfig">The card configuration to be updated.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a boolean value indicating whether the update was successful.</returns>
|
||||
/// <!-- aidoc:v1 sig=a78296b -->
|
||||
Task<bool> UpdateCardConfig(CardConfig baseConfig);
|
||||
/// <summary>
|
||||
/// Inserts a new card configuration using the supplied data and returns the resulting <see cref="CardConfig"/>, or null if no card config is created.
|
||||
/// </summary>
|
||||
/// <param name="updateDisplayConfigNameDto">The DTO containing the data used to create the display config card.</param>
|
||||
/// <returns>A task that resolves to the inserted <see cref="CardConfig"/>, or null if the insert did not produce a card config.</returns>
|
||||
/// <!-- aidoc:v1 sig=aa15ede -->
|
||||
Task<CardConfig?> InsertCardConfig(CreateDisplayConfigCardDto updateDisplayConfigNameDto);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves all card configurations.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of all <see cref="CardConfig"/> items.</returns>
|
||||
/// <!-- aidoc:v1 sig=c76009a -->
|
||||
Task<List<CardConfig>> GetCardConfigAll();
|
||||
/// <summary>
|
||||
/// Retrieves the card configuration associated with the specified identifier.
|
||||
@@ -163,41 +186,48 @@ public interface IDisplayConfigService
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the card configuration to retrieve.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the <see cref="CardConfig"/> if found; otherwise, <c>null</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=8c670e5 -->
|
||||
Task<CardConfig?> GetCardConfigById(ObjectId id);
|
||||
/// <summary>
|
||||
/// Asynchronously updates the card details configuration based on the provided base configuration.
|
||||
/// </summary>
|
||||
/// <param name="baseConfig">The base card details configuration to apply during the update.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a boolean value indicating whether the update was successful.</returns>
|
||||
/// <!-- aidoc:v1 sig=8e7d63d -->
|
||||
Task<bool> UpdateDetailConfig(CardDetailsConfig baseConfig);
|
||||
/// <summary>
|
||||
/// Inserts a new card detail configuration based on the provided display config data.
|
||||
/// </summary>
|
||||
/// <param name="updateDisplayConfigNameDto">The DTO containing the data required to create the card detail configuration.</param>
|
||||
/// <returns>A task that resolves to the created <see cref="CardDetailsConfig"/>, or <c>null</c> if the configuration could not be inserted.</returns>
|
||||
/// <!-- aidoc:v1 sig=c90d7b5 -->
|
||||
Task<CardDetailsConfig?> InsertCardDetailConfig(CreateDisplayConfigCardDto updateDisplayConfigNameDto);
|
||||
/// <summary>
|
||||
/// Inserts a new chart configuration based on the provided display config card data.
|
||||
/// </summary>
|
||||
/// <param name="updateDisplayConfigNameDto">The data transfer object containing the details of the chart configuration to create.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the newly inserted <see cref="ChartConfig"/>, or <c>null</c> if the insertion was not successful.</returns>
|
||||
/// <!-- aidoc:v1 sig=98c18b3 -->
|
||||
Task<ChartConfig?> InsertChartConfig(CreateDisplayConfigCardDto updateDisplayConfigNameDto);
|
||||
/// <summary>
|
||||
/// Asynchronously updates the chart configuration based on the provided base configuration and returns a value indicating whether the update was successful.
|
||||
/// </summary>
|
||||
/// <param name="baseConfig">The base chart configuration to apply during the update.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The result is <c>true</c> if the chart configuration was updated successfully; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=115a30f -->
|
||||
Task<bool> UpdateChartConfig(ChartConfig baseConfig);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes a chart configuration identified by the specified configuration display identifier.
|
||||
/// </summary>
|
||||
/// <param name="objectIdConfigDisplay">The <see cref="ObjectId"/> of the chart configuration display to delete.</param>
|
||||
/// <returns>A task that represents the asynchronous delete operation, containing a value indicating whether the deletion was successful.</returns>
|
||||
/// <!-- aidoc:v1 sig=88cfab6 -->
|
||||
Task<bool> DeleteChartConfig(ObjectId objectIdConfigDisplay);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the chart configuration associated with the specified chart identifier.
|
||||
/// </summary>
|
||||
/// <param name="objectIdConfigChart">The unique identifier of the chart whose configuration should be fetched.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the <see cref="ChartConfig"/> associated with the provided identifier, or <c>null</c> if no configuration is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=15bc45a -->
|
||||
Task<ChartConfig?> GetChartConfig(ObjectId objectIdConfigChart);
|
||||
}
|
||||
@@ -16,6 +16,7 @@ public interface IDisplayService
|
||||
/// Asynchronously retrieves all displays in a compact format containing only minimal identifying information.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of <see cref="DisplayMinimalDto"/> objects representing all available displays in a compact projection.</returns>
|
||||
/// <!-- aidoc:v1 sig=05ec358 -->
|
||||
Task<List<DisplayMinimalDto>> GetAllCompact();
|
||||
/// <summary>
|
||||
/// Retrieves all displays along with their associated permissions for the specified user.
|
||||
@@ -23,30 +24,35 @@ public interface IDisplayService
|
||||
/// </summary>
|
||||
/// <param name="userName">The username used to look up the associated displays and permissions. May be null.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="DisplayWithPermissionsDto"/> entries for the user.</returns>
|
||||
/// <!-- aidoc:v1 sig=970fb6e -->
|
||||
Task<List<DisplayWithPermissionsDto>> GetAllByUser(string? userName);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a list of <see cref="Display"/> entries filtered by the specified display type.
|
||||
/// </summary>
|
||||
/// <param name="type">The display type used to filter the returned collection.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the list of <see cref="Display"/> items matching the specified type.</returns>
|
||||
/// <!-- aidoc:v1 sig=257ad89 -->
|
||||
Task<List<Display>> GetByType(DisplayConfigEnums.DisplayType type);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the list of displays associated with the specified point of care.
|
||||
/// </summary>
|
||||
/// <param name="pointOfCare">The point of care used to filter the displays to be returned.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the list of <see cref="Display"/> items linked to the given point of care.</returns>
|
||||
/// <!-- aidoc:v1 sig=04ec30c -->
|
||||
Task<List<Display>> GetByPointOfCare(PointOfCare pointOfCare);
|
||||
/// <summary>
|
||||
/// Retrieves a list of displays associated with the specified configuration identifier.
|
||||
/// </summary>
|
||||
/// <param name="configId">The unique identifier of the configuration used to filter the displays.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of displays matching the specified configuration identifier.</returns>
|
||||
/// <!-- aidoc:v1 sig=b59323e -->
|
||||
Task<List<Display>> GetByConfigId(ObjectId configId);
|
||||
/// <summary>
|
||||
/// Retrieves a list of <see cref="Display"/> entities associated with the specified card configuration identifier.
|
||||
/// </summary>
|
||||
/// <param name="configId">The unique identifier of the card configuration whose associated displays are to be retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="Display"/> objects linked to the given card configuration.</returns>
|
||||
/// <!-- aidoc:v1 sig=7885fbb -->
|
||||
Task<List<Display>> GetByCardConfigId(ObjectId configId);
|
||||
|
||||
// Task<List<Display>> GetByUser();
|
||||
@@ -56,12 +62,14 @@ public interface IDisplayService
|
||||
/// </summary>
|
||||
/// <param name="name">The name of the display to look up.</param>
|
||||
/// <returns>A <see cref="Task{Display}"/> that resolves to the matching <see cref="Display"/>, or <c>null</c> if none is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=02f4c9c -->
|
||||
Task<Display?> GetByName(string name);
|
||||
/// <summary>
|
||||
/// Retrieves a <see cref="Display"/> entity by its unique identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the display to retrieve.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the <see cref="Display"/> if found; otherwise, <c>null</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=3467c35 -->
|
||||
Task<Display?> GetById(ObjectId id);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a display representation of an entity along with its associated permissions, localized for the specified locale.
|
||||
@@ -69,12 +77,14 @@ public interface IDisplayService
|
||||
/// <param name="id">The unique identifier of the entity to retrieve.</param>
|
||||
/// <param name="localeEnum">The locale used to localize the returned display data.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the localized display data with permissions.</returns>
|
||||
/// <!-- aidoc:v1 sig=22adc98 -->
|
||||
Task<DisplayWithPermissionsDto> GetByIdWithPermissions(ObjectId id, LocaleEnum localeEnum);
|
||||
/// <summary>
|
||||
/// Asynchronously counts the number of displays associated with the specified unit identifier.
|
||||
/// </summary>
|
||||
/// <param name="unitId">The unique identifier of the unit whose displays should be counted.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the count of displays linked to the specified unit.</returns>
|
||||
/// <!-- aidoc:v1 sig=c09d0d4 -->
|
||||
Task<long> CountDisplaysByUnitId(ObjectId unitId);
|
||||
|
||||
/// <summary>
|
||||
@@ -90,6 +100,7 @@ public interface IDisplayService
|
||||
/// <param name="fillDisplayConfig">When <c>true</c>, includes the display configuration in the result.</param>
|
||||
/// <param name="ct">Token used to cancel the asynchronous operation.</param>
|
||||
/// <returns>A <see cref="Task{T}"/> that resolves to the <see cref="Display"/> if found, or <c>null</c> if no display matches the specified <paramref name="id"/>.</returns>
|
||||
/// <!-- aidoc:v1 sig=04117d6 -->
|
||||
Task<Display?> GetInfo(
|
||||
ObjectId id,
|
||||
string? userName,
|
||||
@@ -111,6 +122,7 @@ public interface IDisplayService
|
||||
/// <param name="userName">The user name used to resolve user-specific sections, or <c>null</c> if not applicable.</param>
|
||||
/// <param name="authorizations">The list of authorizations used to authorize and filter the returned sections, or <c>null</c> if no authorization filtering is required.</param>
|
||||
/// <returns>A task that yields the list of <see cref="MinimalDisplaySection"/> instances matching the supplied criteria.</returns>
|
||||
/// <!-- aidoc:v1 sig=1bea901 -->
|
||||
Task<List<MinimalDisplaySection>> GetDisplaySectionByUser(
|
||||
DisplayConfigEnums.DisplayType type,
|
||||
ObjectId? currentDisplay,
|
||||
@@ -121,12 +133,14 @@ public interface IDisplayService
|
||||
/// Asynchronously retrieves all display sections as a minimal display list.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the <see cref="MinimalDisplayListDto"/> with the display section data.</returns>
|
||||
/// <!-- aidoc:v1 sig=a8be7f7 -->
|
||||
Task<MinimalDisplayListDto> GetAllDisplaySection();
|
||||
/// <summary>
|
||||
/// Retrieves a list of <see cref="Display"/> records associated with the specified unit identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The <see cref="ObjectId"/> that identifies the unit whose displays are being requested.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a <see cref="List{Display}"/> of displays linked to the given unit.</returns>
|
||||
/// <!-- aidoc:v1 sig=a786839 -->
|
||||
Task<List<Display>> GetByUnitId(ObjectId id);
|
||||
/// <summary>
|
||||
/// Retrieves all available Points of Contact (POCs) along with their associated unit information, optionally filtered by the provided display identifiers and allowing exclusion of virtual entries.
|
||||
@@ -134,23 +148,27 @@ public interface IDisplayService
|
||||
/// <param name="displayIds">The list of display identifiers used to filter the available POCs.</param>
|
||||
/// <param name="excludeVirtual">When set to <c>true</c>, excludes virtual POCs from the results; otherwise, virtual POCs are included.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a <see cref="PocAndUnitDto"/> with the matching POCs and their unit details.</returns>
|
||||
/// <!-- aidoc:v1 sig=1142e26 -->
|
||||
Task<PocAndUnitDto> GetAllAvailablePoc(List<string> displayIds, bool excludeVirtual = false);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves all Points of Care (POCs) associated with the specified display identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The display identifier used to look up the associated Points of Care.</param>
|
||||
/// <returns>A task representing the asynchronous operation, containing a list of Points of Care matching the specified display identifier.</returns>
|
||||
/// <!-- aidoc:v1 sig=9c3ab00 -->
|
||||
Task<List<PointOfCare>> GetAllPocsByDisplayId(ObjectId id);
|
||||
/// <summary>
|
||||
/// Inserts a new display record into the data store and returns the persisted entity.
|
||||
/// </summary>
|
||||
/// <param name="display">The display entity to insert.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the inserted <see cref="Display"/>.</returns>
|
||||
/// <!-- aidoc:v1 sig=333acbc -->
|
||||
Task<Display> InsertOne(Display display);
|
||||
/// <summary>
|
||||
/// Asynchronously inserts a single test <see cref="Display"/> record and returns the persisted result.
|
||||
/// </summary>
|
||||
/// <returns>A <see cref="Task{Display}"/> that represents the asynchronous insert operation, containing the inserted <see cref="Display"/>.</returns>
|
||||
/// <!-- aidoc:v1 sig=eba6c71 -->
|
||||
Task<Display> InsertOneTest();
|
||||
/// <summary>
|
||||
/// Updates the configuration of an existing display using the provided new configuration.
|
||||
@@ -158,6 +176,7 @@ public interface IDisplayService
|
||||
/// <param name="oldDisplay">The current display whose configuration will be updated.</param>
|
||||
/// <param name="newDisplayConfig">The new display configuration to apply, or null to leave the configuration unchanged.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the updated <see cref="Display"/>, or null if the update was not performed.</returns>
|
||||
/// <!-- aidoc:v1 sig=d4b8ee5 -->
|
||||
Task<Display?> UpdateConfig(Display oldDisplay, DisplayConfig? newDisplayConfig);
|
||||
/// <summary>
|
||||
/// Updates the configuration identifier associated with the specified display.
|
||||
@@ -165,6 +184,7 @@ public interface IDisplayService
|
||||
/// <param name="oldDisplay">The existing display whose configuration identifier will be updated.</param>
|
||||
/// <param name="configId">The new configuration identifier to associate with the display.</param>
|
||||
/// <returns>A task that resolves to the updated <see cref="Display"/>, or <c>null</c> if no result is available.</returns>
|
||||
/// <!-- aidoc:v1 sig=8265f8f -->
|
||||
Task<Display?> UpdateConfigId(Display oldDisplay, ObjectId configId);
|
||||
/// <summary>
|
||||
/// Updates the point of care list associated with the specified object identifier, replacing or merging it with the provided list of point of care object identifiers.
|
||||
@@ -172,6 +192,7 @@ public interface IDisplayService
|
||||
/// <param name="objectId">The identifier of the object whose point of care list is being updated.</param>
|
||||
/// <param name="listPocObId">The collection of point of care object identifiers to apply to the target object.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the resulting <see cref="Display"/> when the update succeeds, or <c>null</c> when no matching object is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=48f0e68 -->
|
||||
Task<Display?> UpdatePointOfCareList(ObjectId objectId, List<ObjectId> listPocObId);
|
||||
/// <summary>
|
||||
/// Updates the configuration preset associated with the specified display using the provided configuration display.
|
||||
@@ -179,6 +200,7 @@ public interface IDisplayService
|
||||
/// <param name="objectIdDisplay">The unique identifier of the display whose configuration preset will be updated.</param>
|
||||
/// <param name="objectIdConfigDisplay">The unique identifier of the configuration display to apply as the preset.</param>
|
||||
/// <returns>A task that resolves to the updated <see cref="Display"/>, or <c>null</c> if no matching display is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=6061a62 -->
|
||||
Task<Display?> UpdateConfigPreset(ObjectId objectIdDisplay, ObjectId objectIdConfigDisplay);
|
||||
/// <summary>
|
||||
/// Updates the name of the entity identified by the given identifier and returns the resulting <see cref="Display"/>.
|
||||
@@ -186,34 +208,40 @@ public interface IDisplayService
|
||||
/// <param name="id">The identifier of the entity whose name should be updated.</param>
|
||||
/// <param name="name">The new name to apply to the entity.</param>
|
||||
/// <returns>A task that represents the asynchronous update operation, containing the updated <see cref="Display"/> or <c>null</c> if no entity was found.</returns>
|
||||
/// <!-- aidoc:v1 sig=67bb64c -->
|
||||
Task<Display?> UpdateName(ObjectId id, string name);
|
||||
/// <summary>
|
||||
/// Retrieves a paginated collection of displays based on the provided filter criteria.
|
||||
/// </summary>
|
||||
/// <param name="filter">The pagination filter that defines the page size, page number, and any additional filtering criteria for the display results.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a <see cref="PaginationResponse{Display}"/> with the requested page of displays and pagination metadata.</returns>
|
||||
/// <!-- aidoc:v1 sig=847a84e -->
|
||||
Task<PaginationResponse<Display>> GetPaginatedDisplays(PaginationFilter filter);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes the display identified by the specified identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the display to delete.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a value indicating whether the display was successfully deleted.</returns>
|
||||
/// <!-- aidoc:v1 sig=5bb6263 -->
|
||||
Task<bool> DeleteDisplay(ObjectId id);
|
||||
/// <summary>
|
||||
/// Retrieves the list of display configuration locations associated with the specified display configuration.
|
||||
/// </summary>
|
||||
/// <param name="displayConfigId">The unique identifier of the display configuration whose locations are being retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="DisplayConfigLocationDto"/> objects for the specified display configuration.</returns>
|
||||
/// <!-- aidoc:v1 sig=89491e6 -->
|
||||
Task<List<DisplayConfigLocationDto>> GetDisplayConfigLocations(ObjectId displayConfigId);
|
||||
/// <summary>
|
||||
/// Asynchronously determines whether the specified display configuration is currently in use.
|
||||
/// </summary>
|
||||
/// <param name="displayConfigId">The identifier of the display configuration to check.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result is <c>true</c> if the display configuration is in use; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=387c518 -->
|
||||
Task<bool> IsDisplayConfigInUse(ObjectId displayConfigId);
|
||||
/// <summary>
|
||||
/// Deletes display records associated with the specified unit identifier.
|
||||
/// </summary>
|
||||
/// <param name="unitId">The identifier of the unit whose displays should be removed.</param>
|
||||
/// <!-- aidoc:v1 sig=6bb1d75 -->
|
||||
Task DeleteDisplaysByUnitId(ObjectId unitId);
|
||||
}
|
||||
@@ -13,6 +13,7 @@ public interface IFileService
|
||||
/// </summary>
|
||||
/// <param name="files">The collection of update files to be copied.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a boolean value indicating whether the copy operation succeeded.</returns>
|
||||
/// <!-- aidoc:v1 sig=53643ff -->
|
||||
Task<bool> CopyUpdateFiles(ICollection<IFormFile> files);
|
||||
/// <summary>
|
||||
/// Uploads the provided asset files categorized by the specified theme, returning a value indicating whether the operation completed successfully.
|
||||
@@ -20,12 +21,14 @@ public interface IFileService
|
||||
/// <param name="files">The collection of uploaded form files to process and store as assets.</param>
|
||||
/// <param name="themeParse">The asset theme used to classify and organize the uploaded files.</param>
|
||||
/// <returns>A task that resolves to <c>true</c> if the asset files were uploaded successfully; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=1b9d2d8 -->
|
||||
Task<bool> UploadAssetFiles(ICollection<IFormFile> files, FileEnum.AssetTheme themeParse);
|
||||
/// <summary>
|
||||
/// Retrieves all asset files for the specified asset theme as a list of asset data transfer objects.
|
||||
/// </summary>
|
||||
/// <param name="themeParse">The asset theme used to retrieve the corresponding assets.</param>
|
||||
/// <returns>A <see cref="List{AssetDto}"/> containing the asset data transfer objects for the specified theme.</returns>
|
||||
/// <!-- aidoc:v1 sig=26bd29d -->
|
||||
List<AssetDto> GetAllAssetFile(FileEnum.AssetTheme themeParse);
|
||||
|
||||
/// <summary>
|
||||
@@ -33,5 +36,6 @@ public interface IFileService
|
||||
/// </summary>
|
||||
/// <param name="directoryPath">The path of the directory from which to retrieve the files.</param>
|
||||
/// <returns>A list of strings representing the names of the files in the specified directory.</returns>
|
||||
/// <!-- aidoc:v1 sig=491d1e8 -->
|
||||
List<string> GetFilesInDirectory(string directoryPath);
|
||||
}
|
||||
@@ -16,6 +16,8 @@ public interface IGroupedObservationService
|
||||
/// <param name="cacheIsChecked">Indicates whether the cache should be consulted before generating the result. Defaults to <c>false</c>.</param>
|
||||
/// <param name="ct">The cancellation token used to cancel the operation.</param>
|
||||
/// <returns>A task that represents the asynchronous generation, producing the resulting <see cref="GroupedObservation"/>.</returns>
|
||||
/// <!-- aidoc-review:v1 severity=low kind=wrong_param_role
|
||||
/// "Documented default value for timeZoneId has a typo: 'Romence Standard Time' should be 'Romance Standard Time' to match the code" -->
|
||||
Task<GroupedObservation> GenerateGroupedObservation(ObjectId id, GroupedField groupedField,
|
||||
string timeZoneId = "Romance Standard Time", bool cacheIsChecked = false, CancellationToken ct = default);
|
||||
|
||||
@@ -30,6 +32,7 @@ public interface IGroupedObservationService
|
||||
/// <param name="obs">The patient observation to be processed and grouped.</param>
|
||||
/// <param name="timeZoneId">The time zone identifier used when computing date and time values for the grouped observation. Defaults to "Romance Standard Time".</param>
|
||||
/// <returns>A <see cref="Task{GroupedObservation}"/> that resolves to the generated grouped observation for the patient.</returns>
|
||||
/// <!-- aidoc:v1 sig=3672d15 -->
|
||||
Task<GroupedObservation> GenerateGroupedObservation(ObjectId obsPatientId, GroupedField groupedField,
|
||||
List<GroupedObservation.GroupedObservationObs> wsgLastGroupedObservationObs, PatientObservation obs,
|
||||
string timeZoneId = "Romance Standard Time");
|
||||
@@ -41,6 +44,7 @@ public interface IGroupedObservationService
|
||||
/// <param name="num">The maximum number of recent observations to return. Defaults to 2.</param>
|
||||
/// <param name="filterObservations">An optional list of observation names to include; if null, all observation types are considered.</param>
|
||||
/// <returns>A task that resolves to a list of the most recent <see cref="PatientObservation"/> entries for the patient.</returns>
|
||||
/// <!-- aidoc:v1 sig=40372b5 -->
|
||||
Task<List<PatientObservation>> FindLastObservations(ObjectId patientId, int num = 2,
|
||||
List<string>? filterObservations = null);
|
||||
|
||||
@@ -49,6 +53,7 @@ public interface IGroupedObservationService
|
||||
/// </summary>
|
||||
/// <param name="ws">The grouped web service subscriber for which the next empty observation is created.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the newly created <see cref="GroupedObservation"/>.</returns>
|
||||
/// <!-- aidoc:v1 sig=d148522 -->
|
||||
Task<GroupedObservation> CreateNextEmptyObs(WsSubscriberGrouped ws);
|
||||
/*
|
||||
*
|
||||
|
||||
@@ -10,6 +10,7 @@ public interface IHistoricalConfigChangesService
|
||||
/// Asynchronously retrieves all historical configuration changes recorded in the system.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a collection of all <see cref="HistoricalConfigChanges"/> entries.</returns>
|
||||
/// <!-- aidoc:v1 sig=89e2dae -->
|
||||
Task<ICollection<HistoricalConfigChanges>> GetAll();
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a historical configuration change entry by its unique identifier.
|
||||
@@ -17,6 +18,7 @@ public interface IHistoricalConfigChangesService
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the historical configuration change to retrieve.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the matching <see cref="HistoricalConfigChanges"/> or null if not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=4bce1e5 -->
|
||||
Task<HistoricalConfigChanges?> Get(ObjectId id);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a collection of historical configuration changes filtered by the specified configuration type.
|
||||
@@ -24,6 +26,7 @@ public interface IHistoricalConfigChangesService
|
||||
/// <param name="type">The configuration type used to filter the historical changes.</param>
|
||||
/// <param name="num">The maximum number of historical change records to return.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a collection of <see cref="HistoricalConfigChanges"/> for the specified type.</returns>
|
||||
/// <!-- aidoc:v1 sig=984ce5a -->
|
||||
Task<ICollection<HistoricalConfigChanges>> GetByType(DisplayConfigEnums.ConfigTypes type, int num);
|
||||
|
||||
/// <summary>
|
||||
@@ -34,6 +37,7 @@ public interface IHistoricalConfigChangesService
|
||||
/// <param name="configTypes">The optional configuration type used to filter the results; if null, changes for all configuration types are returned.</param>
|
||||
/// <param name="num">The maximum number of historical configuration change records to return.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the collection of historical configuration changes matching the specified criteria.</returns>
|
||||
/// <!-- aidoc:v1 sig=ceca012 -->
|
||||
Task<ICollection<HistoricalConfigChanges>> GetByUser(string user, DisplayConfigEnums.ConfigTypes? configTypes,
|
||||
int num);
|
||||
|
||||
@@ -43,6 +47,7 @@ public interface IHistoricalConfigChangesService
|
||||
/// </summary>
|
||||
/// <param name="configTypes">The configuration type used to look up the most recent historical changes.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the last <see cref="HistoricalConfigChanges"/> for the specified type, or null if no changes are available.</returns>
|
||||
/// <!-- aidoc:v1 sig=899c410 -->
|
||||
Task<HistoricalConfigChanges?> FindLastConfigChanges(DisplayConfigEnums.ConfigTypes configTypes);
|
||||
|
||||
|
||||
@@ -52,18 +57,21 @@ public interface IHistoricalConfigChangesService
|
||||
/// </summary>
|
||||
/// <param name="historicalConfigChanges">The historical configuration change entity to be inserted.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the inserted <see cref="HistoricalConfigChanges"/> entity, or null if the insertion did not produce a result.</returns>
|
||||
/// <!-- aidoc:v1 sig=ae5c68c -->
|
||||
Task<HistoricalConfigChanges?> InsertOne(HistoricalConfigChanges historicalConfigChanges);
|
||||
/// <summary>
|
||||
/// Updates an existing historical configuration change record with the provided data and returns the updated entity.
|
||||
/// </summary>
|
||||
/// <param name="historicalConfigChanges">The historical configuration change entity containing the updated values to be persisted.</param>
|
||||
/// <returns>A task that resolves to the updated <see cref="HistoricalConfigChanges"/>, or <c>null</c> if the record was not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=f875ebb -->
|
||||
Task<HistoricalConfigChanges?> UpdateHistoricalConfigChange(HistoricalConfigChanges historicalConfigChanges);
|
||||
|
||||
/// <summary>
|
||||
/// Deletes a historical configuration change identified by the specified identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The identifier of the historical configuration change to delete.</param>
|
||||
/// <!-- aidoc:v1 sig=b0535af -->
|
||||
Task DeleteHistoricalConfigChange(ObjectId id);
|
||||
|
||||
/// <summary>
|
||||
@@ -73,5 +81,6 @@ public interface IHistoricalConfigChangesService
|
||||
/// <param name="configType">The type of configuration that was changed.</param>
|
||||
/// <param name="newConfig">The new configuration value after the change.</param>
|
||||
/// <param name="oldConfig">The previous configuration value before the change.</param>
|
||||
/// <!-- aidoc:v1 sig=6dd04c6 -->
|
||||
Task LogConfigChanged(string user, DisplayConfigEnums.ConfigTypes configType, string newConfig, string oldConfig);
|
||||
}
|
||||
@@ -14,6 +14,7 @@ public interface ILightBeaconService
|
||||
/// </summary>
|
||||
/// <param name="pocId">The identifier of the point of control that targets the light beacon.</param>
|
||||
/// <param name="color">The color to apply to the light beacon.</param>
|
||||
/// <!-- aidoc:v1 sig=4279fa1 -->
|
||||
Task SendColor(ObjectId pocId, LightBeaconColor color);
|
||||
/// <summary>
|
||||
/// Sends a color command to the light beacon of the specified point of care device,
|
||||
@@ -22,34 +23,41 @@ public interface ILightBeaconService
|
||||
/// <param name="pocId">The identifier of the point of care device whose light beacon will be updated.</param>
|
||||
/// <param name="color">The color to apply to the light beacon.</param>
|
||||
/// <returns>A task that represents the asynchronous color send operation.</returns>
|
||||
/// <!-- aidoc-review:v1 severity=medium kind=wrong_param_role
|
||||
/// "pocId is documented as 'The identifier of the point of care device' but the parameter type is PointOfCare, a full object, not an identifier." -->
|
||||
Task SendColor(PointOfCare pocId, LightBeaconColor color);
|
||||
/// <summary>
|
||||
/// Sends a light beacon broadcast for the specified point of care, setting the beacon to display the specified color.
|
||||
/// </summary>
|
||||
/// <param name="poc">The point of care device or location whose beacon will be updated.</param>
|
||||
/// <param name="color">The color to display on the light beacon.</param>
|
||||
/// <!-- aidoc:v1 sig=7a336c8 -->
|
||||
Task SendBeaconBroadcast(PointOfCare poc, LightBeaconColor color);
|
||||
/// <summary>
|
||||
/// Sends a broadcast signal to the beacon associated with the specified point of care identifier using the given beacon color.
|
||||
/// </summary>
|
||||
/// <param name="poc">The identifier of the point of care (or beacon) that will receive the broadcast.</param>
|
||||
/// <param name="color">The color of the light beacon used for the broadcast.</param>
|
||||
/// <!-- aidoc:v1 sig=4fec682 -->
|
||||
Task SendBeaconBroadcast(ObjectId poc, LightBeaconColor color);
|
||||
/// <summary>
|
||||
/// Asynchronously powers off the LED associated with the specified point of connection identifier.
|
||||
/// </summary>
|
||||
/// <param name="pocId">The identifier of the point of connection whose LED will be turned off.</param>
|
||||
/// <!-- aidoc:v1 sig=bde6341 -->
|
||||
Task PowerOffLed(ObjectId pocId);
|
||||
/// <summary>
|
||||
/// Asynchronously powers off the LED indicator associated with the specified point of care.
|
||||
/// </summary>
|
||||
/// <param name="poc">The point of care whose LED indicator should be turned off.</param>
|
||||
/// <!-- aidoc:v1 sig=ce5eefc -->
|
||||
Task PowerOffLed(PointOfCare poc);
|
||||
|
||||
/// <summary>
|
||||
/// Generates a color-coded alert based on the provided patient observation.
|
||||
/// </summary>
|
||||
/// <param name="obs">The patient observation used to determine the alert level and color.</param>
|
||||
/// <!-- aidoc:v1 sig=5f77447 -->
|
||||
void GenerateColorAlert(PatientObservation obs);
|
||||
|
||||
//TODO refactor, one patient can have multiple beacons
|
||||
@@ -58,12 +66,14 @@ public interface ILightBeaconService
|
||||
/// </summary>
|
||||
/// <param name="pocId">The identifier of the point of care whose light beacon color is being requested.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the <see cref="LightBeaconColor"/> for the specified point of care.</returns>
|
||||
/// <!-- aidoc:v1 sig=0f47559 -->
|
||||
public Task<LightBeaconColor> GetColor(ObjectId pocId);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the light beacon color associated with the specified point of care.
|
||||
/// </summary>
|
||||
/// <param name="poc">The point of care for which to look up the light beacon color.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the <see cref="LightBeaconColor"/> for the specified point of care.</returns>
|
||||
/// <!-- aidoc:v1 sig=2bcbc4b -->
|
||||
public Task<LightBeaconColor> GetColor(PointOfCare poc);
|
||||
/// <summary>
|
||||
/// Updates a single light beacon record in the data store.
|
||||
@@ -71,23 +81,27 @@ public interface ILightBeaconService
|
||||
/// </summary>
|
||||
/// <param name="beacon">The light beacon containing the updated values to persist.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the updated <see cref="LightBeacon"/>, or <see langword="null"/> if no matching beacon was found.</returns>
|
||||
/// <!-- aidoc:v1 sig=dea8894 -->
|
||||
Task<LightBeacon?> UpdateOne(LightBeacon beacon);
|
||||
/// <summary>
|
||||
/// Inserts a single light beacon into the data store.
|
||||
/// </summary>
|
||||
/// <param name="beacon">The light beacon entity to insert.</param>
|
||||
/// <returns>A task that resolves to the inserted <see cref="LightBeacon"/>, or <c>null</c> when no result is produced.</returns>
|
||||
/// <!-- aidoc:v1 sig=e90c40d -->
|
||||
Task<LightBeacon?> InsertOne(LightBeacon beacon);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a paginated collection of light beacons based on the specified pagination filter.
|
||||
/// </summary>
|
||||
/// <param name="request">The pagination filter containing the criteria used to page the beacon results.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a pagination response with the requested light beacons.</returns>
|
||||
/// <!-- aidoc:v1 sig=91c5832 -->
|
||||
Task<PaginationResponse<LightBeacon>> GetPaginatedBeacons(PaginationFilter request);
|
||||
/// <summary>
|
||||
/// Asynchronously searches for light beacons by name using the specified search text.
|
||||
/// </summary>
|
||||
/// <param name="textToSearch">The text used to search for matching light beacons by name.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of <see cref="LightBeacon"/> objects matching the search criteria.</returns>
|
||||
/// <!-- aidoc:v1 sig=2c88e45 -->
|
||||
Task<List<LightBeacon>> GetSearchByName(string textToSearch);
|
||||
}
|
||||
@@ -12,11 +12,13 @@ public interface ILocalAuditService
|
||||
/// <param name="dataModified">The modified state of the data after the change. May be null when the action deletes an existing record.</param>
|
||||
/// <param name="reason">An optional explanation or justification for the change. Defaults to null when no reason is provided.</param>
|
||||
/// <returns>A task that represents the asynchronous creation of the audit log entry.</returns>
|
||||
/// <!-- aidoc:v1 sig=f137579 -->
|
||||
Task CreateAuditLogAsync(ClaimsPrincipal? user, object? dataOriginal, object? dataModified, string? reason = null);
|
||||
/// <summary>
|
||||
/// Asynchronously creates a deep copy of the specified data, producing a new independent instance of the same type.
|
||||
/// </summary>
|
||||
/// <param name="data">The data instance to be deep copied.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the deep-copied instance of type <typeparamref name="T"/>, or <c>null</c> if the copy could not be produced.</returns>
|
||||
/// <!-- aidoc:v1 sig=a6d959a -->
|
||||
Task<T?> DeepCopyAsync<T>(T data);
|
||||
}
|
||||
@@ -10,11 +10,14 @@
|
||||
/// <summary>
|
||||
/// Intenta adquirir el lock para una clave dentro del timeout.
|
||||
/// </summary>
|
||||
/// <!-- aidoc-review:v1 severity=medium kind=missing_returns
|
||||
/// "The method returns Task<bool> indicating whether the lock was acquired, but the documentation does not describe the return value." -->
|
||||
Task<bool> AcquireAsync(string key, TimeSpan timeout);
|
||||
|
||||
/// <summary>
|
||||
/// Libera el lock para la clave (idempotente).
|
||||
/// </summary>
|
||||
/// <!-- aidoc:v1 sig=5956b6c -->
|
||||
Task ReleaseAsync(string key);
|
||||
}
|
||||
}
|
||||
@@ -13,17 +13,20 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// Asynchronously retrieves the complete master list of items of type <typeparamref name="T"/>.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains an <see cref="IEnumerable{T}"/> with all items from the master list.</returns>
|
||||
/// <!-- aidoc:v1 sig=bbf098e -->
|
||||
Task<IEnumerable<T>> GetAllMasterList();
|
||||
/// <summary>
|
||||
/// Retrieves all master list entries, excluding items categorized as options.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a collection of <see cref="MasterListDto"/> items representing the master list without options.</returns>
|
||||
/// <!-- aidoc:v1 sig=53f27dd -->
|
||||
Task<IEnumerable<MasterListDto>> GetAllMasterListWithoutOptions();
|
||||
/// <summary>
|
||||
/// Retrieves a paginated collection of master list items with their associated options based on the specified pagination filter.
|
||||
/// </summary>
|
||||
/// <param name="request">The pagination filter containing paging criteria such as page number and page size.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing an enumerable collection of <see cref="MasterListWithPaginatedOptionsDto"/> items for the requested page.</returns>
|
||||
/// <!-- aidoc:v1 sig=576fdd0 -->
|
||||
Task<IEnumerable<MasterListWithPaginatedOptionsDto>> GetAllMasterListWithPaginatedOptions(PaginationFilter request);
|
||||
/// <summary>
|
||||
/// Retrieves a master list entry identified by the specified <paramref name="id"/>, optionally resolving localized content based on the provided <paramref name="locale"/>. Returns <c>null</c> when no matching entry is found.
|
||||
@@ -31,6 +34,7 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="id">The unique identifier of the master list entry to retrieve.</param>
|
||||
/// <param name="locale">The optional locale used to resolve localized fields; when <c>null</c>, a default or non-localized representation is returned.</param>
|
||||
/// <returns>A task that resolves to the matching master list entry of type <typeparamref name="T"/>, or <c>null</c> if the entry does not exist.</returns>
|
||||
/// <!-- aidoc:v1 sig=fab0bce -->
|
||||
Task<T?> GetMasterListById(ObjectId id, LocaleEnum? locale);
|
||||
|
||||
/// <summary>
|
||||
@@ -40,6 +44,7 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="id">The unique identifier of the master list to retrieve.</param>
|
||||
/// <param name="request">The pagination filter used to control the paginated options returned with the master list.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the <see cref="MasterListWithPaginatedOptionsDto"/> if a matching master list is found, otherwise null.</returns>
|
||||
/// <!-- aidoc:v1 sig=46550b5 -->
|
||||
Task<MasterListWithPaginatedOptionsDto?> GetMasterListByIdWithPaginatedOptions(ObjectId id,
|
||||
PaginationFilter request);
|
||||
|
||||
@@ -48,6 +53,7 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the master list whose option names are being retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of option names for the specified master list.</returns>
|
||||
/// <!-- aidoc:v1 sig=5b1bec6 -->
|
||||
Task<List<string>> GetMasterListOptionsNamesById(ObjectId id);
|
||||
/// <summary>
|
||||
/// Retrieves a master list of <see cref="OptionList"/> entries filtered by the specified identifier and an optional text search criterion.
|
||||
@@ -55,6 +61,7 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="id">The unique identifier used to scope the master list lookup.</param>
|
||||
/// <param name="textSearch">An optional text string used to further filter the results; may be <c>null</c> to return all matching entries.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="OptionList"/> items matching the provided identifier and text search.</returns>
|
||||
/// <!-- aidoc:v1 sig=b1e3b91 -->
|
||||
Task<List<OptionList>> GetMasterListByIdAndTextSearch(ObjectId id, string? textSearch);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a master list of options associated with the specified identifier, applying the provided search and filter criteria.
|
||||
@@ -62,29 +69,34 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="id">The identifier used to locate the master list to retrieve.</param>
|
||||
/// <param name="filterOption">The filter and search options used to refine the returned list.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the list of <see cref="OptionList"/> entries that match the specified id and filter options.</returns>
|
||||
/// <!-- aidoc:v1 sig=74ffbb0 -->
|
||||
Task<List<OptionList>> GetMasterListByIdAndSearchOptions(ObjectId id, FilterOptionListElement filterOption);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a master list that matches the specified name.
|
||||
/// </summary>
|
||||
/// <param name="name">The name used to look up the master list.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The result is the matching master list of type <typeparamref name="T"/>, or <c>null</c> if no master list with the specified name is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=f88b34e -->
|
||||
Task<T?> GetMasterListByName(string name);
|
||||
/// <summary>
|
||||
/// Inserts the specified item into the master list and returns the resulting entry, or <c>null</c> if the operation did not produce a result.
|
||||
/// </summary>
|
||||
/// <param name="item">The item to insert into the master list.</param>
|
||||
/// <returns>A <see cref="Task{T}"/> that resolves to the inserted item, or <c>null</c> when no result is available.</returns>
|
||||
/// <!-- aidoc:v1 sig=56ebb96 -->
|
||||
Task<T?> InsertMasterList(T item);
|
||||
/// <summary>
|
||||
/// Updates the master list with the specified item.
|
||||
/// </summary>
|
||||
/// <param name="item">The item to be updated in the master list.</param>
|
||||
/// <returns>A task that represents the asynchronous update operation, containing the updated item or <c>null</c> if the update could not be performed.</returns>
|
||||
/// <!-- aidoc:v1 sig=4dd0c3c -->
|
||||
Task<T?> UpdateMasterList(T item);
|
||||
/// <summary>
|
||||
/// Deletes a master list identified by the specified identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the master list to delete.</param>
|
||||
/// <!-- aidoc:v1 sig=5af7c2c -->
|
||||
Task DeleteMasterListById(ObjectId id);
|
||||
/// <summary>
|
||||
/// Adds the specified option element to the master option list identified by the given identifier.
|
||||
@@ -92,6 +104,7 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="id">The unique identifier of the master option list to which the option will be added.</param>
|
||||
/// <param name="opt">The filter option list element to append to the master list.</param>
|
||||
/// <returns>A task that returns the updated <see cref="OptionList"/>, or <c>null</c> if the master list could not be found.</returns>
|
||||
/// <!-- aidoc:v1 sig=07eea1e -->
|
||||
Task<OptionList?> AddOptionToMasterList(ObjectId id, FilterOptionListElement opt);
|
||||
/// <summary>
|
||||
/// Updates an option in a master list, localized for the specified locale, and returns the updated option list.
|
||||
@@ -101,6 +114,7 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="typeName">The name of the master list type that owns the option.</param>
|
||||
/// <param name="locale">The locale used to resolve or apply localized values.</param>
|
||||
/// <returns>A task that returns the updated <see cref="OptionList"/>, or <c>null</c> if the option could not be found.</returns>
|
||||
/// <!-- aidoc:v1 sig=cda7ccb -->
|
||||
Task<OptionList?> UpdateMasterListOption(ObjectId id, OptionList opt, string typeName, LocaleEnum locale);
|
||||
/// <summary>
|
||||
/// Updates the full master list option identified by the specified identifier and type name.
|
||||
@@ -109,6 +123,7 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="opt">The option list containing the updated values.</param>
|
||||
/// <param name="typeName">The name of the type associated with the master list option.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the updated <see cref="OptionList"/>, or <c>null</c> if the option was not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=6aed753 -->
|
||||
Task<OptionList?> UpdateFullMasterListOption(ObjectId id, OptionList opt, string typeName);
|
||||
/// <summary>
|
||||
/// Updates a master list option for the specified type with the provided option data.
|
||||
@@ -117,6 +132,7 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="opt">The option data to apply to the master list.</param>
|
||||
/// <param name="typeName">The name of the master list type containing the option.</param>
|
||||
/// <returns>The updated <see cref="OptionList"/>, or null if the option is not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=11de0a9 -->
|
||||
Task<OptionList?> UpdateMasterListOption(ObjectId id, OptionList opt, string typeName);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves an option list item identified by the specified master ID, option ID, and locale.
|
||||
@@ -125,6 +141,7 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="optionId">The identifier of the specific option item to find.</param>
|
||||
/// <param name="locale">The locale used to retrieve the localized option item.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the matching <see cref="OptionList"/> or <c>null</c> if no item is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=353f501 -->
|
||||
Task<OptionList?> FindOptionItemById(ObjectId masterId, ObjectId optionId, LocaleEnum locale);
|
||||
/// <summary>
|
||||
/// Updates the option details of a master list entry identified by the specified id.
|
||||
@@ -132,6 +149,7 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="id">The identifier of the master list entry to update.</param>
|
||||
/// <param name="opt">The master list details to apply to the entry.</param>
|
||||
/// <returns>A task that returns the updated master list details, or null if no matching entry is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=1d0803c -->
|
||||
Task<UpdateMasterListDetailsDto?> UpdateOptionDetailsToMasterList(ObjectId id, UpdateMasterListDetailsDto opt);
|
||||
/// <summary>
|
||||
/// Updates the name of an existing master list identified by the specified identifier.
|
||||
@@ -139,6 +157,7 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="id">The identifier of the master list to update.</param>
|
||||
/// <param name="name">The new name to assign to the master list.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result is <c>true</c> if the master list was successfully updated; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=a2d47b2 -->
|
||||
Task<bool> UpdateMasterListName(ObjectId id, string name);
|
||||
/// <summary>
|
||||
/// Updates the description (name) of a master list entry identified by the specified identifier.
|
||||
@@ -146,6 +165,7 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="id">The unique identifier of the master list entry to update.</param>
|
||||
/// <param name="name">The new description to apply to the master list entry.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result is <c>true</c> if the update was successful; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=8d9103c -->
|
||||
Task<bool> UpdateMasterListDescription(ObjectId id, string name);
|
||||
/// <summary>
|
||||
/// Asynchronously removes the specified option from the master list identified by the given id.
|
||||
@@ -153,17 +173,20 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="id">The identifier of the master list from which the option will be removed.</param>
|
||||
/// <param name="oldOpt">The option entry to be removed from the master list.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result is <c>true</c> if the option was successfully removed; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=f049a15 -->
|
||||
Task<bool> RemoveMasterListOption(ObjectId id, OptionList oldOpt);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the total count of all items in the master list.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the total number of items in the master list.</returns>
|
||||
/// <!-- aidoc:v1 sig=819b090 -->
|
||||
Task<int> GetAllMasterListCount();
|
||||
/// <summary>
|
||||
/// Retrieves a paginated master list of items based on the specified filter criteria.
|
||||
/// </summary>
|
||||
/// <param name="filter">The pagination filter that defines paging parameters such as page number and page size.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the paginated response with the requested master list items.</returns>
|
||||
/// <!-- aidoc:v1 sig=836cb10 -->
|
||||
Task<PaginationResponse<T>> GetPaginatedMasterList(PaginationFilter filter);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes a master list option identified by the supplied identifiers.
|
||||
@@ -172,6 +195,7 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="optId">The identifier of the specific option to remove from the master list.</param>
|
||||
/// <param name="typeName">The name of the master list type to which the option belongs.</param>
|
||||
/// <returns>A task that resolves to <c>true</c> if the option was successfully deleted; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=59b3577 -->
|
||||
Task<bool> DeleteMasterListOption(ObjectId id, ObjectId optId, string typeName);
|
||||
|
||||
/// <summary>
|
||||
@@ -180,6 +204,7 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="listFilter">The pagination filter applied to the master list results.</param>
|
||||
/// <param name="optionsFilter">The pagination filter applied to the associated options.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the paginated response with master list and options data.</returns>
|
||||
/// <!-- aidoc:v1 sig=95a8b2b -->
|
||||
Task<PaginationResponse<MasterListWithPaginatedOptionsDto>> GetPaginatedMasterListWithPaginatedOptions(
|
||||
PaginationFilter listFilter, PaginationFilter optionsFilter);
|
||||
|
||||
@@ -189,6 +214,7 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="filter">The pagination parameters used to control the page size and page index of the returned results.</param>
|
||||
/// <param name="listId">The identifier of the list whose options should be retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a <see cref="PaginationResponse{OptionList}"/> with the requested options.</returns>
|
||||
/// <!-- aidoc:v1 sig=0df2157 -->
|
||||
Task<PaginationResponse<OptionList>> GetPaginatedOptions(PaginationFilter filter, ObjectId listId);
|
||||
/// <summary>
|
||||
/// Retrieves the associated list identifier for the given object based on the specified master list types.
|
||||
@@ -197,11 +223,13 @@ public interface IMasterListService<T> where T : MasterList
|
||||
/// <param name="masterListType1">The first master list type used to determine the association.</param>
|
||||
/// <param name="masterListType2">The second master list type used to determine the association.</param>
|
||||
/// <returns>A task that returns the associated <see cref="ObjectId"/> if found, or <c>null</c> if no association exists.</returns>
|
||||
/// <!-- aidoc:v1 sig=6f6f775 -->
|
||||
Task<ObjectId?> GetAssociatedList(ObjectId id, MasterListType masterListType1, MasterListType masterListType2);
|
||||
/// <summary>
|
||||
/// Retrieves the available options associated with the specified list identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the list whose options are being retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of option strings for the specified list.</returns>
|
||||
/// <!-- aidoc:v1 sig=f43c75d -->
|
||||
Task<List<string>> GetOptionsOfList(ObjectId id);
|
||||
}
|
||||
@@ -15,12 +15,14 @@ public interface IMasterListServiceFactory
|
||||
/// A service object of type <paramref name="serviceType"/>, or <c>null</c> if there is no service
|
||||
/// object of that type registered.
|
||||
/// </returns>
|
||||
/// <!-- aidoc:v1 sig=8eed041 -->
|
||||
object GetService(Type serviceType);
|
||||
/// <summary>
|
||||
/// Retrieves a service instance from the master list based on the specified service name.
|
||||
/// </summary>
|
||||
/// <param name="serviceName">The <see cref="MasterListType"/> identifier used to look up the desired service.</param>
|
||||
/// <returns>An <see cref="object"/> representing the resolved service, or <see langword="null"/> if no matching service is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=14dc6e0 -->
|
||||
object GetService(MasterListType serviceName);
|
||||
/// <summary>
|
||||
/// Retrieves a typed representation of the specified <paramref name="masterList"/> based on the given <paramref name="masterListType"/>.
|
||||
@@ -28,12 +30,14 @@ public interface IMasterListServiceFactory
|
||||
/// <param name="masterListType">The type that determines how the master list should be converted or filtered.</param>
|
||||
/// <param name="masterList">The master list to be returned in a typed form.</param>
|
||||
/// <returns>A typed object representing the master list, or <c>null</c> if no matching type is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=c73cdf1 -->
|
||||
object? GetTypedMasterList(MasterListType masterListType, MasterList masterList);
|
||||
/// <summary>
|
||||
/// Gets the specific <see cref="Type"/> associated with the given master list type, mapping the master list category to its corresponding implementation type.
|
||||
/// </summary>
|
||||
/// <param name="masterListType">The master list type whose associated <see cref="Type"/> should be returned.</param>
|
||||
/// <returns>The <see cref="Type"/> that corresponds to the specified <paramref name="masterListType"/>.</returns>
|
||||
/// <!-- aidoc:v1 sig=c05f08e -->
|
||||
Type GetMasterListSpecificType(MasterListType masterListType);
|
||||
/// <summary>
|
||||
/// Inserts a new <see cref="MasterList"/> record based on the specified <paramref name="masterListType"/>.
|
||||
@@ -41,6 +45,7 @@ public interface IMasterListServiceFactory
|
||||
/// <param name="masterListType">The type of master list to insert.</param>
|
||||
/// <param name="masterList">The master list entity to be inserted.</param>
|
||||
/// <returns>A task that represents the asynchronous insert operation. The result contains the inserted master list data, or <c>null</c> if the insert was not successful.</returns>
|
||||
/// <!-- aidoc:v1 sig=a5d5b54 -->
|
||||
Task<object?> InsertMasterList(MasterListType masterListType, MasterList masterList);
|
||||
/// <summary>
|
||||
/// Asynchronously updates an existing master list entry based on the specified master list type and master list data.
|
||||
@@ -48,6 +53,7 @@ public interface IMasterListServiceFactory
|
||||
/// <param name="masterListType">The type of master list to update, used to determine the target list or category.</param>
|
||||
/// <param name="masterList">The master list entity containing the updated data to be persisted.</param>
|
||||
/// <returns>A task that represents the asynchronous update operation. The result is an object containing the updated master list information, or <c>null</c> if no matching record was found.</returns>
|
||||
/// <!-- aidoc:v1 sig=6dbb193 -->
|
||||
Task<object?> UpdateMasterList(MasterListType masterListType, MasterList masterList);
|
||||
/// <summary>
|
||||
/// Retrieves a master list entry by its identifier and type, optionally filtered by the specified data locale.
|
||||
@@ -56,11 +62,13 @@ public interface IMasterListServiceFactory
|
||||
/// <param name="masterListId">The unique identifier of the master list entry to retrieve.</param>
|
||||
/// <param name="dataLocale">The optional locale used to resolve localized data; when null, no locale filtering is applied.</param>
|
||||
/// <returns>A task that yields the matching master list entry as an object, or null if no entry is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=edcfcb0 -->
|
||||
Task<object?> GetMasterListById(MasterListType masterListType, ObjectId masterListId, LocaleEnum? dataLocale);
|
||||
/// <summary>
|
||||
/// Retrieves a list of nurse observation entries as string values.
|
||||
/// </summary>
|
||||
/// <returns>A <see cref="List{T}"/> of <see cref="string"/> containing the nurse observation data.</returns>
|
||||
/// <!-- aidoc:v1 sig=1c82859 -->
|
||||
List<string> StringNurseObs();
|
||||
/// <summary>
|
||||
/// Retrieves a translated <see cref="Patient"/> based on the provided <paramref name="unit"/> and <paramref name="locale"/>.
|
||||
@@ -70,6 +78,7 @@ public interface IMasterListServiceFactory
|
||||
/// <param name="locale">The target locale for the translation. May be <c>null</c>.</param>
|
||||
/// <param name="patient">The patient to be translated. May be <c>null</c>.</param>
|
||||
/// <returns>A <see cref="Task{TResult}"/> that resolves to the translated <see cref="Patient"/>, or <c>null</c> if no translation is available.</returns>
|
||||
/// <!-- aidoc:v1 sig=096dcea -->
|
||||
Task<Patient?> GetPatientTraslated(Unit? unit, LocaleEnum? locale, Patient? patient);
|
||||
|
||||
/// <summary>
|
||||
@@ -81,6 +90,7 @@ public interface IMasterListServiceFactory
|
||||
/// <param name="masterListOptionId">The identifier of the master list option to retrieve.</param>
|
||||
/// <param name="dataLocale">The optional locale used to localize the returned option data.</param>
|
||||
/// <returns>A task that yields the matching master list option as an <see cref="object"/>, or <see langword="null"/> if not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=2952bb7 -->
|
||||
Task<object?> GetMasterListOptionById(MasterListType masterListType, ObjectId masterListId,
|
||||
ObjectId masterListOptionId,
|
||||
LocaleEnum? dataLocale);
|
||||
|
||||
@@ -13,83 +13,98 @@ public interface IMedicineService
|
||||
/// </summary>
|
||||
/// <param name="code">The unique code used to look up the medicine.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the matching <see cref="Medicine"/> or <c>null</c> if not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=92ecf01 -->
|
||||
Task<Medicine?> GetByCode(string code);
|
||||
/// <summary>
|
||||
/// Retrieves a list of medicines that match the provided codes or notes.
|
||||
/// </summary>
|
||||
/// <param name="codeNote">A list of strings representing the codes or notes used to look up medicines.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of <see cref="Medicine"/> objects matching the provided codes or notes.</returns>
|
||||
/// <!-- aidoc:v1 sig=14e1a2b -->
|
||||
Task<List<Medicine>> GetByCodeOrNote(List<string> codeNote);
|
||||
/// <summary>
|
||||
/// Retrieves a medicine by its name, returning null if no matching medicine is found.
|
||||
/// </summary>
|
||||
/// <param name="name">The name of the medicine to look up.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the matching <see cref="Medicine"/> or null if not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=a835f90 -->
|
||||
Task<Medicine?> GetByName(string name);
|
||||
/// <summary>
|
||||
/// Retrieves the medicines associated with the specified patient treatments.
|
||||
/// </summary>
|
||||
/// <param name="treatments">The collection of patient treatments, which may include null entries, whose medicines are to be obtained.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the collection of medicines linked to the provided treatments.</returns>
|
||||
/// <!-- aidoc:v1 sig=f7f9499 -->
|
||||
Task<IEnumerable<Medicine>> GetMedicinesOfTreatments(IEnumerable<PatientTreatment?> treatments);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the collection of active medicines associated with the specified patient.
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose active medicines are being queried.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing an enumerable collection of active <see cref="Medicine"/> records for the patient.</returns>
|
||||
/// <!-- aidoc:v1 sig=60d4b58 -->
|
||||
Task<IEnumerable<Medicine>> GetActiveMedicinesByPatient(ObjectId patientId);
|
||||
/// <summary>
|
||||
/// Retrieves a paginated list of medicines based on the provided filter criteria.
|
||||
/// </summary>
|
||||
/// <param name="filter">The pagination filter containing page size, page number, and optional search criteria.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a <see cref="PaginationResponse{T}"/> with the requested <see cref="Medicine"/> items and pagination metadata.</returns>
|
||||
/// <!-- aidoc:v1 sig=719bac1 -->
|
||||
Task<PaginationResponse<Medicine>> GetPaginatedMedicines(PaginationFilter filter);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves all medicines from the data store.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of all <see cref="Medicine"/> entities.</returns>
|
||||
/// <!-- aidoc:v1 sig=84b2421 -->
|
||||
Task<List<Medicine>> GetAll();
|
||||
/// <summary>
|
||||
/// Retrieves a medicine by its unique identifier.
|
||||
/// </summary>
|
||||
/// <param name="medicineId">The unique identifier of the medicine to retrieve.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the <see cref="Medicine"/> if found; otherwise, <c>null</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=a87fd1e -->
|
||||
Task<Medicine?> GetMedicineById(ObjectId medicineId);
|
||||
/// <summary>
|
||||
/// Asynchronously posts a new medicine and returns the created medicine, or null if the operation fails.
|
||||
/// </summary>
|
||||
/// <param name="medicine">The medicine entity to be posted.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the posted <see cref="Medicine"/>, or null if the medicine could not be posted.</returns>
|
||||
/// <!-- aidoc:v1 sig=9decc93 -->
|
||||
Task<Medicine?> PostMedicine(Medicine medicine);
|
||||
/// <summary>
|
||||
/// Updates an existing medicine in the data store and returns the updated entity, or <c>null</c> if no matching medicine was found.
|
||||
/// </summary>
|
||||
/// <param name="medicine">The medicine entity containing the updated values to be persisted.</param>
|
||||
/// <returns>A task that represents the asynchronous update operation. The result is the updated <see cref="Medicine"/> when the update succeeds, or <c>null</c> when the medicine does not exist.</returns>
|
||||
/// <!-- aidoc:v1 sig=2ae8490 -->
|
||||
Task<Medicine?> UpdateMedicine(Medicine medicine);
|
||||
/// <summary>
|
||||
/// Deletes a medicine record identified by the specified identifier.
|
||||
/// </summary>
|
||||
/// <param name="medicineId">The unique identifier of the medicine to delete.</param>
|
||||
/// <!-- aidoc:v1 sig=44a1285 -->
|
||||
Task DeleteMedicineById(ObjectId medicineId);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves all available types as a list of string identifiers.
|
||||
/// </summary>
|
||||
/// <returns>A task representing the asynchronous operation, containing a list of type identifiers.</returns>
|
||||
/// <!-- aidoc:v1 sig=c476963 -->
|
||||
Task<List<string>> GetAllTypes();
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves all available groups, returning their identifiers or names as a list of strings.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of strings representing all groups.</returns>
|
||||
/// <!-- aidoc:v1 sig=060fe47 -->
|
||||
Task<List<string>> GetAllGroups();
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves all available names.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of all names.</returns>
|
||||
/// <!-- aidoc:v1 sig=24a3647 -->
|
||||
Task<List<string>> GetAllNames();
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the complete list of available codes from the data source.
|
||||
/// </summary>
|
||||
/// <returns>A task representing the asynchronous operation, containing a list of code strings.</returns>
|
||||
/// <!-- aidoc:v1 sig=9b0f08a -->
|
||||
Task<List<string>> GetAllCodes();
|
||||
}
|
||||
@@ -11,11 +11,13 @@ public interface INoticeService
|
||||
/// </summary>
|
||||
/// <param name="notice">The notice to delete.</param>
|
||||
/// <returns>A task that represents the asynchronous delete operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=d29db0d -->
|
||||
Task DeleteNoticeAsync(Notice notice);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes a notice identified by the specified identifier.
|
||||
/// </summary>
|
||||
/// <param name="noticeId">The unique identifier of the notice to delete.</param>
|
||||
/// <!-- aidoc:v1 sig=d491033 -->
|
||||
Task DeleteNoticeByIdAsync(ObjectId noticeId);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a <see cref="Notice"/> entity by its unique identifier from the data store.
|
||||
@@ -23,6 +25,7 @@ public interface INoticeService
|
||||
/// </summary>
|
||||
/// <param name="noticeId">The <see cref="ObjectId"/> that uniquely identifies the notice to retrieve.</param>
|
||||
/// <returns>A <see cref="Task{T}"/> containing the matching <see cref="Notice"/>, or <see langword="null"/> if no notice is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=ed98d3c -->
|
||||
Task<Notice?> GetNoticeByIdAsync(ObjectId noticeId);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a collection of notices filtered by the specified notice type.
|
||||
@@ -30,37 +33,44 @@ public interface INoticeService
|
||||
/// </summary>
|
||||
/// <param name="noticeType">The type of notice to filter by.</param>
|
||||
/// <returns>A task containing an enumerable of matching <see cref="Notice"/> objects, or null if none are found.</returns>
|
||||
/// <!-- aidoc:v1 sig=532654c -->
|
||||
Task<IEnumerable<Notice>?> GetNoticeByTypeAsync(string noticeType);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a collection of notices.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains an enumerable collection of <see cref="Notice"/> objects.</returns>
|
||||
/// <!-- aidoc:v1 sig=d3b0c51 -->
|
||||
Task<IEnumerable<Notice>> GetNoticesAsync();
|
||||
/// <summary>
|
||||
/// Inserts a new notice into the data store.
|
||||
/// </summary>
|
||||
/// <param name="notice">The notice entity to insert.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the inserted <see cref="Notice"/>, or <c>null</c> if the notice could not be inserted.</returns>
|
||||
/// <!-- aidoc:v1 sig=9bc91b1 -->
|
||||
Task<Notice?> InsertNotice(Notice notice);
|
||||
/// <summary>
|
||||
/// Asynchronously updates an existing notice in the system.
|
||||
/// </summary>
|
||||
/// <param name="notice">The notice entity containing the updated information to be persisted.</param>
|
||||
/// <!-- aidoc:v1 sig=a1ae02b -->
|
||||
Task UpdateNoticeAsync(Notice notice);
|
||||
/// <summary>
|
||||
/// Persists the provided API request to the data store.
|
||||
/// </summary>
|
||||
/// <param name="apiRequest">The API request to be saved.</param>
|
||||
/// <!-- aidoc:v1 sig=274a023 -->
|
||||
Task SaveRequest(ApiRequest apiRequest);
|
||||
/// <summary>
|
||||
/// Asynchronously persists the specified API request.
|
||||
/// </summary>
|
||||
/// <param name="apiRequest">The API request to save.</param>
|
||||
/// <!-- aidoc:v1 sig=24f178e -->
|
||||
Task SaveRequestAsync(ApiRequest apiRequest);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the collection of notices associated with the specified display identifier.
|
||||
/// </summary>
|
||||
/// <param name="displayId">The identifier of the display whose notices should be retrieved.</param>
|
||||
/// <returns>A task that returns the notices for the display, or <c>null</c> when no notices are found for the given display.</returns>
|
||||
/// <!-- aidoc:v1 sig=9e0ab44 -->
|
||||
Task<IEnumerable<Notice>?> GetNoticesByDisplayId(ObjectId displayId);
|
||||
}
|
||||
@@ -12,6 +12,7 @@ public interface IObservationDemoService
|
||||
/// <param name="patient">The patient for whom the observations are being generated.</param>
|
||||
/// <param name="dataFields">The collection of fields used to drive the observation generation.</param>
|
||||
/// <returns>A task representing the asynchronous operation that returns the list of generated patient observations.</returns>
|
||||
/// <!-- aidoc:v1 sig=4891e1c -->
|
||||
Task<List<PatientObservation>> GenerateObservationByField(Patient patient, List<Field> dataFields);
|
||||
/// <summary>
|
||||
/// Generates a grouped observation for the specified patient based on the provided grouped field configuration.
|
||||
@@ -19,6 +20,7 @@ public interface IObservationDemoService
|
||||
/// <param name="patient">The patient for whom the grouped observation is generated.</param>
|
||||
/// <param name="groupedField">The grouped field definition that determines the grouping criteria for the observation.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the generated <see cref="GroupedObservation"/>.</returns>
|
||||
/// <!-- aidoc:v1 sig=7c0b714 -->
|
||||
Task<GroupedObservation> GenerateGroupedObservation(Patient patient, GroupedField groupedField);
|
||||
/// <summary>
|
||||
/// Generates a list of patient observation alarms for the specified patient based on the provided data alarm fields.
|
||||
@@ -26,5 +28,6 @@ public interface IObservationDemoService
|
||||
/// <param name="patient">The patient for whom the observation alarms are generated.</param>
|
||||
/// <param name="dataAlarmfields">The list of fields used to determine and generate the data alarms.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="PatientObservationAlarm"/> objects generated for the patient.</returns>
|
||||
/// <!-- aidoc:v1 sig=f61d9a3 -->
|
||||
Task<List<PatientObservationAlarm>> GenerateAlarmByField(Patient patient, List<Field> dataAlarmfields);
|
||||
}
|
||||
@@ -19,6 +19,7 @@ public interface IObservationService : IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose observations are to be retrieved.</param>
|
||||
/// <returns>A task that returns an <see cref="IAsyncCursor{TDocument}"/> of <see cref="PatientObservation"/> instances for the given patient.</returns>
|
||||
/// <!-- aidoc:v1 sig=39ad19b -->
|
||||
Task<IAsyncCursor<PatientObservation>> FindByPatientIdAsync(ObjectId patientId);
|
||||
|
||||
/// <summary>
|
||||
@@ -28,6 +29,7 @@ public interface IObservationService : IApiRequestService
|
||||
/// <param name="codingSystem">The coding system used to classify the observations (e.g., LOINC, SNOMED).</param>
|
||||
/// <param name="name">The name of the observation to filter by.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing an <see cref="IAsyncCursor{TDocument}"/> of <see cref="PatientObservation"/> matching the criteria.</returns>
|
||||
/// <!-- aidoc:v1 sig=d7bdee5 -->
|
||||
Task<IAsyncCursor<PatientObservation>> FindByPatientIdAndCodingSystemAsync(ObjectId patientId, string codingSystem,
|
||||
string name);
|
||||
|
||||
@@ -38,6 +40,7 @@ public interface IObservationService : IApiRequestService
|
||||
/// <param name="num">The maximum number of most recent observations to return. Defaults to 2.</param>
|
||||
/// <param name="filterObservations">An optional list of observation codes used to restrict the result set; if null, observations are not filtered by code.</param>
|
||||
/// <returns>A task that resolves to a list of the most recent <see cref="PatientObservation"/> entries matching the criteria.</returns>
|
||||
/// <!-- aidoc:v1 sig=40372b5 -->
|
||||
Task<List<PatientObservation>> FindLastObservations(ObjectId patientId, int num = 2,
|
||||
List<string>? filterObservations = null);
|
||||
|
||||
@@ -45,14 +48,17 @@ public interface IObservationService : IApiRequestService
|
||||
/// Updates the status of the provided patient observations that have reached their expiration.
|
||||
/// </summary>
|
||||
/// <param name="expiredObservations">The list of patient observations to update as expired.</param>
|
||||
/// <!-- aidoc:v1 sig=e7ed4fa -->
|
||||
Task UpdateExpiredObservations(List<PatientObservation> expiredObservations);
|
||||
/// <summary>
|
||||
/// Asynchronously expires observations that are no longer valid and recalculates the dependent data.
|
||||
/// </summary>
|
||||
/// <!-- aidoc:v1 sig=209fa1b -->
|
||||
Task ExpireObservationsAndRecalculateAsync();
|
||||
/// <summary>
|
||||
/// Asynchronously expires active alerts and powers off the device.
|
||||
/// </summary>
|
||||
/// <!-- aidoc:v1 sig=db747c2 -->
|
||||
Task ExpireAlertsAndPowerOffAsync();
|
||||
|
||||
/// <summary>
|
||||
@@ -62,6 +68,7 @@ public interface IObservationService : IApiRequestService
|
||||
/// <param name="name">The name of the observation to filter by.</param>
|
||||
/// <param name="expires">Optional expiration time in seconds applied to the cached results. If <c>null</c>, no expiration is applied.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of the latest unique <see cref="PatientObservation"/> values matching the specified patient and name.</returns>
|
||||
/// <!-- aidoc:v1 sig=cd1a09e -->
|
||||
Task<List<PatientObservation>> FindLatestUniqueValuesByName(ObjectId patientId, string name, int? expires);
|
||||
|
||||
/// <summary>
|
||||
@@ -72,6 +79,7 @@ public interface IObservationService : IApiRequestService
|
||||
/// <param name="mapped">Indicates whether the returned observations should be mapped (default true) or returned in their raw form.</param>
|
||||
/// <param name="ct">The cancellation token used to cancel the asynchronous operation.</param>
|
||||
/// <returns>A task that resolves to a list of the patient's most recent <see cref="PatientObservation"/> entries.</returns>
|
||||
/// <!-- aidoc:v1 sig=5966f87 -->
|
||||
Task<List<PatientObservation>> FindLastObservationsByField(ObjectId patientId,
|
||||
List<Field>? filterObservations = null, bool mapped = true, CancellationToken ct = default);
|
||||
|
||||
@@ -80,6 +88,7 @@ public interface IObservationService : IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose intravenous line observations are being queried.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of nullable <see cref="PatientObservation"/> entries representing the latest intravenous line observations by location, where individual entries may be <c>null</c> when no data is available.</returns>
|
||||
/// <!-- aidoc:v1 sig=b696654 -->
|
||||
Task<List<PatientObservation?>> FindLastIntravenousLinesObservationByLocation(ObjectId patientId);
|
||||
/// <summary>
|
||||
/// Asynchronously inserts a patient observation, with options to control whether the observation is persisted and whether it is mapped.
|
||||
@@ -87,6 +96,7 @@ public interface IObservationService : IApiRequestService
|
||||
/// <param name="patientObservation">The patient observation to insert.</param>
|
||||
/// <param name="persistObs">Indicates whether the observation should be persisted; defaults to <c>true</c>.</param>
|
||||
/// <param name="mapObs">Indicates whether the observation should be mapped; defaults to <c>true</c>.</param>
|
||||
/// <!-- aidoc:v1 sig=f65b171 -->
|
||||
Task InsertObservation(PatientObservation patientObservation, bool persistObs = true, bool mapObs = true);
|
||||
/// <summary>
|
||||
/// Inserts the specified patient observation only if it has changed, optionally persisting the observation and applying a mapping during the insert.
|
||||
@@ -96,22 +106,26 @@ public interface IObservationService : IApiRequestService
|
||||
/// <param name="persistObs">Indicates whether the observation should be persisted when it is inserted. Defaults to <c>true</c>.</param>
|
||||
/// <param name="mapObs">Indicates whether the observation should be mapped as part of the insert operation. Defaults to <c>true</c>.</param>
|
||||
/// <returns>A task that returns <c>true</c> if the observation was inserted because a change was detected; otherwise, <c>false</c> if no insert was performed.</returns>
|
||||
/// <!-- aidoc:v1 sig=2d74a4d -->
|
||||
Task<bool> InsertIfChanged(string name, PatientObservation observation, bool persistObs = true, bool mapObs = true);
|
||||
/// <summary>
|
||||
/// Inserts a new nurse observation for a patient into the underlying data store.
|
||||
/// </summary>
|
||||
/// <param name="obs">The patient observation data recorded by the nurse to be persisted.</param>
|
||||
/// <!-- aidoc:v1 sig=cbc1b6e -->
|
||||
Task InsertNurseObservation(PatientObservation obs);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes records associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The <see cref="ObjectId"/> of the patient whose related records should be removed.</param>
|
||||
/// <!-- aidoc:v1 sig=d457cb9 -->
|
||||
Task DeleteByPatientId(ObjectId id);
|
||||
/// <summary>
|
||||
/// Asynchronously archives the specified patient observation, preserving it for historical or compliance purposes while removing it from the active set.
|
||||
/// </summary>
|
||||
/// <param name="observation">The patient observation to archive.</param>
|
||||
/// <returns>A task that represents the asynchronous archive operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=44e255f -->
|
||||
Task Archive(PatientObservation observation);
|
||||
/// <summary>
|
||||
/// Asynchronously maps a <see cref="PatientObservation"/> to a corresponding observation, optionally restricting the lookup to name-based matching. Returns <see langword="null"/> when no matching observation is found.
|
||||
@@ -119,27 +133,32 @@ public interface IObservationService : IApiRequestService
|
||||
/// <param name="obs">The source <see cref="PatientObservation"/> to be mapped.</param>
|
||||
/// <param name="onlyByName">When <see langword="true"/>, restricts the lookup to name-based matching; otherwise, the default mapping behavior is applied.</param>
|
||||
/// <returns>A <see cref="Task{TResult}"/> containing the mapped <see cref="PatientObservation"/>, or <see langword="null"/> if no match is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=6377232 -->
|
||||
Task<PatientObservation?> MapObservation(PatientObservation obs, bool onlyByName = false);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the most recent observation time for each patient, returning a mapping of patient identifiers to their last observation timestamps.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a dictionary where each key is a patient <see cref="ObjectId"/> and the associated value is the <see cref="DateTime"/> of that patient's latest observation.</returns>
|
||||
/// <!-- aidoc:v1 sig=cbcaa4c -->
|
||||
Task<Dictionary<ObjectId, DateTime>> FindAllLastPatientObservationTime();
|
||||
/// <summary>
|
||||
/// Asynchronously maps or looks up a <see cref="PatientObservation"/> based on the name of the provided observation, returning the matching observation or <c>null</c> when no match is found.
|
||||
/// </summary>
|
||||
/// <param name="obs">The <see cref="PatientObservation"/> whose name is used to perform the mapping or lookup.</param>
|
||||
/// <returns>A <see cref="Task{PatientObservation}"/> that resolves to the matching <see cref="PatientObservation"/>, or <c>null</c> if no corresponding observation is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=a41fe3f -->
|
||||
Task<PatientObservation?> MapObservationsByName(PatientObservation obs);
|
||||
/// <summary>
|
||||
/// Archives the specified patient, moving their record out of the active set so that it is retained for historical or compliance purposes while no longer appearing in routine operational queries.
|
||||
/// </summary>
|
||||
/// <param name="patient">The patient whose record is to be archived.</param>
|
||||
/// <!-- aidoc:v1 sig=52c2373 -->
|
||||
Task Archive(Patient patient);
|
||||
/// <summary>
|
||||
/// Archives records associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the patient whose records should be archived.</param>
|
||||
/// <!-- aidoc:v1 sig=e5916ec -->
|
||||
Task ArchiveByPatientId(ObjectId id);
|
||||
|
||||
/// <summary>
|
||||
@@ -147,6 +166,7 @@ public interface IObservationService : IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="observation">The patient observation containing the updated information.</param>
|
||||
/// <returns>A task that represents the asynchronous update operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=325f985 -->
|
||||
Task UpdateObservation(PatientObservation observation);
|
||||
/// <summary>
|
||||
/// Updates the specified identifier field (<paramref name="nameId"/>) across multiple objects, replacing the existing value <paramref name="oldId"/> with the new value <paramref name="id"/>.
|
||||
@@ -155,24 +175,28 @@ public interface IObservationService : IApiRequestService
|
||||
/// <param name="id">The new <see cref="ObjectId"/> value to assign to the field.</param>
|
||||
/// <param name="oldId">The current <see cref="ObjectId"/> value to be replaced.</param>
|
||||
/// <returns>A task that represents the asynchronous bulk update operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=24ef97c -->
|
||||
Task UpdateManyObjectId(string nameId, ObjectId id, ObjectId oldId);
|
||||
|
||||
/// <summary>
|
||||
/// Asynchronously broadcasts a patient observation to subscribed listeners or endpoints.
|
||||
/// </summary>
|
||||
/// <param name="obs">The base patient observation to be broadcast.</param>
|
||||
/// <!-- aidoc:v1 sig=875526d -->
|
||||
Task SendObsBroadcast(BasePatientObservation obs);
|
||||
/// <summary>
|
||||
/// Sends a broadcast containing the specified patient observations to the given patient location.
|
||||
/// </summary>
|
||||
/// <param name="obs">The list of patient observations to include in the broadcast.</param>
|
||||
/// <param name="location">The target patient location that will receive the broadcast.</param>
|
||||
/// <!-- aidoc:v1 sig=eba4dc4 -->
|
||||
Task SendObsBroadcast(List<PatientObservation> obs, PatientLocation location);
|
||||
/// <summary>
|
||||
/// Asynchronously sends a broadcast of patient observations to the specified Point of Care (POC) system.
|
||||
/// </summary>
|
||||
/// <param name="obs">The list of patient observations to be transmitted in the broadcast.</param>
|
||||
/// <param name="pocId">The identifier of the Point of Care system that will receive the observations.</param>
|
||||
/// <!-- aidoc:v1 sig=7b85a82 -->
|
||||
Task SendObsBroadcast(List<PatientObservation> obs, ObjectId pocId);
|
||||
|
||||
/// <summary>
|
||||
@@ -182,6 +206,7 @@ public interface IObservationService : IApiRequestService
|
||||
/// <param name="date">The cutoff date; only observations recorded strictly before this date are considered.</param>
|
||||
/// <param name="obsName">The optional name of the observation to filter by, or <c>null</c> to match any observation.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the latest matching <see cref="PatientObservation"/>, or <c>null</c> if none was found before the given date.</returns>
|
||||
/// <!-- aidoc:v1 sig=9dd6e55 -->
|
||||
Task<PatientObservation?> FindLastBeforeDate(ObjectId patientId, DateTime date, string? obsName);
|
||||
|
||||
/// <summary>
|
||||
@@ -191,6 +216,7 @@ public interface IObservationService : IApiRequestService
|
||||
/// <param name="date">The date used to match observations.</param>
|
||||
/// <param name="obsName">The optional observation name used to filter the results. When null, observations are not filtered by name.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of matching <see cref="PatientObservation"/> records, or null when no observations match the criteria.</returns>
|
||||
/// <!-- aidoc:v1 sig=b609e73 -->
|
||||
Task<List<PatientObservation>?> FindAnyWithSameDate(ObjectId patientId, DateTime date, string? obsName);
|
||||
|
||||
//TODO To implement
|
||||
@@ -201,6 +227,7 @@ public interface IObservationService : IApiRequestService
|
||||
/// <param name="date">The cutoff date; only observations recorded before this date will be returned.</param>
|
||||
/// <param name="filterObservations">An optional list of observation identifiers used to restrict the results to specific observation types. When null, all observation types are included.</param>
|
||||
/// <returns>A task that resolves to a list of PatientObservation instances matching the criteria.</returns>
|
||||
/// <!-- aidoc:v1 sig=1182280 -->
|
||||
Task<List<PatientObservation>> FindAllBeforeDate(ObjectId patientId, DateTime date,
|
||||
List<string>? filterObservations = null);
|
||||
|
||||
@@ -212,6 +239,7 @@ public interface IObservationService : IApiRequestService
|
||||
/// <param name="date">The cutoff date; only observations with a timestamp after this value are returned.</param>
|
||||
/// <param name="filterObservations">An optional list of observation names to restrict the result to. When <c>null</c> or empty, all observations after the date are returned.</param>
|
||||
/// <returns>A <see cref="Task{T}"/> that yields the list of matching <see cref="PatientObservation"/> entries.</returns>
|
||||
/// <!-- aidoc:v1 sig=793de04 -->
|
||||
Task<List<PatientObservation>> FindAllAfterDate(ObjectId patientId, DateTime date,
|
||||
List<string>? filterObservations = null);
|
||||
|
||||
@@ -225,6 +253,7 @@ public interface IObservationService : IApiRequestService
|
||||
/// <param name="fromArchived">When true, observations are retrieved from archived records; otherwise, only active records are considered.</param>
|
||||
/// <param name="filter">An optional pagination filter applied to the result set.</param>
|
||||
/// <returns>A task that resolves to a list of <see cref="PatientObservation"/> entries matching the provided criteria.</returns>
|
||||
/// <!-- aidoc:v1 sig=2f8c17f -->
|
||||
Task<List<PatientObservation>> FindAllBetweenDates(ObjectId patientId, DateTime? startDate, DateTime? endDate,
|
||||
List<string>? filterObservations = null, bool fromArchived = false, PaginationFilter? filter = null);
|
||||
|
||||
@@ -236,6 +265,7 @@ public interface IObservationService : IApiRequestService
|
||||
/// <param name="endAfter">Optional parameter that defines the pagination boundary; when provided, observations are returned starting after this position.</param>
|
||||
/// <param name="num">Optional parameter that limits the maximum number of observations returned.</param>
|
||||
/// <returns>A task representing the asynchronous operation, containing a collection of matching non-expired <see cref="PatientObservation"/> records; an empty collection is returned if none are found.</returns>
|
||||
/// <!-- aidoc:v1 sig=ba8e6f1 -->
|
||||
Task<IEnumerable<PatientObservation>> FindLastNotExpiredObservatonsByPatient(ObjectId patientId, string name,
|
||||
int? endAfter = null, int? num = null);
|
||||
|
||||
@@ -243,12 +273,14 @@ public interface IObservationService : IApiRequestService
|
||||
/// <summary>
|
||||
/// Checks observations and expires those that meet the expiration criteria.
|
||||
/// </summary>
|
||||
/// <!-- aidoc:v1 sig=0d8befa -->
|
||||
Task CheckAndExpireObservations();
|
||||
|
||||
/// <summary>
|
||||
/// Retrieves patient observations that have not been marked as expired but should be, based on their validity period or business rules.
|
||||
/// </summary>
|
||||
/// <returns>An asynchronous stream of <see cref="PatientObservation"/> instances that are not expired but meet the criteria to be expired.</returns>
|
||||
/// <!-- aidoc:v1 sig=ef73cf5 -->
|
||||
IAsyncEnumerable<PatientObservation> FindNotExpiredObservationsShouldBeExpired();
|
||||
|
||||
|
||||
@@ -259,12 +291,14 @@ public interface IObservationService : IApiRequestService
|
||||
/// <param name="patient">The patient associated with the observations.</param>
|
||||
/// <param name="messageTime">The timestamp of the message containing the observations.</param>
|
||||
/// <param name="observationData">Optional additional data related to the observations.</param>
|
||||
/// <!-- aidoc:v1 sig=26ab597 -->
|
||||
void ProcessObservations(List<PatientObservation> observations, Patient patient, DateTime messageTime,
|
||||
ObservationData? observationData = null);
|
||||
|
||||
/// <summary>
|
||||
/// Asynchronously processes and expires observations that have exceeded their validity period.
|
||||
/// </summary>
|
||||
/// <!-- aidoc:v1 sig=386e4a2 -->
|
||||
Task ExpireObservations();
|
||||
|
||||
/// <summary>
|
||||
@@ -272,16 +306,19 @@ public interface IObservationService : IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="observation">The patient observation to insert.</param>
|
||||
/// <returns>A task that represents the asynchronous insert operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=5bd41b8 -->
|
||||
Task InsertSimpleObservation(PatientObservation observation);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a paginated collection of patient observations based on the specified filter criteria.
|
||||
/// </summary>
|
||||
/// <param name="filter">The pagination filter that controls the page size, page number, and any additional query criteria applied to the patient observations.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a <see cref="PaginationResponse{T}"/> of <see cref="PatientObservation"/> with the requested page of results.</returns>
|
||||
/// <!-- aidoc:v1 sig=55ee5d3 -->
|
||||
Task<PaginationResponse<PatientObservation>> GetPaginatedObservations(PaginationFilter filter);
|
||||
/// <summary>
|
||||
/// Asynchronously saves a nurse observation request.
|
||||
/// </summary>
|
||||
/// <param name="request">The API request containing the nurse observation data to save.</param>
|
||||
/// <!-- aidoc:v1 sig=bc3f3e7 -->
|
||||
Task SaveRequestNurseObsAsync(ApiRequest request);
|
||||
}
|
||||
@@ -11,34 +11,40 @@ public interface IPatientCarePlanService
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose care plans are being retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="PatientCarePlan"/> records for the given patient.</returns>
|
||||
/// <!-- aidoc:v1 sig=6525ef9 -->
|
||||
Task<List<PatientCarePlan>> FindByPatientId(ObjectId patientId);
|
||||
/// <summary>
|
||||
/// Retrieves a list of patient care plans associated with the specified user identifier.
|
||||
/// </summary>
|
||||
/// <param name="userId">The unique identifier of the user whose patient care plans are being retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of patient care plans associated with the user.</returns>
|
||||
/// <!-- aidoc:v1 sig=150426f -->
|
||||
Task<List<PatientCarePlan>> FindByUserId(ObjectId userId);
|
||||
/// <summary>
|
||||
/// Retrieves all patient care plans from the system.
|
||||
/// </summary>
|
||||
/// <returns>A task containing a list of all <see cref="PatientCarePlan"/> records.</returns>
|
||||
/// <!-- aidoc:v1 sig=83af170 -->
|
||||
Task<List<PatientCarePlan>> FindAll();
|
||||
/// <summary>
|
||||
/// Asynchronously inserts a single patient care plan into the underlying data store.
|
||||
/// </summary>
|
||||
/// <param name="patientCarePlan">The patient care plan to insert.</param>
|
||||
/// <!-- aidoc:v1 sig=0e9c8f0 -->
|
||||
Task InsertOneAsync(PatientCarePlan patientCarePlan);
|
||||
/// <summary>
|
||||
/// Archives the care plan associated with a finished procedure for the specified patient, processing the provided list of items to be archived.
|
||||
/// </summary>
|
||||
/// <param name="patientWithFinishedProcedure">The patient whose procedure has been completed and whose care plan should be archived.</param>
|
||||
/// <param name="itemsToArchive">The collection of option list items to be archived as part of the care plan archival process.</param>
|
||||
/// <!-- aidoc:v1 sig=7ddd7f6 -->
|
||||
Task ArchiveCarePlanFromJob(Patient patientWithFinishedProcedure, List<OptionList> itemsToArchive);
|
||||
|
||||
/// <summary>
|
||||
/// Asynchronously archives records associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="patientid">The unique identifier of the patient whose records are to be archived.</param>
|
||||
/// <!-- aidoc:v1 sig=af2b0d3 -->
|
||||
Task ArchiveByPatientId(ObjectId patientid);
|
||||
/// <summary>
|
||||
/// Updates the ObjectId references from the specified old identifier to a new one across multiple records associated with the given patient.
|
||||
@@ -46,5 +52,7 @@ public interface IPatientCarePlanService
|
||||
/// <param name="patientid">The string identifier of the patient whose related records will be updated.</param>
|
||||
/// <param name="patientId">The ObjectId of the patient used to locate the records to update.</param>
|
||||
/// <param name="oldId">The existing ObjectId value to be replaced in the matched records.</param>
|
||||
/// <!-- aidoc-review:v1 severity=medium kind=stale_summary
|
||||
/// "Summary states the method updates references 'to a new one', but the method signature has no parameter for a new ObjectId value; only an oldId is provided for replacement." -->
|
||||
Task UpdateManyObjectId(string patientid, ObjectId patientId, ObjectId oldId);
|
||||
}
|
||||
@@ -17,6 +17,7 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="patientId">The unique identifier of the patient to find.</param>
|
||||
/// <param name="withLocation">When set to <c>true</c>, includes location details in the returned patient; otherwise, only basic patient data is returned.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the found <see cref="Patient"/>, or <c>null</c> if no patient matches the specified identifier.</returns>
|
||||
/// <!-- aidoc:v1 sig=823c22c -->
|
||||
Task<Patient?> FindByPatientId(string patientId, bool withLocation = false);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a patient by their unique identifier, applying the specified locale for localized data.
|
||||
@@ -24,12 +25,14 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="patientId">The unique identifier of the patient to locate.</param>
|
||||
/// <param name="localeEnum">The locale to use when retrieving or formatting localized patient information.</param>
|
||||
/// <returns>A task that resolves to the matching patient, or <c>null</c> if no patient is found for the given identifier.</returns>
|
||||
/// <!-- aidoc:v1 sig=0b2d8b0 -->
|
||||
Task<Patient?> FindByPatientIdWithLocale(string patientId, LocaleEnum localeEnum);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves an archived <see cref="Patient"/> matching the specified patient number, returning <c>null</c> when no matching archived record is found.
|
||||
/// </summary>
|
||||
/// <param name="patientNumber">The unique patient number used to look up the archived patient record.</param>
|
||||
/// <returns>A <see cref="Task{Patient}"/> that yields the matching archived <see cref="Patient"/>, or <c>null</c> if no archived patient is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=38fda84 -->
|
||||
Task<Patient?> FindByPatientNumberArchived(string patientNumber);
|
||||
/// <summary>
|
||||
/// Retrieves a patient by their unique patient number, optionally including location information in the result.
|
||||
@@ -37,6 +40,7 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="patientNumber">The unique patient number used to look up the patient.</param>
|
||||
/// <param name="withLocation">When <c>true</c>, location information is included in the returned patient; otherwise, it is omitted.</param>
|
||||
/// <returns>A task that yields the matching <see cref="Patient"/> if one is found, or <c>null</c> when no patient matches the given number.</returns>
|
||||
/// <!-- aidoc:v1 sig=d9f5471 -->
|
||||
Task<Patient?> FindByPatientNumber(string patientNumber, bool withLocation = false);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a patient associated with the specified location.
|
||||
@@ -44,12 +48,14 @@ public interface IPatientService : IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="location">The patient location used to search for a matching patient. May be <see langword="null"/>.</param>
|
||||
/// <returns>A <see cref="Task{TResult}"/> that yields the matching <see cref="Patient"/>, or <see langword="null"/> if no patient is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=ca2dffa -->
|
||||
Task<Patient?> FindByLocation(PatientLocation? location);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a patient associated with the specified Point of Care identifier.
|
||||
/// </summary>
|
||||
/// <param name="pocId">The ObjectId representing the Point of Care identifier used to look up the patient.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the matching <see cref="Patient"/> if found; otherwise, <c>null</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=1336816 -->
|
||||
Task<Patient?> FindByPointOfCareId(ObjectId pocId);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a patient identified by the specified unit and point-of-care identifiers.
|
||||
@@ -57,18 +63,21 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="unit">The unique identifier of the unit to search within.</param>
|
||||
/// <param name="pointOfCare">The unique identifier of the point-of-care associated with the patient.</param>
|
||||
/// <returns>A task that yields the matching <see cref="Patient"/>, or <c>null</c> if no patient is found for the given unit and point-of-care.</returns>
|
||||
/// <!-- aidoc:v1 sig=a028676 -->
|
||||
Task<Patient?> FindByUnitAndPocId(ObjectId unit, ObjectId pointOfCare);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a list of patients associated with the specified point of care.
|
||||
/// </summary>
|
||||
/// <param name="pointOfCare">The point of care identifier used to locate matching patients.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="Patient"/> objects that match the specified point of care.</returns>
|
||||
/// <!-- aidoc:v1 sig=c2cb9ce -->
|
||||
Task<List<Patient>> FindByPointOfCare(string pointOfCare);
|
||||
/// <summary>
|
||||
/// Asynchronously counts the number of patients associated with the specified unit identifier.
|
||||
/// </summary>
|
||||
/// <param name="unitId">The ObjectId of the unit whose patients should be counted.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the total count of patients for the given unit.</returns>
|
||||
/// <!-- aidoc:v1 sig=867c6c1 -->
|
||||
Task<long> CountPatientsByUnitId(ObjectId unitId);
|
||||
|
||||
/// <summary>
|
||||
@@ -82,6 +91,7 @@ public interface IPatientService : IApiRequestService
|
||||
/// <paramref name="location"/> instead of the patient identifiers.</param>
|
||||
/// <returns>A <see cref="Task{Patient}"/> that yields the matching <see cref="Patient"/>, or
|
||||
/// <c>null</c> if no patient is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=9cea35f -->
|
||||
Task<Patient?> FindPatient(string? patientId, string? patientNumber, PatientLocation? location,
|
||||
bool findByLocation = false);
|
||||
|
||||
@@ -89,33 +99,39 @@ public interface IPatientService : IApiRequestService
|
||||
/// Asynchronously inserts a new patient record into the data store.
|
||||
/// </summary>
|
||||
/// <param name="patient">The patient entity to be inserted.</param>
|
||||
/// <!-- aidoc:v1 sig=3c6f3e8 -->
|
||||
Task Insert(Patient patient);
|
||||
/// <summary>
|
||||
/// Asynchronously inserts the specified <see cref="Patient"/> into the data store.
|
||||
/// </summary>
|
||||
/// <param name="patient">The patient entity to be persisted.</param>
|
||||
/// <!-- aidoc:v1 sig=6e78a3b -->
|
||||
Task InsertAsync(Patient patient);
|
||||
/// <summary>
|
||||
/// Archives the specified patient record.
|
||||
/// </summary>
|
||||
/// <param name="patient">The patient to archive.</param>
|
||||
/// <!-- aidoc:v1 sig=a500807 -->
|
||||
Task ArchivePatient(Patient patient);
|
||||
/// <summary>
|
||||
/// Archives the patient data identified by the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="patientid">The unique identifier of the patient whose data should be archived.</param>
|
||||
/// <!-- aidoc:v1 sig=1a00b68 -->
|
||||
Task ArchivePatientData(ObjectId patientid);
|
||||
/// <summary>
|
||||
/// Merges the specified patient record with the existing patient identified by the old patient number.
|
||||
/// </summary>
|
||||
/// <param name="patient">The patient data to merge into the existing record.</param>
|
||||
/// <param name="oldPatienNumber">The identifier of the existing patient record to be merged.</param>
|
||||
/// <!-- aidoc:v1 sig=1e8bdc4 -->
|
||||
Task MergePatient(Patient patient, string oldPatienNumber);
|
||||
/// <summary>
|
||||
/// Updates the location of a patient identified by the specified object identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the patient whose location will be updated.</param>
|
||||
/// <param name="location">The new patient location, or <c>null</c> if no location is provided.</param>
|
||||
/// <!-- aidoc:v1 sig=aa67e50 -->
|
||||
Task UpdateLocation(ObjectId id, PatientLocation? location);
|
||||
/// <summary>
|
||||
/// Updates the attending doctor for the entity identified by the specified identifier.
|
||||
@@ -123,6 +139,7 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="id">The identifier of the entity whose attending doctor will be updated.</param>
|
||||
/// <param name="doctor">The new attending doctor to assign to the entity.</param>
|
||||
/// <returns>A task that represents the asynchronous update operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=c6b59f4 -->
|
||||
Task UpdateAttendingDoctor(ObjectId id, Person doctor);
|
||||
/// <summary>
|
||||
/// Updates the data of an existing patient identified by the given identifier, optionally replacing the patient number when the <paramref name="updatePatientNumber"/> flag is true.
|
||||
@@ -131,6 +148,7 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="patientNumber">The patient number to be applied to the patient.</param>
|
||||
/// <param name="data">The person data to assign to the patient.</param>
|
||||
/// <param name="updatePatientNumber">Indicates whether the patient number should also be updated; defaults to true.</param>
|
||||
/// <!-- aidoc:v1 sig=c9778ad -->
|
||||
Task UpdatePatientData(ObjectId id, string patientNumber, Person data, bool updatePatientNumber = true);
|
||||
/// <summary>
|
||||
/// Updates the patient data for the specified patient identified by <paramref name="id"/> and <paramref name="patientNumber"/>, applying the changes from the provided <paramref name="patient"/> object. When <paramref name="updatePatientNumber"/> is <c>true</c>, the patient number is also updated as part of the operation; otherwise, only the remaining patient fields are updated.
|
||||
@@ -140,11 +158,13 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="patient">The patient object containing the updated data to be applied.</param>
|
||||
/// <param name="updatePatientNumber">A flag indicating whether the patient number should also be updated; defaults to <c>true</c>.</param>
|
||||
/// <returns>A <see cref="Task"/> that represents the asynchronous update operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=d6fb956 -->
|
||||
Task UpdatePatientData(ObjectId id, string patientNumber, Patient patient, bool updatePatientNumber = true);
|
||||
/// <summary>
|
||||
/// Updates the specified patient record.
|
||||
/// </summary>
|
||||
/// <param name="patient">The patient whose information will be updated.</param>
|
||||
/// <!-- aidoc:v1 sig=0688359 -->
|
||||
Task Update(Patient patient);
|
||||
/// <summary>
|
||||
/// Moves the specified patient from the old point of care to the new point of care.
|
||||
@@ -153,6 +173,7 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="newPocId">The identifier of the destination point of care.</param>
|
||||
/// <param name="oldPocId">The identifier of the source point of care.</param>
|
||||
/// <returns>A task that resolves to <c>true</c> if the move was successful; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=40515dd -->
|
||||
Task<bool> Move(Patient patient, ObjectId newPocId, ObjectId oldPocId);
|
||||
/// <summary>
|
||||
/// Retrieves a patient by their unique identifier, optionally including location information.
|
||||
@@ -161,6 +182,7 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="id">The <see cref="ObjectId"/> used to look up the patient.</param>
|
||||
/// <param name="withLocation">When <c>true</c>, includes the patient's location data in the result; otherwise, location data is omitted.</param>
|
||||
/// <returns>A <see cref="Task{T}"/> that resolves to the matching <see cref="Patient"/>, or <c>null</c> if no patient is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=a1146e7 -->
|
||||
Task<Patient?> FindById(ObjectId id, bool withLocation = false);
|
||||
/// <summary>
|
||||
/// Retrieves a <see cref="Box"/> associated with the specified <see cref="PointOfCare"/>, returning <see langword="null"/> when no box is found for the given point of care.
|
||||
@@ -169,6 +191,7 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="observations">When <see langword="true"/>, observations are included with the returned box; otherwise, observations are omitted.</param>
|
||||
/// <param name="filterObservations">An optional list of observation identifiers used to restrict which observations are loaded when <paramref name="observations"/> is <see langword="true"/>.</param>
|
||||
/// <returns>A <see cref="Task{Box}"/> that resolves to the matching <see cref="Box"/>, or <see langword="null"/> if no box exists for the specified point of care.</returns>
|
||||
/// <!-- aidoc:v1 sig=8cd91c3 -->
|
||||
Task<Box?> GetBox(PointOfCare poc, bool observations = false, List<string>? filterObservations = null);
|
||||
/// <summary>
|
||||
/// Creates a <see cref="Patient"/> instance from the provided <see cref="ApiRequest"/>, optionally ignoring location information during the creation process.
|
||||
@@ -176,35 +199,41 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="apiRequest">The API request containing the data used to construct the patient.</param>
|
||||
/// <param name="ignoreLocation">When <c>true</c>, location information is ignored during patient creation. Defaults to <c>false</c>.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the created <see cref="Patient"/>, or <c>null</c> if the patient could not be created.</returns>
|
||||
/// <!-- aidoc:v1 sig=f7ca273 -->
|
||||
Task<Patient?> CreatePatientFromRequest(ApiRequest apiRequest, bool ignoreLocation = false);
|
||||
/// <summary>
|
||||
/// Asynchronously finds a patient based on the information provided in the specified API request.
|
||||
/// </summary>
|
||||
/// <param name="apiRequest">The API request containing the data used to look up the patient.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the matching <see cref="Patient"/> if found, or null if no patient matches the request.</returns>
|
||||
/// <!-- aidoc:v1 sig=9bc220c -->
|
||||
Task<Patient?> FindPatientByApiRequest(ApiRequest apiRequest);
|
||||
/// <summary>
|
||||
/// Archives patients who have no observations recorded since the specified date.
|
||||
/// </summary>
|
||||
/// <param name="date">The cutoff date; patients without observations after this date are archived.</param>
|
||||
/// <!-- aidoc:v1 sig=ab342f5 -->
|
||||
Task ArchivePatientWithoutObservationsSinceDate(DateTime date);
|
||||
|
||||
/// <summary>
|
||||
/// Archives patient records for patients who have been discharged longer than the specified time threshold.
|
||||
/// </summary>
|
||||
/// <param name="hoursBeforeArchive">The number of hours a patient must have been discharged before being archived.</param>
|
||||
/// <!-- aidoc:v1 sig=218184e -->
|
||||
Task ArchiveDischargedPatients(int hoursBeforeArchive);
|
||||
/// <summary>
|
||||
/// Retrieves all patients, optionally including their location data when requested.
|
||||
/// </summary>
|
||||
/// <param name="withLocation">Indicates whether location information should be included in the returned patient records.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="Patient"/> objects.</returns>
|
||||
/// <!-- aidoc:v1 sig=4462ed0 -->
|
||||
Task<List<Patient>> FindAll(bool withLocation = false);
|
||||
/// <summary>
|
||||
/// Retrieves a paginated list of patients based on the provided pagination filter.
|
||||
/// </summary>
|
||||
/// <param name="filter">The pagination filter that defines the paging criteria used to retrieve patients.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a <see cref="PaginationResponse{Patient}"/> with the requested page of patients.</returns>
|
||||
/// <!-- aidoc:v1 sig=8405329 -->
|
||||
Task<PaginationResponse<Patient>> GetPaginatedPatients(PaginationFilter filter);
|
||||
|
||||
/// <summary>
|
||||
@@ -212,34 +241,40 @@ public interface IPatientService : IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="sinceDate">The date used to identify patients that have been inactive since this point in time.</param>
|
||||
/// <param name="hoursBeforeArchive">The number of hours of inactivity that must elapse before a discharged patient is archived.</param>
|
||||
/// <!-- aidoc:v1 sig=ac3e223 -->
|
||||
Task DischargeInactivePatients(DateTime sinceDate, int hoursBeforeArchive);
|
||||
/// <summary>
|
||||
/// Updates an existing patient record with the provided patient data. Returns the updated patient, or <c>null</c> if no matching patient was found.
|
||||
/// </summary>
|
||||
/// <param name="updatedPatient">The patient object containing the updated information to be persisted.</param>
|
||||
/// <returns>A <see cref="Task{Patient}"/> that resolves to the updated <see cref="Patient"/>, or <c>null</c> if the patient could not be found.</returns>
|
||||
/// <!-- aidoc:v1 sig=1b69c26 -->
|
||||
Task<Patient?> UpdateOne(Patient updatedPatient);
|
||||
|
||||
/// <summary>
|
||||
/// Sends an asynchronous broadcast notification to inform relevant subscribers or systems about a newly registered patient.
|
||||
/// </summary>
|
||||
/// <param name="patient">The patient whose information will be included in the broadcast notification.</param>
|
||||
/// <!-- aidoc:v1 sig=8b73b63 -->
|
||||
Task SendNewPatientBroadcast(Patient patient);
|
||||
/// <summary>
|
||||
/// Asynchronously sends a broadcast notification about an update to the specified patient.
|
||||
/// </summary>
|
||||
/// <param name="patient">The patient whose update information will be broadcast.</param>
|
||||
/// <!-- aidoc:v1 sig=9f4f683 -->
|
||||
Task SendPatientUpdateBroadcast(Patient patient);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the list of inactive Patients of Care (PoC), allowing consumers to identify
|
||||
/// patients that are no longer active in the system for reporting, cleanup, or follow-up workflows.
|
||||
/// </summary>
|
||||
/// <returns>A task representing the asynchronous operation, containing a list of inactive <see cref="Patient"/> records.</returns>
|
||||
/// <!-- aidoc:v1 sig=1eb056c -->
|
||||
Task<List<Patient>> FindInActivePoC();
|
||||
/// <summary>
|
||||
/// Retrieves a list of patients associated with inactive PoC records.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of <see cref="Patient"/> objects associated with inactive PoC records.</returns>
|
||||
/// <!-- aidoc:v1 sig=ace85d3 -->
|
||||
Task<List<Patient>> FindInInactivePoC();
|
||||
|
||||
/// <summary>
|
||||
@@ -250,6 +285,7 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="observations">Indicates whether the patient's observations should be included in the returned patient.</param>
|
||||
/// <param name="filterObservations">An optional list of observation identifiers used to filter which observations are returned when <paramref name="observations"/> is <c>true</c>.</param>
|
||||
/// <returns>A <see cref="Task{Patient}"/> that resolves to the matching <see cref="Patient"/>, or <c>null</c> if no patient is found for the given point of care.</returns>
|
||||
/// <!-- aidoc:v1 sig=d512c37 -->
|
||||
Task<Patient?> GetByPointOfCare(PointOfCare item, bool observations = false,
|
||||
List<string>? filterObservations = null);
|
||||
|
||||
@@ -260,6 +296,7 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="unit">An optional unit that further filters the lookup.</param>
|
||||
/// <param name="localeEnum">An optional locale used to scope the search.</param>
|
||||
/// <returns>A task that yields the matching <see cref="Patient"/>, or <c>null</c> when no patient is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=7e6d4de -->
|
||||
Task<Patient?> GetByPointOfCareAndLocale(PointOfCare item, Unit? unit, LocaleEnum? localeEnum);
|
||||
/// <summary>
|
||||
/// Updates the altable (allergy table) information for the specified patient and returns the updated patient.
|
||||
@@ -268,12 +305,14 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="altable">The option list containing the altable data to apply to the patient.</param>
|
||||
/// <param name="user">The user performing the update, or <c>null</c> when no user context is available.</param>
|
||||
/// <returns>A task that resolves to the updated <see cref="Patient"/>, or <c>null</c> if the patient was not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=6bc7695 -->
|
||||
Task<Patient?> UpdatePatientAltable(ObjectId patientId, OptionList altable, User? user);
|
||||
/// <summary>
|
||||
/// Exits a patient identified by the given identifier, optionally archiving the patient record.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the patient to exit.</param>
|
||||
/// <param name="archivePatient">When true, the patient record is archived as part of the exit process; when false, archiving is skipped.</param>
|
||||
/// <!-- aidoc:v1 sig=8436023 -->
|
||||
Task ExitPatientById(ObjectId id, bool archivePatient = true);
|
||||
|
||||
/// <summary>
|
||||
@@ -285,6 +324,7 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="user">The user performing the update, or null if not specified.</param>
|
||||
/// <param name="carePlanLog">Optional care plan log entries associated with the update.</param>
|
||||
/// <returns>A task that returns the updated <see cref="Patient"/>, or null if the patient was not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=003aa16 -->
|
||||
Task<Patient?> UpdatePatientMasterList(ObjectId patientId, MasterListType typeName,
|
||||
List<OptionList> updatedOptions,
|
||||
User? user, List<OptionList>? carePlanLog);
|
||||
@@ -297,6 +337,7 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="patient">The patient for whom the nurse care plan is generated and inserted.</param>
|
||||
/// <param name="user">The user associated with the care plan generation. May be null.</param>
|
||||
/// <returns>A task that completes when the nurse care plan has been generated and inserted.</returns>
|
||||
/// <!-- aidoc:v1 sig=ddba9de -->
|
||||
Task GenerateNurseCarePlanAndInsert(MasterListType carePlanType, List<OptionList>? options,
|
||||
Patient patient, User? user);
|
||||
|
||||
@@ -305,6 +346,7 @@ public interface IPatientService : IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose incoming data is being updated.</param>
|
||||
/// <param name="person">The patient object containing the incoming data to be applied to the patient record.</param>
|
||||
/// <!-- aidoc:v1 sig=43355e2 -->
|
||||
Task UpdatePatientIncomingData(ObjectId patientId, Patient person);
|
||||
/// <summary>
|
||||
/// Asynchronously updates the demographic data of an existing patient identified by the specified patient identifier.
|
||||
@@ -312,6 +354,7 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="patientId">The unique identifier of the patient whose demographic data is to be updated.</param>
|
||||
/// <param name="person">The patient object containing the new demographic information to apply.</param>
|
||||
/// <param name="user">The user performing the update operation, or <see langword="null"/> if no user context is available.</param>
|
||||
/// <!-- aidoc:v1 sig=592313b -->
|
||||
Task UpdatePatientDemographicData(ObjectId patientId, Patient person, User? user);
|
||||
/// <summary>
|
||||
/// Searches for a patient by their patient number within a distinct unit.
|
||||
@@ -319,24 +362,28 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="patientNumber">The patient number used to identify the patient.</param>
|
||||
/// <param name="unitId">The identifier of the distinct unit where the patient is registered.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the matching <see cref="Patient"/> if found; otherwise, <see langword="null"/>.</returns>
|
||||
/// <!-- aidoc:v1 sig=1d70651 -->
|
||||
Task<Patient?> SearchByPatientNumberAndDistinctUnit(string patientNumber, ObjectId unitId);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves all patients whose procedures have been finished, filtering based on the specified archive threshold for procedure end times.
|
||||
/// </summary>
|
||||
/// <param name="archiveProcedureEndDateAfterMinutes">The number of minutes after the procedure end date used as the archive threshold to qualify patients with finished procedures.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="Patient"/> objects that match the finished procedures criteria.</returns>
|
||||
/// <!-- aidoc:v1 sig=d37257e -->
|
||||
Task<List<Patient>> FindAllPatientWithFinishedProcedures(int archiveProcedureEndDateAfterMinutes);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves all patients who have completed a test, using the specified archive window in minutes to determine which tests are considered finished.
|
||||
/// </summary>
|
||||
/// <param name="archiveTestEndDateAfterMinutes">The time window in minutes applied to the test end date to identify tests that should be treated as finished/archived.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="Patient"/> instances with finished tests.</returns>
|
||||
/// <!-- aidoc:v1 sig=650b7bb -->
|
||||
Task<List<Patient>> FindAllPatientWithFinishedTest(int archiveTestEndDateAfterMinutes);
|
||||
/// <summary>
|
||||
/// Retrieves a list of patients whose treatments have finished, based on the specified archive time threshold in minutes after the treatment end date.
|
||||
/// </summary>
|
||||
/// <param name="archiveTreatmentEndDateAfterMinutes">The number of minutes after the treatment end date used to determine which finished treatments should be included.</param>
|
||||
/// <returns>A task representing the asynchronous operation, containing a list of patients with finished treatment matching the specified criteria.</returns>
|
||||
/// <!-- aidoc:v1 sig=bef780c -->
|
||||
Task<List<Patient>> FindAllPatientWithFinishedTreatment(int archiveTreatmentEndDateAfterMinutes);
|
||||
|
||||
/// <summary>
|
||||
@@ -346,6 +393,7 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="person">The patient entity associated with the update.</param>
|
||||
/// <param name="personDataChange">The income data changes to apply to the patient.</param>
|
||||
/// <param name="user">The user performing the update operation.</param>
|
||||
/// <!-- aidoc:v1 sig=9a965eb -->
|
||||
Task UpdatePatientIncomingData(ObjectId patientId, Patient person, PatientIncomeData personDataChange,
|
||||
User user);
|
||||
|
||||
@@ -355,6 +403,7 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="opt">The update options for the master list item.</param>
|
||||
/// <param name="unitList">The collection of units associated with the update.</param>
|
||||
/// <param name="typeName">The name of the type used to categorize the master list item.</param>
|
||||
/// <!-- aidoc:v1 sig=6d7dd8e -->
|
||||
Task UpdatePatientMasterListItemChange(UpdateOptionMasterListDto opt, IEnumerable<Unit> unitList,
|
||||
string typeName);
|
||||
|
||||
@@ -364,5 +413,6 @@ public interface IPatientService : IApiRequestService
|
||||
/// <param name="opt">The option list containing the details of the patient master list item to delete.</param>
|
||||
/// <param name="unitList">The collection of units associated with the patient master list item.</param>
|
||||
/// <param name="typeName">The name of the type identifying the patient master list item to be deleted.</param>
|
||||
/// <!-- aidoc:v1 sig=bbc71d1 -->
|
||||
Task DeletePatientMasterListItem(OptionList opt, IEnumerable<Unit> unitList, string typeName);
|
||||
}
|
||||
@@ -12,6 +12,7 @@ public interface IPermissionService
|
||||
/// <param name="display">The display for which permissions are being evaluated.</param>
|
||||
/// <param name="user">The user whose permissions for the display are being retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the <see cref="DisplayPermissionTypes"/> granted to the user for the display.</returns>
|
||||
/// <!-- aidoc:v1 sig=ba241eb -->
|
||||
public Task<DisplayPermissionTypes> GetPermissionsForDisplay(Display display, User user);
|
||||
/// <summary>
|
||||
/// Retrieves the display-friendly permission types applicable to the specified user for the given unit.
|
||||
@@ -19,18 +20,21 @@ public interface IPermissionService
|
||||
/// <param name="unitId">The identifier of the unit whose permissions are being queried.</param>
|
||||
/// <param name="user">The user whose permissions for the unit should be evaluated.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the <see cref="DisplayPermissionTypes"/> for the specified unit and user.</returns>
|
||||
/// <!-- aidoc:v1 sig=a645ad9 -->
|
||||
public Task<DisplayPermissionTypes> GetPermissionsForUnit(string unitId, User user);
|
||||
/// <summary>
|
||||
/// Retrieves the panel permission types associated with the specified user.
|
||||
/// </summary>
|
||||
/// <param name="user">The user whose panel permissions are being queried.</param>
|
||||
/// <returns>The <see cref="PanelPermissionTypes"/> granted to the specified user.</returns>
|
||||
/// <!-- aidoc:v1 sig=a5da6a5 -->
|
||||
public PanelPermissionTypes GetPermissionsForPanel(User user);
|
||||
/// <summary>
|
||||
/// Retrieves the panel permission types associated with the specified user.
|
||||
/// </summary>
|
||||
/// <param name="user">The identifier or name of the user whose panel permissions are being requested.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the <see cref="PanelPermissionTypes"/> granted to the user.</returns>
|
||||
/// <!-- aidoc:v1 sig=7d60015 -->
|
||||
public Task<PanelPermissionTypes> GetPermissionsForPanel(string user);
|
||||
|
||||
/// <summary>
|
||||
@@ -41,6 +45,7 @@ public interface IPermissionService
|
||||
/// <param name="source">The source permission type considered when evaluating access.</param>
|
||||
/// <param name="displayId">The identifier of the display for which access is being checked.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result is <c>true</c> if the user has access to the display; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=d0c67ae -->
|
||||
Task<bool> HasAccessToDisplay(string username, PermissionEnum.RolesType role,
|
||||
PermissionEnum.SourcePermissionsEnum source, string displayId);
|
||||
|
||||
@@ -52,6 +57,7 @@ public interface IPermissionService
|
||||
/// <param name="source">The permission source used to resolve the user's access rights.</param>
|
||||
/// <param name="unitId">The identifier of the unit to check access against.</param>
|
||||
/// <returns>A task that resolves to <c>true</c> if the user has access to the specified unit; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=382550b -->
|
||||
Task<bool> HasAccessToUnit(string username, PermissionEnum.RolesType role,
|
||||
PermissionEnum.SourcePermissionsEnum source, string unitId);
|
||||
|
||||
@@ -62,6 +68,7 @@ public interface IPermissionService
|
||||
/// <param name="role">The role assigned to the user, used to resolve applicable permissions.</param>
|
||||
/// <param name="source">The source permission being checked against the user's access rights.</param>
|
||||
/// <returns>A task that resolves to <c>true</c> if the user has access to the panel; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=b661393 -->
|
||||
Task<bool> HasAccessToPanel(string username, PermissionEnum.RolesType role,
|
||||
PermissionEnum.SourcePermissionsEnum source);
|
||||
}
|
||||
@@ -9,5 +9,6 @@ public interface IPoCMappingService
|
||||
/// </summary>
|
||||
/// <param name="original">The source patient location to map from.</param>
|
||||
/// <returns>A task that yields the mapped <see cref="PatientLocation"/>, or <c>null</c> if no mapping result is available.</returns>
|
||||
/// <!-- aidoc:v1 sig=e9beb22 -->
|
||||
Task<PatientLocation?> Map(PatientLocation original);
|
||||
}
|
||||
@@ -14,6 +14,7 @@ public interface IPointOfCareService
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the entity to delete.</param>
|
||||
/// <returns>A task that represents the asynchronous delete operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=0112d17 -->
|
||||
Task Delete(ObjectId id);
|
||||
|
||||
/// <summary>
|
||||
@@ -21,6 +22,7 @@ public interface IPointOfCareService
|
||||
/// </summary>
|
||||
/// <param name="pointOfCare">The point of care entity containing the updated data.</param>
|
||||
/// <returns>A task representing the asynchronous operation, containing the updated point of care, or null if no matching record was found.</returns>
|
||||
/// <!-- aidoc:v1 sig=6e2aa0e -->
|
||||
Task<PointOfCare?> Update(PointOfCare pointOfCare);
|
||||
|
||||
/// <summary>
|
||||
@@ -28,22 +30,26 @@ public interface IPointOfCareService
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the unit to update.</param>
|
||||
/// <param name="unit">The unit data to apply to the existing record.</param>
|
||||
/// <!-- aidoc:v1 sig=d59a50c -->
|
||||
Task UpdateUnit(ObjectId id, Unit unit);
|
||||
/// <summary>
|
||||
/// Retrieves all PointOfCare records asynchronously.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of all PointOfCare entries.</returns>
|
||||
/// <!-- aidoc:v1 sig=8074bfb -->
|
||||
Task<List<PointOfCare>> GetAll();
|
||||
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves all PointOfCare configurations.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of all <see cref="PointOfCare"/> configurations.</returns>
|
||||
/// <!-- aidoc:v1 sig=b9af568 -->
|
||||
Task<List<PointOfCare>> GetAllConfigs();
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves all point-of-care location information.
|
||||
/// </summary>
|
||||
/// <returns>A task representing the asynchronous operation, containing a list of all <see cref="PointOfCare"/> locations.</returns>
|
||||
/// <!-- aidoc:v1 sig=c0c2738 -->
|
||||
Task<List<PointOfCare>> GetAllLocationInfo();
|
||||
|
||||
/// <summary>
|
||||
@@ -51,6 +57,7 @@ public interface IPointOfCareService
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the point of care configuration to update.</param>
|
||||
/// <param name="configuration">The new configuration data to apply.</param>
|
||||
/// <!-- aidoc:v1 sig=92922a6 -->
|
||||
Task UpdateConfiguration(ObjectId id, PointOfCareConfiguration configuration);
|
||||
|
||||
/// <summary>
|
||||
@@ -58,12 +65,14 @@ public interface IPointOfCareService
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the <see cref="PointOfCare"/> to look up.</param>
|
||||
/// <returns>A task that represents the asynchronous lookup operation. The task result contains the matching <see cref="PointOfCare"/> if found, or null when no entity with the specified identifier exists.</returns>
|
||||
/// <!-- aidoc:v1 sig=f01a187 -->
|
||||
Task<PointOfCare?> FindById(ObjectId id);
|
||||
/// <summary>
|
||||
/// Retrieves a <see cref="PointOfCare"/> entity by its identifier, including all of its associated configuration data.
|
||||
/// </summary>
|
||||
/// <param name="id">The <see cref="ObjectId"/> of the <see cref="PointOfCare"/> to locate.</param>
|
||||
/// <returns>A task that yields the matching <see cref="PointOfCare"/> with its full configuration, or <c>null</c> if no entity is found for the supplied identifier.</returns>
|
||||
/// <!-- aidoc:v1 sig=810206b -->
|
||||
Task<PointOfCare?> FindByIdAllConfig(ObjectId id);
|
||||
|
||||
/// <summary>
|
||||
@@ -71,6 +80,7 @@ public interface IPointOfCareService
|
||||
/// </summary>
|
||||
/// <param name="unit">The unique identifier of the unit whose PointOfCare records should be retrieved.</param>
|
||||
/// <returns>A task that returns a collection of PointOfCare records for the specified unit, or <c>null</c> if no records are found.</returns>
|
||||
/// <!-- aidoc:v1 sig=d969dd8 -->
|
||||
Task<IEnumerable<PointOfCare>?> FindAllByUnitId(ObjectId unit);
|
||||
|
||||
/// <summary>
|
||||
@@ -78,6 +88,7 @@ public interface IPointOfCareService
|
||||
/// </summary>
|
||||
/// <param name="room">The room identifier used to look up the associated Points of Care.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains an enumerable of Points of Care found for the given room, or <c>null</c> if no matching results are found.</returns>
|
||||
/// <!-- aidoc:v1 sig=4637691 -->
|
||||
Task<IEnumerable<PointOfCare>?> FindByRoom(string room);
|
||||
|
||||
/// <summary>
|
||||
@@ -85,6 +96,7 @@ public interface IPointOfCareService
|
||||
/// </summary>
|
||||
/// <param name="bed">The bed identifier used to look up the associated points of care.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a collection of <see cref="PointOfCare"/> instances matching the bed, or <c>null</c> if no match is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=604796d -->
|
||||
Task<IEnumerable<PointOfCare>?> FindByBed(string bed);
|
||||
|
||||
/// <summary>
|
||||
@@ -92,6 +104,7 @@ public interface IPointOfCareService
|
||||
/// </summary>
|
||||
/// <param name="unitIds">The list of unit identifiers used to look up the associated points of care.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the list of points of care matching the provided unit identifiers.</returns>
|
||||
/// <!-- aidoc:v1 sig=f8dba62 -->
|
||||
Task<List<PointOfCare>> FindAllByUnitIds(List<ObjectId> unitIds);
|
||||
|
||||
/// <summary>
|
||||
@@ -103,6 +116,7 @@ public interface IPointOfCareService
|
||||
/// <param name="fillPatientData">When <c>true</c>, associated patient data is included in the result; when <c>false</c>, only the point of care information is returned.</param>
|
||||
/// <param name="ct">Token to cancel the asynchronous operation.</param>
|
||||
/// <returns>A task that yields the <see cref="PointOfCare"/> corresponding to the given identifier, or <c>null</c> if it is not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=815317f -->
|
||||
Task<PointOfCare?> GetInfo(ObjectId id, LocaleEnum? locale = null, bool fillPatientData = true, CancellationToken ct = default);
|
||||
|
||||
/// <summary>
|
||||
@@ -110,12 +124,14 @@ public interface IPointOfCareService
|
||||
/// </summary>
|
||||
/// <param name="pointOfCare">The <see cref="PointOfCare"/> entity to be inserted.</param>
|
||||
/// <returns>A <see cref="Task{PointOfCare}"/> containing the inserted <see cref="PointOfCare"/>, or <c>null</c> if the insertion was not performed.</returns>
|
||||
/// <!-- aidoc:v1 sig=de1c6f7 -->
|
||||
Task<PointOfCare?> InsertPointOfCare(PointOfCare pointOfCare);
|
||||
/// <summary>
|
||||
/// Retrieves the Point of Care associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose Point of Care is being looked up.</param>
|
||||
/// <returns>A task that yields the <see cref="PointOfCare"/> associated with the patient, or <c>null</c> if no Point of Care is found for the given patient identifier.</returns>
|
||||
/// <!-- aidoc:v1 sig=c43c4f3 -->
|
||||
Task<PointOfCare?> FindPoCByPatientId(ObjectId patientId);
|
||||
|
||||
/// <summary>
|
||||
@@ -124,6 +140,7 @@ public interface IPointOfCareService
|
||||
/// <param name="id">The unique identifier of the entity whose Point of Care status will be updated.</param>
|
||||
/// <param name="status">The Point of Care status to assign to the entity.</param>
|
||||
/// <returns>A task that represents the asynchronous status update operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=486326c -->
|
||||
Task SetPointOfCareStatus(ObjectId id, StatusEnum.PointOfCare status);
|
||||
|
||||
/// <summary>
|
||||
@@ -133,6 +150,7 @@ public interface IPointOfCareService
|
||||
/// <param name="poc">The point-of-care status used to filter the results.</param>
|
||||
/// <param name="excludeVirtual">When <c>true</c>, virtual points of care are excluded from the results; otherwise, they are included.</param>
|
||||
/// <returns>A task that returns the matching collection of <see cref="PointOfCare"/> entries.</returns>
|
||||
/// <!-- aidoc:v1 sig=078d6e7 -->
|
||||
Task<IEnumerable<PointOfCare>> FindByUnitAndStatus(ObjectId unitId, StatusEnum.PointOfCare poc,
|
||||
bool excludeVirtual = false);
|
||||
|
||||
@@ -140,6 +158,7 @@ public interface IPointOfCareService
|
||||
/// Checks the next admission for the specified patient location.
|
||||
/// </summary>
|
||||
/// <param name="patientLocation">The optional identifier of the patient location to check.</param>
|
||||
/// <!-- aidoc:v1 sig=050dfd4 -->
|
||||
void CheckNextAdmission(ObjectId? patientLocation);
|
||||
/// <summary>
|
||||
/// Retrieves a <see cref="PointOfCare"/> associated with the specified bed and unit identifier, returning <c>null</c> when no matching record is found.
|
||||
@@ -147,11 +166,13 @@ public interface IPointOfCareService
|
||||
/// <param name="bed">The bed identifier used to locate the point of care.</param>
|
||||
/// <param name="unitId">The MongoDB <see cref="ObjectId"/> of the unit the point of care belongs to.</param>
|
||||
/// <returns>A <see cref="Task{T}"/> that resolves to the matching <see cref="PointOfCare"/> or <c>null</c> if no record matches the supplied bed and unit.</returns>
|
||||
/// <!-- aidoc:v1 sig=b2740c6 -->
|
||||
Task<PointOfCare?> FindByBedAndUnitId(string? bed, ObjectId? unitId);
|
||||
/// <summary>
|
||||
/// Updates the relay configuration associated with the specified point-of-care device.
|
||||
/// </summary>
|
||||
/// <param name="poc">The point-of-care device whose relay configuration should be updated.</param>
|
||||
/// <!-- aidoc:v1 sig=a1848f1 -->
|
||||
Task UpdateRelayConfig(PointOfCare poc);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the Point of Care (PoC) associated with the specified patient number.
|
||||
@@ -159,6 +180,7 @@ public interface IPointOfCareService
|
||||
/// </summary>
|
||||
/// <param name="patientNumber">The unique patient number used to look up the associated Point of Care.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the <see cref="PointOfCare"/> if found, or <c>null</c> if no match exists.</returns>
|
||||
/// <!-- aidoc:v1 sig=ea5395f -->
|
||||
Task<PointOfCare?> FindPoCByPatientNumber(string patientNumber);
|
||||
|
||||
/// <summary>
|
||||
@@ -166,43 +188,51 @@ public interface IPointOfCareService
|
||||
/// </summary>
|
||||
/// <param name="unitId">The unique identifier of the unit whose PoCs should be counted.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the total number of PoCs linked to the given unit.</returns>
|
||||
/// <!-- aidoc:v1 sig=41f9c5e -->
|
||||
Task<long> CountPoCsByUnitId(ObjectId unitId);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the total number of virtual Proofs of Concept (PoCs) associated with the specified unit.
|
||||
/// </summary>
|
||||
/// <param name="unitId">The unique identifier of the unit whose virtual PoCs should be counted.</param>
|
||||
/// <returns>A <see cref="Task{Int64}"/> that represents the asynchronous operation, containing the count of virtual PoCs for the given unit.</returns>
|
||||
/// <!-- aidoc:v1 sig=2a40a4f -->
|
||||
Task<long> CountVirtualPoCsByUnitId(ObjectId unitId);
|
||||
/// <summary>
|
||||
/// Retrieves a paginated collection of Points of Care based on the provided filter.
|
||||
/// </summary>
|
||||
/// <param name="filter">The pagination parameters used to control page size and page number.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the paginated response of Points of Care.</returns>
|
||||
/// <!-- aidoc:v1 sig=6ceec7c -->
|
||||
Task<PaginationResponse<PointOfCare>> GetPaginatedPoCs(PaginationFilter filter);
|
||||
/// <summary>
|
||||
/// Deletes all PoCs associated with the specified unit identifier.
|
||||
/// </summary>
|
||||
/// <param name="unitId">The unique identifier of the unit whose PoCs should be removed.</param>
|
||||
/// <!-- aidoc:v1 sig=2c44a9e -->
|
||||
Task DeletePoCsByUnitId(ObjectId unitId);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the set of all camera identifiers that are currently in use.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a HashSet of ObjectId values representing the cameras currently in use.</returns>
|
||||
/// <!-- aidoc:v1 sig=5635e4a -->
|
||||
Task<HashSet<ObjectId>> FindAllIdCamerasInUse();
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the set of all ID relays that are currently in use.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a <see cref="HashSet{ObjectId}"/> of the ID relays currently in use.</returns>
|
||||
/// <!-- aidoc:v1 sig=a6e513b -->
|
||||
Task<HashSet<ObjectId>> FindAllIdRelaysInUse();
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the set of all ID beacons currently in use.
|
||||
/// </summary>
|
||||
/// <returns>A task containing a <see cref="HashSet{ObjectId}"/> of the ID beacons that are active or in use.</returns>
|
||||
/// <!-- aidoc:v1 sig=3084f59 -->
|
||||
Task<HashSet<ObjectId>> FindAllIdBeaconsInUse();
|
||||
/// <summary>
|
||||
/// Retrieves all Point of Care entries associated with the specified unit, including their related devices.
|
||||
/// </summary>
|
||||
/// <param name="unitId">The unique identifier of the unit whose Point of Care entries should be retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a collection of Point of Care entries with their devices, or <c>null</c> if no entries are found for the given unit.</returns>
|
||||
/// <!-- aidoc:v1 sig=dbf2769 -->
|
||||
Task<IEnumerable<PointOfCare>?> FindAllByUnitIdWithDevices(ObjectId unitId);
|
||||
}
|
||||
@@ -7,6 +7,7 @@ public interface IPublisherService
|
||||
/// </summary>
|
||||
/// <param name="queueName">The name of the queue to create.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result is <see langword="true"/> if the queue was created successfully; otherwise, <see langword="false"/>.</returns>
|
||||
/// <!-- aidoc:v1 sig=8ce64d8 -->
|
||||
Task<bool> CreateQueue(string queueName);
|
||||
/// <summary>
|
||||
/// Asynchronously sends an error message to the specified message queue.
|
||||
@@ -14,6 +15,7 @@ public interface IPublisherService
|
||||
/// <param name="obj">The error payload or message object to be sent to the queue.</param>
|
||||
/// <param name="queueName">The name of the target message queue.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a boolean value that indicates whether the message was successfully sent.</returns>
|
||||
/// <!-- aidoc:v1 sig=4c43b3f -->
|
||||
Task<bool> SendMessageError(object obj, string queueName);
|
||||
/// <summary>
|
||||
/// Asynchronously sends the specified object as a message to the named queue.
|
||||
@@ -21,6 +23,7 @@ public interface IPublisherService
|
||||
/// <param name="obj">The object payload to serialize and publish to the queue.</param>
|
||||
/// <param name="queueName">The name of the target queue that will receive the message.</param>
|
||||
/// <returns>A task that resolves to <c>true</c> if the message was sent successfully, otherwise <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=8eb8873 -->
|
||||
Task<bool> SendMessage(object obj, string queueName);
|
||||
/// <summary>
|
||||
/// Asynchronously sends a message to the specified message queue and returns a value indicating whether the operation succeeded.
|
||||
@@ -28,5 +31,6 @@ public interface IPublisherService
|
||||
/// <param name="message">The message content to be sent to the queue.</param>
|
||||
/// <param name="queueName">The name of the target queue where the message will be delivered.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result is <c>true</c> if the message was sent successfully; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=e20a929 -->
|
||||
Task<bool> SendMessage(string message, string queueName);
|
||||
}
|
||||
@@ -14,6 +14,7 @@ public interface IPumpService: IApiRequestService
|
||||
/// Asynchronously inserts a pump observation record into the underlying data store.
|
||||
/// </summary>
|
||||
/// <param name="obs">The pump observation to persist.</param>
|
||||
/// <!-- aidoc:v1 sig=dc84e4b -->
|
||||
Task InsertPumpObservation(PumpObservation obs);
|
||||
|
||||
// Mapping
|
||||
@@ -22,6 +23,7 @@ public interface IPumpService: IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="obs">The source pump observation to be mapped.</param>
|
||||
/// <returns>A task that represents the asynchronous mapping operation, containing the resulting <see cref="PumpObservation"/> or <c>null</c> if no result is available.</returns>
|
||||
/// <!-- aidoc:v1 sig=825d828 -->
|
||||
Task<PumpObservation?> MapPumpObservation(PumpObservation obs);
|
||||
|
||||
// Consultas por paciente
|
||||
@@ -31,11 +33,13 @@ public interface IPumpService: IApiRequestService
|
||||
/// <param name="patientId">The unique identifier of the patient whose pump observations are being queried.</param>
|
||||
/// <param name="num">The maximum number of recent observations to return. Defaults to 1.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of the most recent pump observations for the patient, up to the specified count.</returns>
|
||||
/// <!-- aidoc:v1 sig=c6e10b9 -->
|
||||
Task<List<PumpObservation>> FindLastPumpObservations(ObjectId patientId, int num = 1);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the most recent observation timestamp for every patient, returning a dictionary keyed by patient identifier.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a dictionary mapping each patient's <see cref="ObjectId"/> to their last observation <see cref="DateTime"/>.</returns>
|
||||
/// <!-- aidoc:v1 sig=cbcaa4c -->
|
||||
Task<Dictionary<ObjectId, DateTime>> FindAllLastPatientObservationTime();
|
||||
|
||||
// Gestión de configuración
|
||||
@@ -44,35 +48,41 @@ public interface IPumpService: IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier used to look up the configuration pump items.</param>
|
||||
/// <returns>A task that resolves to a list of <see cref="ConfigPumpItem"/> objects matching the given identifier, or <c>null</c> when no items are found.</returns>
|
||||
/// <!-- aidoc:v1 sig=0480417 -->
|
||||
Task<List<ConfigPumpItem>?> GetItemsById(string id);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the full list of pump configurations from the underlying data source.
|
||||
/// </summary>
|
||||
/// <returns>A task that resolves to a <see cref="List{ConfigPumps}"/> containing all pump configurations, or <c>null</c> if no configurations are available.</returns>
|
||||
/// <!-- aidoc:v1 sig=b9aae05 -->
|
||||
Task<List<ConfigPumps>?> GetAllPumpConfig();
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the pump configuration associated with the specified identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the pump configuration to retrieve.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the <see cref="ConfigPumps"/> instance matching the specified identifier, or <see langword="null"/> if no configuration is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=3958f50 -->
|
||||
Task<ConfigPumps?> GetPumpConfigsById(string id);
|
||||
/// <summary>
|
||||
/// Asynchronously updates the pump configuration.
|
||||
/// </summary>
|
||||
/// <param name="config">The pump configuration to update.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the updated <see cref="ConfigPumps"/> or null if not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=563e48a -->
|
||||
Task<ConfigPumps?> UpdatePumpConfig(ConfigPumps config);
|
||||
/// <summary>
|
||||
/// Inserts a new pump configuration into the system asynchronously.
|
||||
/// </summary>
|
||||
/// <param name="config">The pump configuration to be inserted.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the inserted <see cref="ConfigPumps"/> or <c>null</c> if the insertion fails.</returns>
|
||||
/// <!-- aidoc:v1 sig=7fd9494 -->
|
||||
Task<ConfigPumps?> InsertPumpConfig(ConfigPumps config);
|
||||
/// <summary>
|
||||
/// Deletes the specified pump configuration.
|
||||
/// </summary>
|
||||
/// <param name="config">The pump configuration to delete.</param>
|
||||
/// <returns>A task that represents the asynchronous delete operation. The task result is <c>true</c> if the configuration was deleted successfully; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=ce3f871 -->
|
||||
Task<bool> DeletePumpConfig(ConfigPumps config);
|
||||
|
||||
// Paginación
|
||||
@@ -82,6 +92,7 @@ public interface IPumpService: IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="filter">The pagination filter that defines page size, page number, and any additional filtering criteria applied to the pump observations.</param>
|
||||
/// <returns>A task that resolves to a <see cref="PaginationResponse{PumpObservation}"/> containing the matching pump observations, or null when no results are found.</returns>
|
||||
/// <!-- aidoc:v1 sig=f72dd47 -->
|
||||
Task<PaginationResponse<PumpObservation>?> GetPaginatedPump(PaginationFilter filter);
|
||||
|
||||
// Archivado / limpieza
|
||||
@@ -89,17 +100,20 @@ public interface IPumpService: IApiRequestService
|
||||
/// Asynchronously deletes records associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The ObjectId of the patient whose related records should be deleted.</param>
|
||||
/// <!-- aidoc:v1 sig=d457cb9 -->
|
||||
Task DeleteByPatientId(ObjectId id);
|
||||
/// <summary>
|
||||
/// Archives the specified patient, marking the patient record as archived in the system.
|
||||
/// </summary>
|
||||
/// <param name="patient">The patient to be archived.</param>
|
||||
/// <!-- aidoc:v1 sig=52c2373 -->
|
||||
Task Archive(Patient patient);
|
||||
/// <summary>
|
||||
/// Asynchronously archives the data associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the patient whose data should be archived.</param>
|
||||
/// <returns>A task that represents the asynchronous archive operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=e5916ec -->
|
||||
Task ArchiveByPatientId(ObjectId id);
|
||||
|
||||
// Mantenimiento ids
|
||||
@@ -109,5 +123,6 @@ public interface IPumpService: IApiRequestService
|
||||
/// <param name="nameId">The name of the field whose ObjectId value should be updated.</param>
|
||||
/// <param name="id">The new ObjectId value to assign.</param>
|
||||
/// <param name="oldId">The existing ObjectId value to be replaced.</param>
|
||||
/// <!-- aidoc:v1 sig=24ef97c -->
|
||||
Task UpdateManyObjectId(string nameId, ObjectId id, ObjectId oldId);
|
||||
}
|
||||
@@ -12,21 +12,25 @@ public interface IRecordingAlertService : IApiRequestService
|
||||
/// <param name="patientId">The identifier of the patient whose recording alerts are being queried.</param>
|
||||
/// <param name="num">The maximum number of most recent recording alerts to return. Defaults to 2.</param>
|
||||
/// <returns>A task representing the asynchronous operation, containing a list of the patient's most recent recording alerts.</returns>
|
||||
/// <!-- aidoc:v1 sig=452ab2a -->
|
||||
Task<List<PatientRecordingAlert>> FindLastRecordingAlert(ObjectId patientId, int num = 2);
|
||||
/// <summary>
|
||||
/// Deletes records associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the patient whose related records should be removed.</param>
|
||||
/// <!-- aidoc:v1 sig=d457cb9 -->
|
||||
Task DeleteByPatientId(ObjectId id);
|
||||
/// <summary>
|
||||
/// Asynchronously archives the specified patient, moving their record out of the active set.
|
||||
/// </summary>
|
||||
/// <param name="patient">The patient to archive.</param>
|
||||
/// <!-- aidoc:v1 sig=52c2373 -->
|
||||
Task Archive(Patient patient);
|
||||
/// <summary>
|
||||
/// Archives the records associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The <see cref="ObjectId"/> identifying the patient whose related records should be archived.</param>
|
||||
/// <!-- aidoc:v1 sig=e5916ec -->
|
||||
Task ArchiveByPatientId(ObjectId id);
|
||||
|
||||
/// <summary>
|
||||
@@ -36,5 +40,6 @@ public interface IRecordingAlertService : IApiRequestService
|
||||
/// <param name="nameId">The identifier used to select the target records to update.</param>
|
||||
/// <param name="id">The new ObjectId value to assign to the matching records.</param>
|
||||
/// <param name="oldId">The existing ObjectId value to be replaced in the matching records.</param>
|
||||
/// <!-- aidoc:v1 sig=24ef97c -->
|
||||
Task UpdateManyObjectId(string nameId, ObjectId id, ObjectId oldId);
|
||||
}
|
||||
@@ -15,6 +15,7 @@ public interface IRecordingService : IApiRequestService
|
||||
/// <param name="patient">The patient whose recording should be cancelled.</param>
|
||||
/// <param name="poc">The point of care associated with the recording to be cancelled.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a boolean value indicating the outcome of the cancel recording request.</returns>
|
||||
/// <!-- aidoc:v1 sig=3c3bc68 -->
|
||||
Task<bool> SendCancelRecordingToRecordingApi(Patient patient, PointOfCare poc);
|
||||
|
||||
/// <summary>
|
||||
@@ -31,6 +32,7 @@ public interface IRecordingService : IApiRequestService
|
||||
/// <param name="alarmDescription">The description of the alarm, if applicable.</param>
|
||||
/// <param name="start">Indicates whether to start the recording (default is true).</param>
|
||||
/// <param name="type">The type of alarm (default is Manual).</param>
|
||||
/// <!-- aidoc:v1 sig=aa9d33d -->
|
||||
Task SendRecordingDataToQueue(Patient patient, PointOfCare poc, DateTime? date, DateTime? endDate,
|
||||
DateTime? eventDate, AlarmEnum.Name? alarmName, AlarmEnum.Severity severity, string? alarmDescription,
|
||||
bool start = true, AlarmEnum.Type type = AlarmEnum.Type.Manual);
|
||||
@@ -42,6 +44,7 @@ public interface IRecordingService : IApiRequestService
|
||||
/// <param name="poc">The point of care associated with the recording.</param>
|
||||
/// <param name="manualRecording">The manual recording payload to transmit.</param>
|
||||
/// <param name="start">A flag indicating whether the recording is being started or stopped.</param>
|
||||
/// <!-- aidoc:v1 sig=102dc90 -->
|
||||
Task SendRecordingData(Patient patient, PointOfCare poc, ManualRecording manualRecording, bool start);
|
||||
|
||||
/// <summary>
|
||||
@@ -51,6 +54,7 @@ public interface IRecordingService : IApiRequestService
|
||||
/// <param name="poc">The point of care where the recording was taken.</param>
|
||||
/// <param name="automaticRecording">The automatic recording data to be sent.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a boolean indicating whether the data was sent successfully.</returns>
|
||||
/// <!-- aidoc:v1 sig=0e48f1a -->
|
||||
Task<bool> SendAutoRecordingData(Patient patient, PointOfCare poc, RecordingData automaticRecording);
|
||||
|
||||
/// <summary>
|
||||
@@ -58,5 +62,6 @@ public interface IRecordingService : IApiRequestService
|
||||
/// </summary>
|
||||
/// <param name="roomName">The identifier of the room whose recordings are being requested.</param>
|
||||
/// <returns>A task that returns a list of <see cref="RecordingData"/> for the room, or <c>null</c> if no recordings are available.</returns>
|
||||
/// <!-- aidoc:v1 sig=e92f1dd -->
|
||||
Task<List<RecordingData>?> GetRecordings(int roomName);
|
||||
}
|
||||
@@ -13,23 +13,27 @@ public interface IRelayService
|
||||
/// </summary>
|
||||
/// <param name="relay">The relay whose status is being checked.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the current <see cref="RelayEnum.Status"/> of the relay.</returns>
|
||||
/// <!-- aidoc:v1 sig=2b11d08 -->
|
||||
Task<RelayEnum.Status> CheckRelayStatus(Relay relay);
|
||||
/// <summary>
|
||||
/// Asynchronously checks the current status of the relay identified by the specified identifier.
|
||||
/// </summary>
|
||||
/// <param name="relayId">The unique identifier of the relay whose status is being queried.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the <see cref="RelayEnum.Status"/> of the requested relay.</returns>
|
||||
/// <!-- aidoc:v1 sig=8240e77 -->
|
||||
Task<RelayEnum.Status> CheckRelayStatus(ObjectId relayId);
|
||||
|
||||
/// <summary>
|
||||
/// Powers on the specified relay.
|
||||
/// </summary>
|
||||
/// <param name="relay">The relay to power on.</param>
|
||||
/// <!-- aidoc:v1 sig=a6937ad -->
|
||||
Task PowerOn(Relay relay);
|
||||
/// <summary>
|
||||
/// Powers off the specified relay by sending a command to deactivate it.
|
||||
/// </summary>
|
||||
/// <param name="relay">The relay to power off.</param>
|
||||
/// <!-- aidoc:v1 sig=5540326 -->
|
||||
Task PowerOff(Relay relay);
|
||||
/// <summary>
|
||||
/// Sets a manual relay with the specified status for the given point of contact and relay type.
|
||||
@@ -37,18 +41,21 @@ public interface IRelayService
|
||||
/// <param name="status">The status to apply to the manual relay.</param>
|
||||
/// <param name="pocId">The identifier of the point of contact associated with the relay.</param>
|
||||
/// <param name="type">The type of relay to set manually.</param>
|
||||
/// <!-- aidoc:v1 sig=a56b641 -->
|
||||
Task SetManualRelay(RelayEnum.Status status, ObjectId pocId, RelayEnum.Type type);
|
||||
/// <summary>
|
||||
/// Retrieves a relay by its unique identifier, returning <c>null</c> if no matching relay is found.
|
||||
/// </summary>
|
||||
/// <param name="relay">The unique identifier of the relay to look up.</param>
|
||||
/// <returns>A <see cref="Task{TResult}"/> that resolves to the <see cref="Relay"/> if found, or <c>null</c> if no relay matches the provided identifier.</returns>
|
||||
/// <!-- aidoc:v1 sig=89a52df -->
|
||||
Task<Relay?> GetById(ObjectId relay);
|
||||
/// <summary>
|
||||
/// Retrieves the list of <see cref="Relay"/> objects corresponding to the specified collection of relay identifiers.
|
||||
/// </summary>
|
||||
/// <param name="relayList">The list of <see cref="ObjectId"/> values identifying the relays to retrieve. May be <c>null</c>.</param>
|
||||
/// <returns>A <see cref="List{Relay}"/> containing the relays found for the provided identifiers.</returns>
|
||||
/// <!-- aidoc:v1 sig=cab20f9 -->
|
||||
List<Relay> GetRelayInList(List<ObjectId>? relayList);
|
||||
/// <summary>
|
||||
/// Retrieves the relays of a specified type from the provided configuration relay list.
|
||||
@@ -56,6 +63,7 @@ public interface IRelayService
|
||||
/// <param name="configurationRelayList">The list of relay ObjectIds to filter, or null if no configuration relays are available.</param>
|
||||
/// <param name="type">The relay type to match against the configuration relays.</param>
|
||||
/// <returns>A list of <see cref="Relay"/> objects that match the specified <paramref name="type"/>.</returns>
|
||||
/// <!-- aidoc:v1 sig=ac9918d -->
|
||||
List<Relay> GetRelayByTypeInList(List<ObjectId>? configurationRelayList, RelayEnum.Type type);
|
||||
|
||||
/// <summary>
|
||||
@@ -63,12 +71,14 @@ public interface IRelayService
|
||||
/// </summary>
|
||||
/// <param name="request">The pagination filter containing the criteria used to retrieve the relays.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the paginated response with the requested relays.</returns>
|
||||
/// <!-- aidoc:v1 sig=171773b -->
|
||||
Task<PaginationResponse<Relay>> GetPaginatedRelays(PaginationFilter request);
|
||||
/// <summary>
|
||||
/// Inserts a new relay record based on the provided request data.
|
||||
/// </summary>
|
||||
/// <param name="request">The relay entity to be inserted.</param>
|
||||
/// <returns>A task that resolves to the inserted <see cref="Relay"/>, or <c>null</c> if the insert did not return a value.</returns>
|
||||
/// <!-- aidoc:v1 sig=8e83e60 -->
|
||||
Task<Relay?> InsertRelay(Relay request);
|
||||
/// <summary>
|
||||
/// Updates an existing relay identified by the specified <paramref name="objectId"/> with the provided <paramref name="relay"/> data.
|
||||
@@ -77,5 +87,6 @@ public interface IRelayService
|
||||
/// <param name="objectId">The unique identifier of the relay to update.</param>
|
||||
/// <param name="relay">The relay data containing the updated values.</param>
|
||||
/// <returns>A task that resolves to the updated <see cref="Relay"/>, or <c>null</c> if the relay was not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=cbb172b -->
|
||||
Task<Relay?> UpdateRelayById(ObjectId objectId, Relay relay);
|
||||
}
|
||||
@@ -8,15 +8,18 @@ public interface ISendAlertService
|
||||
/// Asynchronously retrieves a list of available queues.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the list of <see cref="Queue"/> instances.</returns>
|
||||
/// <!-- aidoc:v1 sig=f99b362 -->
|
||||
Task<List<Queue>> GetQueues();
|
||||
/// <summary>
|
||||
/// Retrieves a list of performance records.
|
||||
/// </summary>
|
||||
/// <returns>A list of <see cref="Performance"/> objects.</returns>
|
||||
/// <!-- aidoc:v1 sig=3205076 -->
|
||||
List<Performance> GetPerformance();
|
||||
/// <summary>
|
||||
/// Retrieves a list of API clients.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of <see cref="ApiClients"/>.</returns>
|
||||
/// <!-- aidoc:v1 sig=5b1f979 -->
|
||||
Task<List<ApiClients>> GetApiClients();
|
||||
}
|
||||
@@ -9,5 +9,6 @@ public interface IServiceConfigService
|
||||
/// </summary>
|
||||
/// <param name="id">The identifier of the service configuration to retrieve.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the matching <see cref="ServiceConfig"/> if found, or <c>null</c> if no configuration exists for the given identifier.</returns>
|
||||
/// <!-- aidoc:v1 sig=86fa8c8 -->
|
||||
Task<ServiceConfig?> Get(string id);
|
||||
}
|
||||
@@ -11,34 +11,40 @@ public interface ISubscriberGroupedService
|
||||
/// Retrieves a list of subscribers organized into groups.
|
||||
/// </summary>
|
||||
/// <returns>A list of <see cref="WsSubscriberGrouped"/> instances representing the grouped subscribers.</returns>
|
||||
/// <!-- aidoc:v1 sig=f5051ca -->
|
||||
List<WsSubscriberGrouped> GetGrouped();
|
||||
/// <summary>
|
||||
/// Removes grouped observations associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose grouped observations should be removed.</param>
|
||||
/// <!-- aidoc:v1 sig=f293e05 -->
|
||||
void RemoveGroupedObsByPatientId(string patientId);
|
||||
/// <summary>
|
||||
/// Removes a WebSocket subscriber associated with the specified patient based on the provided location.
|
||||
/// </summary>
|
||||
/// <param name="patientId">The identifier of the patient whose WebSocket subscriber should be removed.</param>
|
||||
/// <param name="newLocation">The new patient location used to identify the subscriber to remove, or null to remove without location filtering.</param>
|
||||
/// <!-- aidoc:v1 sig=a9f97d5 -->
|
||||
void RemoveWsSubscriberByLocation(string patientId, PatientLocation? newLocation);
|
||||
/// <summary>
|
||||
/// Removes the specified workstation identifier associated with a patient's WS subscriber entry.
|
||||
/// </summary>
|
||||
/// <param name="patientId">The identifier of the patient whose WS subscriber entry will be updated.</param>
|
||||
/// <param name="wsIdToRemove">The workstation identifier to remove from the patient's WS subscriber entry.</param>
|
||||
/// <!-- aidoc:v1 sig=4add1da -->
|
||||
void RemoveWsSubscriberPatientIdAndWsId(string patientId, string wsIdToRemove);
|
||||
/// <summary>
|
||||
/// Validates the provided <see cref="WsSubscriberGrouped"/> instance to identify empty subscriber groups.
|
||||
/// </summary>
|
||||
/// <param name="wsl">The subscriber group instance to be checked for empty groups.</param>
|
||||
/// <returns>A <see cref="List{String}"/> containing validation messages for any empty subscriber groups found; returns an empty list if all groups are valid.</returns>
|
||||
/// <!-- aidoc:v1 sig=d6864a4 -->
|
||||
List<string> CheckEmptySubscriberGroup(WsSubscriberGrouped wsl);
|
||||
/// <summary>
|
||||
/// Adds a new subscriber together with its associated group information to the system.
|
||||
/// </summary>
|
||||
/// <param name="wsSubscriberGrouped">The web service representation of the subscriber and its group assignments to be added.</param>
|
||||
/// <!-- aidoc:v1 sig=fdb64fe -->
|
||||
void AddSubscriberGrouped(WsSubscriberGrouped wsSubscriberGrouped);
|
||||
|
||||
/// <summary>
|
||||
@@ -49,6 +55,7 @@ public interface ISubscriberGroupedService
|
||||
/// <param name="timeZoneId">The time zone identifier used for the observation context.</param>
|
||||
/// <param name="connectionId">The connection identifier for the current request or session.</param>
|
||||
/// <param name="go">The grouped observation to be checked against the subscription.</param>
|
||||
/// <!-- aidoc:v1 sig=adb6856 -->
|
||||
void CheckOnSubscriptionGroup(GroupedField groupedField, ObjectId patientId, string timeZoneId, string connectionId,
|
||||
GroupedObservation go);
|
||||
|
||||
@@ -57,5 +64,6 @@ public interface ISubscriberGroupedService
|
||||
/// </summary>
|
||||
/// <param name="wsgHashCode">The hash code identifying the group whose last grouped observation should be updated.</param>
|
||||
/// <param name="newGroupedObservation">The new grouped observation to set as the last grouped observation in the group.</param>
|
||||
/// <!-- aidoc:v1 sig=3b3409a -->
|
||||
void UpdateLastGroupedObsInGroup(string wsgHashCode, GroupedObservation newGroupedObservation);
|
||||
}
|
||||
@@ -9,28 +9,33 @@ public interface ISubscribersService
|
||||
/// Retrieves the list of subscribers.
|
||||
/// </summary>
|
||||
/// <returns>A list of <see cref="WsSubscriber"/> instances representing the subscribers.</returns>
|
||||
/// <!-- aidoc:v1 sig=7e137ae -->
|
||||
List<WsSubscriber> GetSubscribers();
|
||||
/// <summary>
|
||||
/// Retrieves a <see cref="WsSubscriber"/> associated with the specified context connection identifier.
|
||||
/// </summary>
|
||||
/// <param name="contextConnectionId">The unique identifier of the context connection used to look up the subscriber.</param>
|
||||
/// <returns>The <see cref="WsSubscriber"/> matching the given connection identifier, or <c>null</c> if no subscriber is found.</returns>
|
||||
/// <!-- aidoc:v1 sig=b24d002 -->
|
||||
WsSubscriber? GetById(string contextConnectionId);
|
||||
/// <summary>
|
||||
/// Retrieves the list of subscribers associated with the specified point of contact (POC) identifier.
|
||||
/// </summary>
|
||||
/// <param name="pocId">The identifier of the point of contact whose subscribers should be returned.</param>
|
||||
/// <returns>A list of <see cref="WsSubscriber"/> instances matching the provided POC identifier.</returns>
|
||||
/// <!-- aidoc:v1 sig=aec8331 -->
|
||||
List<WsSubscriber> GetByPocId(ObjectId pocId);
|
||||
/// <summary>
|
||||
/// Removes a connection identified by the specified context connection identifier.
|
||||
/// </summary>
|
||||
/// <param name="contextConnectionId">The unique identifier of the connection to remove.</param>
|
||||
/// <returns>An integer indicating the result of the removal operation.</returns>
|
||||
/// <!-- aidoc:v1 sig=26b732e -->
|
||||
int RemoveConnectionById(string contextConnectionId);
|
||||
/// <summary>
|
||||
/// Registers the specified WebSocket subscriber to receive notifications or messages.
|
||||
/// </summary>
|
||||
/// <param name="subscriber">The <see cref="WsSubscriber"/> instance to be added to the collection of subscribers.</param>
|
||||
/// <!-- aidoc:v1 sig=695cf06 -->
|
||||
void AddSubscriber(WsSubscriber subscriber);
|
||||
}
|
||||
@@ -13,33 +13,39 @@ public interface ITreatmentService : IApiRequestService
|
||||
/// Inserts a new <see cref="PatientTreatment"/> record into the underlying data store.
|
||||
/// </summary>
|
||||
/// <param name="treatment">The patient treatment entity to be added.</param>
|
||||
/// <!-- aidoc:v1 sig=64e0091 -->
|
||||
Task Insert(PatientTreatment treatment);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes an entity associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The <see cref="ObjectId"/> representing the unique identifier of the patient whose related entity should be removed.</param>
|
||||
/// <returns>A <see cref="Task{TResult}"/> containing <c>true</c> if the deletion was successful; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=fa9d1b9 -->
|
||||
Task<bool> DeleteByPatientId(ObjectId id);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes the entity identified by the specified identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the entity to delete.</param>
|
||||
/// <!-- aidoc:v1 sig=9d4aeba -->
|
||||
Task DeleteById(ObjectId id);
|
||||
/// <summary>
|
||||
/// Archives records associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The ObjectId of the patient whose records should be archived.</param>
|
||||
/// <!-- aidoc:v1 sig=e5916ec -->
|
||||
Task ArchiveByPatientId(ObjectId id);
|
||||
/// <summary>
|
||||
/// Archives the specified patient, marking them as archived in the system.
|
||||
/// </summary>
|
||||
/// <param name="patient">The patient to archive.</param>
|
||||
/// <!-- aidoc:v1 sig=52c2373 -->
|
||||
Task Archive(Patient patient);
|
||||
/// <summary>
|
||||
/// Updates an existing patient treatment record in the system.
|
||||
/// </summary>
|
||||
/// <param name="patientTreatment">The patient treatment entity containing the updated information to be persisted.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains <c>true</c> if the treatment was updated successfully; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=fa7946f -->
|
||||
Task<bool> UpdateTreatment(PatientTreatment patientTreatment);
|
||||
/// <summary>
|
||||
/// Updates many records by replacing the specified old ObjectId with the new ObjectId in the field identified by nameId.
|
||||
@@ -47,42 +53,49 @@ public interface ITreatmentService : IApiRequestService
|
||||
/// <param name="nameId">The name of the field that contains the ObjectId to be updated.</param>
|
||||
/// <param name="id">The new ObjectId value that will replace the existing one.</param>
|
||||
/// <param name="oldId">The existing ObjectId value to be replaced.</param>
|
||||
/// <!-- aidoc:v1 sig=24ef97c -->
|
||||
Task UpdateManyObjectId(string nameId, ObjectId id, ObjectId oldId);
|
||||
/// <summary>
|
||||
/// Retrieves all treatments associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the patient whose treatments are to be retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a collection of PatientTreatment objects for the specified patient.</returns>
|
||||
/// <!-- aidoc:v1 sig=464e56c -->
|
||||
Task<IEnumerable<PatientTreatment>> GetTreatmentsByPatientId(ObjectId id);
|
||||
/// <summary>
|
||||
/// Retrieves the active treatment records associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the patient whose active treatments should be retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing an enumerable collection of active <see cref="PatientTreatment"/> records, which may include null entries.</returns>
|
||||
/// <!-- aidoc:v1 sig=9eb0d98 -->
|
||||
Task<IEnumerable<PatientTreatment?>> GetActiveTreatmentsByPatient(ObjectId id);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a cursor over the <see cref="PatientTreatment"/> records associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose treatments should be returned.</param>
|
||||
/// <returns>A <see cref="Task{TResult}"/> yielding an <see cref="IAsyncCursor{TDocument}"/> that iterates the matching <see cref="PatientTreatment"/> documents.</returns>
|
||||
/// <!-- aidoc:v1 sig=1be8597 -->
|
||||
Task<IAsyncCursor<PatientTreatment>> FindByPatientIdAsync(ObjectId patientId);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves all patient treatments associated with the specified patient identifier.
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose treatments are being queried.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a collection of <see cref="PatientTreatment"/> instances for the specified patient.</returns>
|
||||
/// <!-- aidoc:v1 sig=8e33f27 -->
|
||||
Task<IEnumerable<PatientTreatment>> FindByPatientId(ObjectId patientId);
|
||||
/// <summary>
|
||||
/// Retrieves the list of bolus treatments associated with the specified patient.
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose bolus treatments are being retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of <see cref="PatientTreatment"/> records representing the patient's bolus treatments.</returns>
|
||||
/// <!-- aidoc:v1 sig=e8ec7d6 -->
|
||||
Task<List<PatientTreatment>> GetBolusTreatments(ObjectId patientId);
|
||||
/// <summary>
|
||||
/// Retrieves a paginated list of patient treatments based on the specified filter criteria.
|
||||
/// </summary>
|
||||
/// <param name="filter">The pagination filter used to control the page number, page size, and other query options.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the paginated patient treatment results.</returns>
|
||||
/// <!-- aidoc:v1 sig=b165424 -->
|
||||
Task<PaginationResponse<PatientTreatment>> GetPaginatedTreatments(PaginationFilter filter);
|
||||
/// <summary>
|
||||
/// Retrieves the list of active treatments associated with the specified patient, sorted according to the provided order parameter.
|
||||
@@ -90,5 +103,6 @@ public interface ITreatmentService : IApiRequestService
|
||||
/// <param name="patientId">The unique identifier of the patient whose active treatments are being queried.</param>
|
||||
/// <param name="order">A string defining the ordering criteria applied to the returned treatments.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing a list of active <see cref="PatientTreatment"/> entries for the patient.</returns>
|
||||
/// <!-- aidoc:v1 sig=d9fb0b1 -->
|
||||
Task<List<PatientTreatment>> GetActiveTreatmentsByPatientIdAndOrder(ObjectId patientId, string order);
|
||||
}
|
||||
@@ -15,11 +15,13 @@ public interface IUnitService
|
||||
/// </summary>
|
||||
/// <param name="withPocs">Indicates whether the returned units should include their associated POCs.</param>
|
||||
/// <returns>A task representing the asynchronous operation, containing the list of units.</returns>
|
||||
/// <!-- aidoc:v1 sig=d5d641e -->
|
||||
Task<List<Unit>> GetAll(bool withPocs = false);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a compact list of all units, returning minimal summary information for each unit.
|
||||
/// </summary>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains a list of <see cref="UnitInfoDto"/> objects with the compact information of all units.</returns>
|
||||
/// <!-- aidoc:v1 sig=85c8e61 -->
|
||||
Task<List<UnitInfoDto>> GetAllCompact();
|
||||
|
||||
/// <summary>
|
||||
@@ -27,6 +29,7 @@ public interface IUnitService
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the unit to retrieve.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the compact unit information.</returns>
|
||||
/// <!-- aidoc:v1 sig=ea6d80a -->
|
||||
Task<UnitInfoDto> GetOneCompact(ObjectId id);
|
||||
|
||||
// Task<Unit?> GetByCodeSysAndCode(string unit);
|
||||
@@ -35,6 +38,7 @@ public interface IUnitService
|
||||
/// </summary>
|
||||
/// <param name="unit">The name of the unit to look up.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the matching <see cref="Unit"/> if found; otherwise, <c>null</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=d855f4f -->
|
||||
Task<Unit?> GetByName(string unit);
|
||||
|
||||
// Task<Unit?> GetByPointOfCare(PointOfCare pointOfCare);
|
||||
@@ -46,6 +50,7 @@ public interface IUnitService
|
||||
/// <param name="fillLists">When <see langword="true"/>, populates the related lists on the returned unit.</param>
|
||||
/// <param name="withPoCs">When <see langword="true"/>, includes the unit's points of contact in the result.</param>
|
||||
/// <returns>A task that yields the located <see cref="Unit"/>, or <see langword="null"/> if no unit matches the given id.</returns>
|
||||
/// <!-- aidoc:v1 sig=59363d0 -->
|
||||
Task<Unit?> GetInfo(ObjectId id, LocaleEnum? dataLocale, bool fillLists = true, bool withPoCs = false);
|
||||
/// <summary>
|
||||
/// Retrieves information about a unit identified by the specified <paramref name="id"/>, optionally including related points of contact and devices.
|
||||
@@ -54,6 +59,7 @@ public interface IUnitService
|
||||
/// <param name="withPoCs">Indicates whether related points of contact should be included in the result. Defaults to <c>true</c>.</param>
|
||||
/// <param name="withDevices">Indicates whether related devices should be included in the result. Defaults to <c>true</c>.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the <c>Unit</c> if found, or <c>null</c> if no unit matches the specified identifier.</returns>
|
||||
/// <!-- aidoc:v1 sig=83c1253 -->
|
||||
Task<Unit?> GetInfo(ObjectId id, bool withPoCs = true, bool withDevices = true);
|
||||
|
||||
/// <summary>
|
||||
@@ -61,6 +67,7 @@ public interface IUnitService
|
||||
/// </summary>
|
||||
/// <param name="patientId">The unique identifier of the patient whose unit is being looked up.</param>
|
||||
/// <returns>A task that represents the asynchronous lookup, containing the matching <see cref="Unit"/> if found, or <c>null</c> if no unit is associated with the patient.</returns>
|
||||
/// <!-- aidoc:v1 sig=2a55026 -->
|
||||
Task<Unit?> FindByPatientId(ObjectId patientId);
|
||||
|
||||
// Task<List<Unit>?> FindByLocation(PatientLocation location);
|
||||
@@ -69,12 +76,14 @@ public interface IUnitService
|
||||
/// </summary>
|
||||
/// <param name="id">The unique identifier of the <see cref="Unit"/> to retrieve. May be <c>null</c>.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the <see cref="Unit"/> if found; otherwise, <c>null</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=31e43d9 -->
|
||||
Task<Unit?> FindById(ObjectId? id);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves a <see cref="Unit"/> entity matching the specified name.
|
||||
/// </summary>
|
||||
/// <param name="name">The name used to look up the unit. Can be null.</param>
|
||||
/// <returns>A task that resolves to the matching <see cref="Unit"/> if found; otherwise, null.</returns>
|
||||
/// <!-- aidoc:v1 sig=1e5dd65 -->
|
||||
Task<Unit?> FindByName(string? name);
|
||||
|
||||
/// <summary>
|
||||
@@ -84,6 +93,8 @@ public interface IUnitService
|
||||
/// <param name="name">The unit name to search for. May be <c>null</c>.</param>
|
||||
/// <param name="pocName">The point-of-contact (POC) name to search for. May be <c>null</c>.</param>
|
||||
/// <returns>A <see cref="Task{Unit}"/> containing the matched <see cref="Unit"/>, or <c>null</c> if no unit is found.</returns>
|
||||
/// <!-- aidoc-review:v1 severity=low kind=wrong_returns
|
||||
/// "<see cref=\"Task{Unit}\"/> should be <see cref=\"Task{Unit?}\"/> to reflect the nullable Unit return type; text correctly describes null result." -->
|
||||
Task<Unit?> FindByUnitNameOrPocName(string? name, string? pocName);
|
||||
|
||||
//Task<Unit?> FindByPointOfCare(PointOfCare pointOfCare);
|
||||
@@ -92,12 +103,14 @@ public interface IUnitService
|
||||
/// </summary>
|
||||
/// <param name="unit">The <see cref="Unit"/> instance to be inserted.</param>
|
||||
/// <returns>A task that resolves to the inserted <see cref="Unit"/>, or <c>null</c> if the insertion did not produce a result.</returns>
|
||||
/// <!-- aidoc:v1 sig=dcc73fd -->
|
||||
Task<Unit?> InsertOne(Unit unit);
|
||||
/// <summary>
|
||||
/// Updates the specified unit in the system.
|
||||
/// </summary>
|
||||
/// <param name="unit">The unit containing the updated information to persist.</param>
|
||||
/// <returns>A task that returns the updated <see cref="Unit"/>, or <c>null</c> if the unit was not found.</returns>
|
||||
/// <!-- aidoc:v1 sig=fb3e248 -->
|
||||
Task<Unit?> UpdateUnit(Unit unit);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the collection of units associated with the specified master list identifier and master list type.
|
||||
@@ -106,6 +119,7 @@ public interface IUnitService
|
||||
/// <param name="masterListId">The unique identifier of the master list whose units should be retrieved.</param>
|
||||
/// <param name="masterListType">The type of the master list used to scope the unit lookup.</param>
|
||||
/// <returns>A task that returns an <see cref="IEnumerable{T}"/> of <see cref="Unit"/> when matches exist, or null when no matching units are found.</returns>
|
||||
/// <!-- aidoc:v1 sig=af11dcc -->
|
||||
Task<IEnumerable<Unit>?> FindUnitsByMasterListId(ObjectId masterListId, MasterListType masterListType);
|
||||
/// <summary>
|
||||
/// Asynchronously counts the number of units associated with the specified master list, filtered by the given master list type.
|
||||
@@ -113,18 +127,21 @@ public interface IUnitService
|
||||
/// <param name="masterListId">The unique identifier of the master list whose units should be counted.</param>
|
||||
/// <param name="masterListType">The type of the master list used to scope the count to the appropriate unit category.</param>
|
||||
/// <returns>A <see cref="Task{Int64}"/> that represents the asynchronous operation, containing the total number of units matching the specified master list.</returns>
|
||||
/// <!-- aidoc:v1 sig=64362ca -->
|
||||
Task<long> CountUnitsByMasterListId(ObjectId masterListId, MasterListType masterListType);
|
||||
/// <summary>
|
||||
/// Asynchronously retrieves the collection of units associated with the specified master list identifier.
|
||||
/// </summary>
|
||||
/// <param name="masterListId">The identifier of the master list whose units are to be retrieved.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the collection of units that belong to the specified master list.</returns>
|
||||
/// <!-- aidoc:v1 sig=2e9fc3b -->
|
||||
Task<IEnumerable<Unit>> FindUnitsByMasterListId(ObjectId masterListId);
|
||||
/// <summary>
|
||||
/// Updates the unit master list based on the provided unit ID list DTO.
|
||||
/// </summary>
|
||||
/// <param name="updateUnitListDto">The DTO containing the list of unit IDs to be used for updating the master list.</param>
|
||||
/// <returns>A task that represents the asynchronous operation. The task result contains the updated <see cref="Unit"/>, or <c>null</c> if the update was not applicable.</returns>
|
||||
/// <!-- aidoc:v1 sig=4b7663f -->
|
||||
Task<Unit?> UpdateUnitMasterList(UpdateUnitIdListDto updateUnitListDto);
|
||||
/// <summary>
|
||||
/// Asynchronously updates the configuration for the specified unit using the provided configuration data.
|
||||
@@ -132,12 +149,14 @@ public interface IUnitService
|
||||
/// <param name="unitIdParsed">The parsed identifier of the unit whose configuration will be updated.</param>
|
||||
/// <param name="unitConfiguration">The new configuration values to apply to the unit.</param>
|
||||
/// <returns>A task that resolves to <c>true</c> if the configuration was successfully updated; otherwise, <c>false</c>.</returns>
|
||||
/// <!-- aidoc:v1 sig=bfe899b -->
|
||||
Task<bool> UpdateConfiguration(ObjectId unitIdParsed, UnitConfiguration unitConfiguration);
|
||||
/// <summary>
|
||||
/// Asynchronously deletes a unit identified by the provided <paramref name="unit"/> entity's identifier.
|
||||
/// </summary>
|
||||
/// <param name="unit">The unit entity whose identifier is used to locate and delete the record.</param>
|
||||
/// <returns>A <see cref="Task{TResult}"/> that represents the asynchronous operation, containing a value indicating whether the unit was successfully deleted.</returns>
|
||||
/// <!-- aidoc:v1 sig=734db28 -->
|
||||
Task<bool> DeleteUnitById(Unit unit);
|
||||
/// <summary>
|
||||
/// Updates the information of an existing unit identified by <paramref name="unitId"/>, including its name, title, and optionally its configuration object ID.
|
||||
@@ -148,6 +167,7 @@ public interface IUnitService
|
||||
/// <param name="title">The new title to assign to the unit.</param>
|
||||
/// <param name="configObsId">An optional configuration object ID to associate with the unit.</param>
|
||||
/// <returns>A task that yields the updated <see cref="Unit"/>, or <c>null</c> if the unit does not exist.</returns>
|
||||
/// <!-- aidoc:v1 sig=89b9f8d -->
|
||||
Task<Unit?> UpdateUnitInfo(ObjectId unitId, string name, string title, string? configObsId = null);
|
||||
/// <summary>
|
||||
/// Retrieves a paginated list of units based on the provided filter, optionally including their associated points of contact.
|
||||
@@ -155,5 +175,6 @@ public interface IUnitService
|
||||
/// <param name="filter">The pagination filter that defines the page size, page number, and any additional query criteria.</param>
|
||||
/// <param name="withPoCs">A flag indicating whether the response should include the points of contact associated with each unit.</param>
|
||||
/// <returns>A task that represents the asynchronous operation, containing the paginated response of units.</returns>
|
||||
/// <!-- aidoc:v1 sig=5b42d0a -->
|
||||
Task<PaginationResponse<Unit>> GetPaginatedUnits(PaginationFilter filter, bool withPoCs);
|
||||
}
|
||||
Reference in New Issue
Block a user