@icure/cardinal-sdk 2.8.0 → 2.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -367,7 +367,7 @@ function addFormatStructureForDate(structure) {
367
367
  function addFormatStructureForTime(structure) {
368
368
  this.u3z(structure);
369
369
  }
370
- initMetadataForInterface(AbstractWithDateTimeBuilder, 'AbstractWithDateTimeBuilder', VOID, VOID, [AbstractWithDateBuilder, AbstractWithTimeBuilder, WithTime, WithDate]);
370
+ initMetadataForInterface(AbstractWithDateTimeBuilder, 'AbstractWithDateTimeBuilder', VOID, VOID, [AbstractWithDateBuilder, AbstractWithTimeBuilder, WithDate, WithTime]);
371
371
  initMetadataForClass(Builder_0, 'Builder', VOID, VOID, [AbstractDateTimeFormatBuilder, AbstractWithDateTimeBuilder]);
372
372
  initMetadataForClass(LocalDateTimeFormat, 'LocalDateTimeFormat', VOID, AbstractDateTimeFormat);
373
373
  function set_fractionOfSecond(value) {
@@ -2,6 +2,7 @@ import { FilterOptions, PaginatedListIterator, SortableFilterOptions } from '../
2
2
  import { CalendarItemShareOptions } from '../crypto/entities/CalendarItemShareOptions.mjs';
3
3
  import { SecretIdUseOption } from '../crypto/entities/SecretIdUseOption.mjs';
4
4
  import { CalendarItem, DecryptedCalendarItem, EncryptedCalendarItem } from '../model/CalendarItem.mjs';
5
+ import { CalendarItemOccupancy } from '../model/CalendarItemOccupancy.mjs';
5
6
  import { EntityReferenceInGroup } from '../model/EntityReferenceInGroup.mjs';
6
7
  import { Patient } from '../model/Patient.mjs';
7
8
  import { StoredDocumentIdentifier } from '../model/StoredDocumentIdentifier.mjs';
@@ -153,6 +154,41 @@ export interface CalendarItemApi {
153
154
  * @return a list of calendarItem ids
154
155
  */
155
156
  matchCalendarItemsBySorted(filter: SortableFilterOptions<CalendarItem>): Promise<Array<string>>;
157
+ /**
158
+ *
159
+ * Computes the concurrent-occupancy histogram of the calendar items for the current data owner over the
160
+ * period [startDate]..[endDate] (fuzzy date-times, either bound may be null = open).
161
+ *
162
+ * Only calendar items whose whole interval fits within the search range are considered. By default, the
163
+ * range is exactly [startDate]..[endDate], so items starting before [startDate] or ending after [endDate]
164
+ * are ignored. Pass [extensionInDays] to widen the range by that many days on each side, which lets items
165
+ * that start shortly before [startDate] (contributing to the occupancy baseline) or end shortly after
166
+ * [endDate] be taken into account. Items reaching beyond the extended range are still ignored.
167
+ */
168
+ getCalendarItemsOccupancyByPeriodForSelf(startDate: number, endDate: number, extensionInDays: number | undefined): Promise<Array<CalendarItemOccupancy>>;
169
+ /**
170
+ *
171
+ * Computes the concurrent-occupancy histogram of the calendar items of [hcPartyId] over the
172
+ * period [startDate]..[endDate] (fuzzy date-times, either bound may be null = open).
173
+ *
174
+ * Only calendar items whose whole interval fits within the search range are considered. By default, the
175
+ * range is exactly [startDate]..[endDate], so items starting before [startDate] or ending after [endDate]
176
+ * are ignored. Pass [extensionInDays] to widen the range by that many days on each side, which lets items
177
+ * that start shortly before [startDate] (contributing to the occupancy baseline) or end shortly after
178
+ * [endDate] be taken into account. Items reaching beyond the extended range are still ignored.
179
+ */
180
+ getCalendarItemsOccupancyByPeriodForHealthcareParty(startDate: number, endDate: number, hcPartyId: string, extensionInDays: number | undefined): Promise<Array<CalendarItemOccupancy>>;
181
+ /**
182
+ *
183
+ * Computes the concurrent-occupancy histogram of the calendar items of the agenda [agendaId] over the
184
+ * period [startDate]..[endDate] (fuzzy date-times, either bound may be null = open).
185
+ *
186
+ * Only calendar items whose whole interval fits within the search range are considered. By default, the range
187
+ * is exactly [startDate]..[endDate], you can pass a non-null [extensionInDays] to widen it by that many days on each side (e.g.
188
+ * to include items that start before [startDate] but are still open during the period). Items reaching beyond
189
+ * the extended range are ignored.
190
+ */
191
+ getCalendarItemsOccupancyByPeriodAndAgendaId(startDate: number, endDate: number, agendaId: string, extensionInDays: number | undefined): Promise<Array<CalendarItemOccupancy>>;
156
192
  /**
157
193
  *
158
194
  * Deletes a calendarItem. If you don't have write access to the calendarItem the method will fail.
@@ -2,6 +2,7 @@ import { FilterOptions, PaginatedListIterator, SortableFilterOptions } from '../
2
2
  import { CalendarItemShareOptions } from '../crypto/entities/CalendarItemShareOptions.mjs';
3
3
  import { SecretIdUseOption } from '../crypto/entities/SecretIdUseOption.mjs';
4
4
  import { CalendarItem, DecryptedCalendarItem, EncryptedCalendarItem } from '../model/CalendarItem.mjs';
5
+ import { CalendarItemOccupancy } from '../model/CalendarItemOccupancy.mjs';
5
6
  import { EntityReferenceInGroup } from '../model/EntityReferenceInGroup.mjs';
6
7
  import { GroupScoped } from '../model/GroupScoped.mjs';
7
8
  import { Patient } from '../model/Patient.mjs';
@@ -72,6 +73,21 @@ export interface CalendarItemInGroupApi {
72
73
  * In-group version of [CalendarItemApi.matchCalendarItemsBySorted]
73
74
  */
74
75
  matchCalendarItemsBySorted(groupId: string, filter: SortableFilterOptions<CalendarItem>): Promise<Array<string>>;
76
+ /**
77
+ *
78
+ * In-group version of [CalendarItemApi.getCalendarItemsOccupancyByPeriodForSelf].
79
+ */
80
+ getCalendarItemsOccupancyByPeriodForSelf(groupId: string, startDate: number, endDate: number, extensionInDays: number | undefined): Promise<Array<CalendarItemOccupancy>>;
81
+ /**
82
+ *
83
+ * In-group version of [CalendarItemApi.getCalendarItemsOccupancyByPeriodForHealthcareParty].
84
+ */
85
+ getCalendarItemsOccupancyByPeriodForHealthcareParty(groupId: string, startDate: number, endDate: number, hcPartyId: string, extensionInDays: number | undefined): Promise<Array<CalendarItemOccupancy>>;
86
+ /**
87
+ *
88
+ * In-group version of [CalendarItemApi.getCalendarItemsOccupancyByPeriodAndAgendaId].
89
+ */
90
+ getCalendarItemsOccupancyByPeriodAndAgendaId(groupId: string, startDate: number, endDate: number, agendaId: string, extensionInDays: number | undefined): Promise<Array<CalendarItemOccupancy>>;
75
91
  /**
76
92
  *
77
93
  * In-group version of [CalendarItemBasicFlavourlessApi.deleteCalendarItemById]
@@ -1,3 +1,4 @@
1
+ import { BaseFilterOptions, BaseSortableFilterOptions, PaginatedListIterator } from '../cardinal-sdk-ts.mjs';
1
2
  import { Insurance } from '../model/Insurance.mjs';
2
3
  import { StoredDocumentIdentifier } from '../model/StoredDocumentIdentifier.mjs';
3
4
  import { InsuranceInGroupApi } from './InsuranceInGroupApi.mjs';
@@ -23,4 +24,8 @@ export interface InsuranceApi {
23
24
  purgeInsurances(insurances: Array<Insurance>): Promise<Array<StoredDocumentIdentifier>>;
24
25
  listInsurancesByCode(insuranceCode: string): Promise<Array<Insurance>>;
25
26
  listInsurancesByName(insuranceName: string): Promise<Array<Insurance>>;
27
+ matchInsurancesBy(filter: BaseFilterOptions<Insurance>): Promise<Array<string>>;
28
+ filterInsurancesBy(filter: BaseFilterOptions<Insurance>): Promise<PaginatedListIterator<Insurance>>;
29
+ matchInsurancesBySorted(filter: BaseSortableFilterOptions<Insurance>): Promise<Array<string>>;
30
+ filterInsurancesBySorted(filter: BaseSortableFilterOptions<Insurance>): Promise<PaginatedListIterator<Insurance>>;
26
31
  }
@@ -1,3 +1,4 @@
1
+ import { BaseFilterOptions, BaseSortableFilterOptions, PaginatedListIterator } from '../cardinal-sdk-ts.mjs';
1
2
  import { GroupScoped } from '../model/GroupScoped.mjs';
2
3
  import { Insurance } from '../model/Insurance.mjs';
3
4
  import { StoredDocumentIdentifier } from '../model/StoredDocumentIdentifier.mjs';
@@ -20,4 +21,8 @@ export interface InsuranceInGroupApi {
20
21
  purgeInsuranceByIds(entityIds: Array<GroupScoped<StoredDocumentIdentifier>>): Promise<Array<GroupScoped<StoredDocumentIdentifier>>>;
21
22
  purgeInsurance(insurance: GroupScoped<Insurance>): Promise<void>;
22
23
  purgeInsurances(insurances: Array<GroupScoped<Insurance>>): Promise<Array<GroupScoped<StoredDocumentIdentifier>>>;
24
+ matchInsurancesBy(groupId: string, filter: BaseFilterOptions<Insurance>): Promise<Array<string>>;
25
+ matchInsurancesBySorted(groupId: string, filter: BaseSortableFilterOptions<Insurance>): Promise<Array<string>>;
26
+ filterInsurancesBy(groupId: string, filter: BaseFilterOptions<Insurance>): Promise<PaginatedListIterator<GroupScoped<Insurance>>>;
27
+ filterInsurancesBySorted(groupId: string, filter: BaseSortableFilterOptions<Insurance>): Promise<PaginatedListIterator<GroupScoped<Insurance>>>;
23
28
  }
@@ -509,6 +509,25 @@ export declare namespace InternalHealthcarePartyFiltersObj {
509
509
  }
510
510
  }
511
511
  }
512
+ export declare abstract class InternalInsuranceFiltersObj {
513
+ static readonly getInstance: () => typeof InternalInsuranceFiltersObj.$metadata$.type;
514
+ private constructor();
515
+ }
516
+ export declare namespace InternalInsuranceFiltersObj {
517
+ /** @deprecated $metadata$ is used for internal purposes, please don't use it in your code, because it can be removed at any moment */
518
+ namespace $metadata$ {
519
+ abstract class type extends KtSingleton<constructor>() {
520
+ private constructor();
521
+ }
522
+ abstract class constructor {
523
+ all(): BaseFilterOptions<model.Insurance>;
524
+ byIdentifiers(identifiers: Array<model.Identifier>): BaseFilterOptions<model.Insurance>;
525
+ byCode(codeType: string, options: any): BaseSortableFilterOptions<model.Insurance>;
526
+ byTag(tagType: string, options: any): BaseSortableFilterOptions<model.Insurance>;
527
+ private constructor();
528
+ }
529
+ }
530
+ }
512
531
  export declare abstract class InternalMaintenanceTaskFiltersObj {
513
532
  static readonly getInstance: () => typeof InternalMaintenanceTaskFiltersObj.$metadata$.type;
514
533
  private constructor();