@icure/cardinal-sdk 2.6.1 → 2.8.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.
Files changed (53) hide show
  1. package/Kotlin-DateTime-library-kotlinx-datetime.mjs +1 -1
  2. package/api/CalendarItemBasicApi.d.mts +36 -0
  3. package/api/CalendarItemBasicInGroupApi.d.mts +16 -0
  4. package/api/FilterApi.d.mts +6 -0
  5. package/api/FilterApi.mjs +1 -0
  6. package/api.d.mts +1 -0
  7. package/api.mjs +1 -0
  8. package/cardinal-sdk-ts.d.mts +1 -1
  9. package/cardinal-sdk-ts.mjs +40387 -39924
  10. package/cardinal-sdk.mjs +83203 -82225
  11. package/filters/MessageFilters.d.mts +1 -1
  12. package/filters/MessageFilters.mjs +1 -1
  13. package/kotlin-kotlin-stdlib.mjs +4 -4
  14. package/kotlinx-coroutines-core.mjs +8 -8
  15. package/model/CalendarItemOccupancy.d.mts +25 -0
  16. package/model/CalendarItemOccupancy.mjs +39 -0
  17. package/model/Document.d.mts +12 -0
  18. package/model/Document.mjs +8 -0
  19. package/model/Group.d.mts +19 -3
  20. package/model/Group.mjs +28 -3
  21. package/model/HealthElement.d.mts +12 -12
  22. package/model/HealthElement.mjs +8 -8
  23. package/model/Receipt.d.mts +24 -0
  24. package/model/Receipt.mjs +16 -0
  25. package/model/User.d.mts +3 -3
  26. package/model/User.mjs +3 -3
  27. package/model/base/CodeStub.d.mts +3 -3
  28. package/model/base/CodeStub.mjs +3 -3
  29. package/model/base/CryptoActor.mjs +2 -2
  30. package/model/base/Identifier.d.mts +5 -0
  31. package/model/base/Identifier.mjs +5 -0
  32. package/model/couchdb/DesignDocument.d.mts +0 -7
  33. package/model/couchdb/DesignDocument.mjs +0 -9
  34. package/model/couchdb/ReplicatorDocument.d.mts +0 -7
  35. package/model/couchdb/ReplicatorDocument.mjs +0 -10
  36. package/model/embed/DataAttachment.d.mts +2 -2
  37. package/model/embed/DataAttachment.mjs +2 -2
  38. package/model/embed/Medication.d.mts +85 -0
  39. package/model/embed/Medication.mjs +85 -0
  40. package/model/embed/Partnership.d.mts +8 -0
  41. package/model/embed/Partnership.mjs +8 -0
  42. package/model/embed/Service.d.mts +30 -0
  43. package/model/embed/Service.mjs +20 -0
  44. package/model/embed/form/template/Field.d.mts +1 -1
  45. package/model/embed/form/template/StructureElement.d.mts +1 -1
  46. package/model/embed/form/template/StructureElement.mjs +7 -7
  47. package/model/filter/FilterOptionGroupWithViews.d.mts +21 -0
  48. package/model/filter/FilterOptionGroupWithViews.mjs +47 -0
  49. package/model/filter/predicate/Predicate.d.mts +1 -1
  50. package/model/filter/predicate/Predicate.mjs +2 -2
  51. package/model.d.mts +2 -0
  52. package/model.mjs +2 -0
  53. package/package.json +1 -1
@@ -75,13 +75,6 @@ export declare class ReplicatorDocument implements Versionable<string> {
75
75
  revsInfo: Array<{
76
76
  [key: string]: string;
77
77
  }> | undefined;
78
- /**
79
- *
80
- * A map of the document revision history.
81
- */
82
- revHistory: {
83
- [key: string]: string;
84
- } | undefined;
85
78
  constructor(partial: Partial<ReplicatorDocument>);
86
79
  toJSON(): object;
87
80
  static fromJSON(json: any, ignoreUnknownKeys?: boolean, path?: Array<string>): ReplicatorDocument;
@@ -72,11 +72,6 @@ export class ReplicatorDocument {
72
72
  * Information about the document revisions.
73
73
  */
74
74
  this.revsInfo = undefined;
75
- /**
76
- *
77
- * A map of the document revision history.
78
- */
79
- this.revHistory = undefined;
80
75
  this.id = (_a = partial.id) !== null && _a !== void 0 ? _a : randomUuid();
81
76
  if ('rev' in partial)
82
77
  this.rev = partial.rev;
@@ -102,8 +97,6 @@ export class ReplicatorDocument {
102
97
  this.errorCount = partial.errorCount;
103
98
  if ('revsInfo' in partial)
104
99
  this.revsInfo = partial.revsInfo;
105
- if ('revHistory' in partial)
106
- this.revHistory = partial.revHistory;
107
100
  }
108
101
  toJSON() {
109
102
  const res = {};
@@ -132,8 +125,6 @@ export class ReplicatorDocument {
132
125
  res['errorCount'] = this.errorCount;
133
126
  if (this.revsInfo != undefined)
134
127
  res['revsInfo'] = this.revsInfo.map((x0) => Object.fromEntries(Object.entries(x0).map(([k1, v1]) => [k1, v1])));
135
- if (this.revHistory != undefined)
136
- res['revHistory'] = Object.fromEntries(Object.entries(this.revHistory).map(([k0, v0]) => [k0, v0]));
137
128
  return res;
138
129
  }
139
130
  static fromJSON(json, ignoreUnknownKeys = false, path = ['ReplicatorDocument']) {
@@ -154,7 +145,6 @@ export class ReplicatorDocument {
154
145
  replicationStats: expectObject(extractEntry(jCpy, 'replicationStats', false, path), true, ignoreUnknownKeys, [...path, ".replicationStats"], ReplicationStats.fromJSON),
155
146
  errorCount: expectNumber(extractEntry(jCpy, 'errorCount', false, path), true, true, [...path, ".errorCount"]),
156
147
  revsInfo: expectArray(extractEntry(jCpy, 'revsInfo', false, path), true, [...path, ".revsInfo"], (x0, p0) => expectMap(x0, false, p0, (k1, p1) => expectString(k1, false, p1), (v1, p1) => expectString(v1, false, p1))),
157
- revHistory: expectMap(extractEntry(jCpy, 'revHistory', false, path), true, [...path, ".revHistory"], (k0, p0) => expectString(k0, false, p0), (v0, p0) => expectString(v0, false, p0)),
158
148
  });
159
149
  if (!ignoreUnknownKeys) {
160
150
  const unused = Object.keys(jCpy);
@@ -1,8 +1,8 @@
1
1
  /**
2
2
  *
3
- * Represents a data attachment that can be stored either as a CouchDB attachment or via object
3
+ *
4
+ * Represents a data attachment that can be stored either as a CouchDB attachment or via object
4
5
  * storage.
5
- * /
6
6
  */
7
7
  export declare class DataAttachment {
8
8
  /**
@@ -2,9 +2,9 @@
2
2
  import { expectArray, expectNumber, expectString, extractEntry } from '../../internal/JsonDecodeUtils.mjs';
3
3
  /**
4
4
  *
5
- * Represents a data attachment that can be stored either as a CouchDB attachment or via object
5
+ *
6
+ * Represents a data attachment that can be stored either as a CouchDB attachment or via object
6
7
  * storage.
7
- * /
8
8
  */
9
9
  export class DataAttachment {
10
10
  constructor(partial) {
@@ -17,22 +17,107 @@ export declare class Medication {
17
17
  * The expiration date of the medication. Format: yyyyMMdd
18
18
  */
19
19
  expirationDate: number | undefined;
20
+ /**
21
+ *
22
+ * The expiration date of the medication. Format: yyyyMMdd
23
+ * /
24
+ */
20
25
  instructionForPatient: string | undefined;
26
+ /**
27
+ *
28
+ * The expiration date of the medication. Format: yyyyMMdd
29
+ * /
30
+ */
21
31
  instructionForReimbursement: string | undefined;
32
+ /**
33
+ *
34
+ * The expiration date of the medication. Format: yyyyMMdd
35
+ * /
36
+ */
22
37
  commentForDelivery: string | undefined;
38
+ /**
39
+ *
40
+ * The expiration date of the medication. Format: yyyyMMdd
41
+ * /
42
+ */
23
43
  drugRoute: string | undefined;
44
+ /**
45
+ *
46
+ * The expiration date of the medication. Format: yyyyMMdd
47
+ * /
48
+ */
24
49
  temporality: string | undefined;
50
+ /**
51
+ *
52
+ * The expiration date of the medication. Format: yyyyMMdd
53
+ * /
54
+ */
25
55
  frequency: CodeStub | undefined;
56
+ /**
57
+ *
58
+ * The expiration date of the medication. Format: yyyyMMdd
59
+ * /
60
+ */
26
61
  reimbursementReason: CodeStub | undefined;
62
+ /**
63
+ *
64
+ * The expiration date of the medication. Format: yyyyMMdd
65
+ * /
66
+ */
27
67
  substitutionAllowed: boolean | undefined;
68
+ /**
69
+ *
70
+ * The expiration date of the medication. Format: yyyyMMdd
71
+ * /
72
+ */
28
73
  beginMoment: number | undefined;
74
+ /**
75
+ *
76
+ * The expiration date of the medication. Format: yyyyMMdd
77
+ * /
78
+ */
29
79
  endMoment: number | undefined;
80
+ /**
81
+ *
82
+ * The expiration date of the medication. Format: yyyyMMdd
83
+ * /
84
+ */
30
85
  deliveryMoment: number | undefined;
86
+ /**
87
+ *
88
+ * The expiration date of the medication. Format: yyyyMMdd
89
+ * /
90
+ */
31
91
  endExecutionMoment: number | undefined;
92
+ /**
93
+ *
94
+ * The expiration date of the medication. Format: yyyyMMdd
95
+ * /
96
+ */
32
97
  duration: Duration | undefined;
98
+ /**
99
+ *
100
+ * The expiration date of the medication. Format: yyyyMMdd
101
+ * /
102
+ */
33
103
  renewal: Renewal | undefined;
104
+ /**
105
+ *
106
+ * The expiration date of the medication. Format: yyyyMMdd
107
+ * /
108
+ */
34
109
  knownUsage: boolean | undefined;
110
+ /**
111
+ *
112
+ * The expiration date of the medication. Format: yyyyMMdd
113
+ * /
114
+ */
35
115
  regimen: Array<RegimenItem> | undefined;
116
+ /**
117
+ *
118
+ * The expiration date of the medication. Format: yyyyMMdd
119
+ * /
120
+ */
36
121
  posology: string | undefined;
37
122
  stockLocation: DecryptedAddress | undefined;
38
123
  constructor(partial: Partial<Medication>);
@@ -20,22 +20,107 @@ export class Medication {
20
20
  * The expiration date of the medication. Format: yyyyMMdd
21
21
  */
22
22
  this.expirationDate = undefined;
23
+ /**
24
+ *
25
+ * The expiration date of the medication. Format: yyyyMMdd
26
+ * /
27
+ */
23
28
  this.instructionForPatient = undefined;
29
+ /**
30
+ *
31
+ * The expiration date of the medication. Format: yyyyMMdd
32
+ * /
33
+ */
24
34
  this.instructionForReimbursement = undefined;
35
+ /**
36
+ *
37
+ * The expiration date of the medication. Format: yyyyMMdd
38
+ * /
39
+ */
25
40
  this.commentForDelivery = undefined;
41
+ /**
42
+ *
43
+ * The expiration date of the medication. Format: yyyyMMdd
44
+ * /
45
+ */
26
46
  this.drugRoute = undefined;
47
+ /**
48
+ *
49
+ * The expiration date of the medication. Format: yyyyMMdd
50
+ * /
51
+ */
27
52
  this.temporality = undefined;
53
+ /**
54
+ *
55
+ * The expiration date of the medication. Format: yyyyMMdd
56
+ * /
57
+ */
28
58
  this.frequency = undefined;
59
+ /**
60
+ *
61
+ * The expiration date of the medication. Format: yyyyMMdd
62
+ * /
63
+ */
29
64
  this.reimbursementReason = undefined;
65
+ /**
66
+ *
67
+ * The expiration date of the medication. Format: yyyyMMdd
68
+ * /
69
+ */
30
70
  this.substitutionAllowed = undefined;
71
+ /**
72
+ *
73
+ * The expiration date of the medication. Format: yyyyMMdd
74
+ * /
75
+ */
31
76
  this.beginMoment = undefined;
77
+ /**
78
+ *
79
+ * The expiration date of the medication. Format: yyyyMMdd
80
+ * /
81
+ */
32
82
  this.endMoment = undefined;
83
+ /**
84
+ *
85
+ * The expiration date of the medication. Format: yyyyMMdd
86
+ * /
87
+ */
33
88
  this.deliveryMoment = undefined;
89
+ /**
90
+ *
91
+ * The expiration date of the medication. Format: yyyyMMdd
92
+ * /
93
+ */
34
94
  this.endExecutionMoment = undefined;
95
+ /**
96
+ *
97
+ * The expiration date of the medication. Format: yyyyMMdd
98
+ * /
99
+ */
35
100
  this.duration = undefined;
101
+ /**
102
+ *
103
+ * The expiration date of the medication. Format: yyyyMMdd
104
+ * /
105
+ */
36
106
  this.renewal = undefined;
107
+ /**
108
+ *
109
+ * The expiration date of the medication. Format: yyyyMMdd
110
+ * /
111
+ */
37
112
  this.knownUsage = undefined;
113
+ /**
114
+ *
115
+ * The expiration date of the medication. Format: yyyyMMdd
116
+ * /
117
+ */
38
118
  this.regimen = undefined;
119
+ /**
120
+ *
121
+ * The expiration date of the medication. Format: yyyyMMdd
122
+ * /
123
+ */
39
124
  this.posology = undefined;
40
125
  this.stockLocation = undefined;
41
126
  if ('compoundPrescription' in partial)
@@ -49,6 +49,10 @@ export declare class DecryptedPartnership {
49
49
  * The UUID of the contact person or patient in this relationship.
50
50
  */
51
51
  partnerId: string | undefined;
52
+ /**
53
+ *
54
+ * Deprecated. Description of the relationship from the other person to this patient.
55
+ */
52
56
  encryptedSelf: Base64String | undefined;
53
57
  readonly isEncrypted: false;
54
58
  constructor(partial: Partial<DecryptedPartnership>);
@@ -77,6 +81,10 @@ export declare class EncryptedPartnership {
77
81
  * The UUID of the contact person or patient in this relationship.
78
82
  */
79
83
  partnerId: string | undefined;
84
+ /**
85
+ *
86
+ * Deprecated. Description of the relationship from the other person to this patient.
87
+ */
80
88
  encryptedSelf: Base64String | undefined;
81
89
  readonly isEncrypted: true;
82
90
  constructor(partial: Partial<EncryptedPartnership>);
@@ -25,6 +25,10 @@ export class DecryptedPartnership {
25
25
  * The UUID of the contact person or patient in this relationship.
26
26
  */
27
27
  this.partnerId = undefined;
28
+ /**
29
+ *
30
+ * Deprecated. Description of the relationship from the other person to this patient.
31
+ */
28
32
  this.encryptedSelf = undefined;
29
33
  this.isEncrypted = false;
30
34
  if (partial.isEncrypted !== undefined && partial.isEncrypted !== false)
@@ -94,6 +98,10 @@ export class EncryptedPartnership {
94
98
  * The UUID of the contact person or patient in this relationship.
95
99
  */
96
100
  this.partnerId = undefined;
101
+ /**
102
+ *
103
+ * Deprecated. Description of the relationship from the other person to this patient.
104
+ */
97
105
  this.encryptedSelf = undefined;
98
106
  this.isEncrypted = true;
99
107
  if (partial.isEncrypted !== undefined && partial.isEncrypted !== true)
@@ -16,6 +16,11 @@ export interface Service extends Encryptable, ICureDocument<string>, HasEndOfLif
16
16
  * reasons. Several services with the same non null transaction id form one single service
17
17
  */
18
18
  transactionId: string | undefined;
19
+ /**
20
+ *
21
+ * The transactionId is used when a single service had to be split into parts for technical
22
+ * reasons. Several services with the same non null transaction id form one single service
23
+ */
19
24
  identifier: Array<Identifier>;
20
25
  /**
21
26
  *
@@ -42,6 +47,11 @@ export interface Service extends Encryptable, ICureDocument<string>, HasEndOfLif
42
47
  * its contact.
43
48
  */
44
49
  formIds: Array<string> | undefined;
50
+ /**
51
+ *
52
+ * List of Ids of all forms linked to the Service. Only used when the Service is emitted outside of
53
+ * its contact.
54
+ */
45
55
  secretForeignKeys: Array<string> | undefined;
46
56
  /**
47
57
  *
@@ -146,6 +156,11 @@ export declare class DecryptedService {
146
156
  * reasons. Several services with the same non null transaction id form one single service
147
157
  */
148
158
  transactionId: string | undefined;
159
+ /**
160
+ *
161
+ * The transactionId is used when a single service had to be split into parts for technical
162
+ * reasons. Several services with the same non null transaction id form one single service
163
+ */
149
164
  identifier: Array<Identifier>;
150
165
  /**
151
166
  *
@@ -172,6 +187,11 @@ export declare class DecryptedService {
172
187
  * its contact.
173
188
  */
174
189
  formIds: Array<string> | undefined;
190
+ /**
191
+ *
192
+ * List of Ids of all forms linked to the Service. Only used when the Service is emitted outside of
193
+ * its contact.
194
+ */
175
195
  secretForeignKeys: Array<string> | undefined;
176
196
  /**
177
197
  *
@@ -309,6 +329,11 @@ export declare class EncryptedService {
309
329
  * reasons. Several services with the same non null transaction id form one single service
310
330
  */
311
331
  transactionId: string | undefined;
332
+ /**
333
+ *
334
+ * The transactionId is used when a single service had to be split into parts for technical
335
+ * reasons. Several services with the same non null transaction id form one single service
336
+ */
312
337
  identifier: Array<Identifier>;
313
338
  /**
314
339
  *
@@ -335,6 +360,11 @@ export declare class EncryptedService {
335
360
  * its contact.
336
361
  */
337
362
  formIds: Array<string> | undefined;
363
+ /**
364
+ *
365
+ * List of Ids of all forms linked to the Service. Only used when the Service is emitted outside of
366
+ * its contact.
367
+ */
338
368
  secretForeignKeys: Array<string> | undefined;
339
369
  /**
340
370
  *
@@ -17,6 +17,11 @@ export class DecryptedService {
17
17
  * reasons. Several services with the same non null transaction id form one single service
18
18
  */
19
19
  this.transactionId = undefined;
20
+ /**
21
+ *
22
+ * The transactionId is used when a single service had to be split into parts for technical
23
+ * reasons. Several services with the same non null transaction id form one single service
24
+ */
20
25
  this.identifier = [];
21
26
  /**
22
27
  *
@@ -43,6 +48,11 @@ export class DecryptedService {
43
48
  * its contact.
44
49
  */
45
50
  this.formIds = undefined;
51
+ /**
52
+ *
53
+ * List of Ids of all forms linked to the Service. Only used when the Service is emitted outside of
54
+ * its contact.
55
+ */
46
56
  this.secretForeignKeys = [];
47
57
  /**
48
58
  *
@@ -330,6 +340,11 @@ export class EncryptedService {
330
340
  * reasons. Several services with the same non null transaction id form one single service
331
341
  */
332
342
  this.transactionId = undefined;
343
+ /**
344
+ *
345
+ * The transactionId is used when a single service had to be split into parts for technical
346
+ * reasons. Several services with the same non null transaction id form one single service
347
+ */
333
348
  this.identifier = [];
334
349
  /**
335
350
  *
@@ -356,6 +371,11 @@ export class EncryptedService {
356
371
  * its contact.
357
372
  */
358
373
  this.formIds = undefined;
374
+ /**
375
+ *
376
+ * List of Ids of all forms linked to the Service. Only used when the Service is emitted outside of
377
+ * its contact.
378
+ */
359
379
  this.secretForeignKeys = [];
360
380
  /**
361
381
  *
@@ -17,4 +17,4 @@ import { TimePicker } from './TimePicker.mjs';
17
17
  * validation rules, and optional codification and tagging.
18
18
  * /
19
19
  */
20
- export type Field = DropdownField | DateTimePicker | RadioButton | MultipleChoice | MeasureField | CheckBox | TextField | TimePicker | DatePicker | NumberField;
20
+ export type Field = TextField | MultipleChoice | TimePicker | DatePicker | RadioButton | MeasureField | DropdownField | NumberField | CheckBox | DateTimePicker;
@@ -6,7 +6,7 @@ import { FieldsGroup } from './FieldsGroup.mjs';
6
6
  * groups.
7
7
  * /
8
8
  */
9
- export type StructureElement = Field | FieldsGroup;
9
+ export type StructureElement = FieldsGroup | Field;
10
10
  export declare namespace StructureElement {
11
11
  function fromJSON(json: any, ignoreUnknownKeys?: boolean, path?: Array<string>): StructureElement;
12
12
  }
@@ -14,17 +14,17 @@ export var StructureElement;
14
14
  (function (StructureElement) {
15
15
  function fromJSON(json, ignoreUnknownKeys = false, path = ['StructureElement']) {
16
16
  switch (json.$ktClass) {
17
- case 'com.icure.cardinal.sdk.model.embed.form.template.DropdownField': return DropdownField.fromJSON(json, ignoreUnknownKeys);
18
- case 'com.icure.cardinal.sdk.model.embed.form.template.DateTimePicker': return DateTimePicker.fromJSON(json, ignoreUnknownKeys);
19
- case 'com.icure.cardinal.sdk.model.embed.form.template.RadioButton': return RadioButton.fromJSON(json, ignoreUnknownKeys);
20
- case 'com.icure.cardinal.sdk.model.embed.form.template.MultipleChoice': return MultipleChoice.fromJSON(json, ignoreUnknownKeys);
21
- case 'com.icure.cardinal.sdk.model.embed.form.template.MeasureField': return MeasureField.fromJSON(json, ignoreUnknownKeys);
22
- case 'com.icure.cardinal.sdk.model.embed.form.template.CheckBox': return CheckBox.fromJSON(json, ignoreUnknownKeys);
17
+ case 'com.icure.cardinal.sdk.model.embed.form.template.FieldsGroup': return FieldsGroup.fromJSON(json, ignoreUnknownKeys);
23
18
  case 'com.icure.cardinal.sdk.model.embed.form.template.TextField': return TextField.fromJSON(json, ignoreUnknownKeys);
19
+ case 'com.icure.cardinal.sdk.model.embed.form.template.MultipleChoice': return MultipleChoice.fromJSON(json, ignoreUnknownKeys);
24
20
  case 'com.icure.cardinal.sdk.model.embed.form.template.TimePicker': return TimePicker.fromJSON(json, ignoreUnknownKeys);
25
21
  case 'com.icure.cardinal.sdk.model.embed.form.template.DatePicker': return DatePicker.fromJSON(json, ignoreUnknownKeys);
22
+ case 'com.icure.cardinal.sdk.model.embed.form.template.RadioButton': return RadioButton.fromJSON(json, ignoreUnknownKeys);
23
+ case 'com.icure.cardinal.sdk.model.embed.form.template.MeasureField': return MeasureField.fromJSON(json, ignoreUnknownKeys);
24
+ case 'com.icure.cardinal.sdk.model.embed.form.template.DropdownField': return DropdownField.fromJSON(json, ignoreUnknownKeys);
26
25
  case 'com.icure.cardinal.sdk.model.embed.form.template.NumberField': return NumberField.fromJSON(json, ignoreUnknownKeys);
27
- case 'com.icure.cardinal.sdk.model.embed.form.template.FieldsGroup': return FieldsGroup.fromJSON(json, ignoreUnknownKeys);
26
+ case 'com.icure.cardinal.sdk.model.embed.form.template.CheckBox': return CheckBox.fromJSON(json, ignoreUnknownKeys);
27
+ case 'com.icure.cardinal.sdk.model.embed.form.template.DateTimePicker': return DateTimePicker.fromJSON(json, ignoreUnknownKeys);
28
28
  default: throw new Error('Unexpected discriminator for StructureElement: ' + json.$ktClass);
29
29
  }
30
30
  }
@@ -0,0 +1,21 @@
1
+ /**
2
+ *
3
+ * A set of factory methods that produce the same kind of filter, differing only in how parameters are
4
+ * passed (for-self vs. for-data-owner, in-group variants, full entities vs. secret ids).
5
+ *
6
+ * @property name a short semantic name for the group (the operation, without the parameter-passing suffixes).
7
+ * @property factoryMethods the names of the factory methods of the corresponding `XFilters` object that
8
+ * belong to this group, in source order.
9
+ * @property targetFilter the simple name of the `AbstractFilter` actually sent to the backend (or the
10
+ * possible filters, separated by " or ", for the rare groups that branch on their input).
11
+ * @property views the views that are used on the backend to provide the results for the options in this group.
12
+ */
13
+ export declare class FilterOptionGroupWithViews {
14
+ name: string;
15
+ factoryMethods: Array<string>;
16
+ targetFilter: string;
17
+ views: Array<string>;
18
+ constructor(partial: Partial<FilterOptionGroupWithViews> & Pick<FilterOptionGroupWithViews, "name" | "factoryMethods" | "targetFilter" | "views">);
19
+ toJSON(): object;
20
+ static fromJSON(json: any, ignoreUnknownKeys?: boolean, path?: Array<string>): FilterOptionGroupWithViews;
21
+ }
@@ -0,0 +1,47 @@
1
+ // auto-generated file
2
+ import { expectArray, expectString, extractEntry } from '../../internal/JsonDecodeUtils.mjs';
3
+ /**
4
+ *
5
+ * A set of factory methods that produce the same kind of filter, differing only in how parameters are
6
+ * passed (for-self vs. for-data-owner, in-group variants, full entities vs. secret ids).
7
+ *
8
+ * @property name a short semantic name for the group (the operation, without the parameter-passing suffixes).
9
+ * @property factoryMethods the names of the factory methods of the corresponding `XFilters` object that
10
+ * belong to this group, in source order.
11
+ * @property targetFilter the simple name of the `AbstractFilter` actually sent to the backend (or the
12
+ * possible filters, separated by " or ", for the rare groups that branch on their input).
13
+ * @property views the views that are used on the backend to provide the results for the options in this group.
14
+ */
15
+ export class FilterOptionGroupWithViews {
16
+ constructor(partial) {
17
+ this.name = partial.name;
18
+ this.factoryMethods = partial.factoryMethods;
19
+ this.targetFilter = partial.targetFilter;
20
+ this.views = partial.views;
21
+ }
22
+ toJSON() {
23
+ const res = {};
24
+ res['name'] = this.name;
25
+ res['factoryMethods'] = this.factoryMethods.map((x0) => x0);
26
+ res['targetFilter'] = this.targetFilter;
27
+ res['views'] = this.views.map((x0) => x0);
28
+ return res;
29
+ }
30
+ static fromJSON(json, ignoreUnknownKeys = false, path = ['FilterOptionGroupWithViews']) {
31
+ if (typeof json != 'object')
32
+ throw new Error(`Expected json object at path ${path.join("")}`);
33
+ const jCpy = Object.assign({}, json);
34
+ const res = new FilterOptionGroupWithViews({
35
+ name: expectString(extractEntry(jCpy, 'name', true, path), false, [...path, ".name"]),
36
+ factoryMethods: expectArray(extractEntry(jCpy, 'factoryMethods', true, path), false, [...path, ".factoryMethods"], (x0, p0) => expectString(x0, false, p0)),
37
+ targetFilter: expectString(extractEntry(jCpy, 'targetFilter', true, path), false, [...path, ".targetFilter"]),
38
+ views: expectArray(extractEntry(jCpy, 'views', true, path), false, [...path, ".views"], (x0, p0) => expectString(x0, false, p0)),
39
+ });
40
+ if (!ignoreUnknownKeys) {
41
+ const unused = Object.keys(jCpy);
42
+ if (unused.length > 0)
43
+ throw new Error(`Unexpected key(s) for json object FilterOptionGroupWithViews at path ${path.join("")}: ${unused}`);
44
+ }
45
+ return res;
46
+ }
47
+ }
@@ -9,7 +9,7 @@ import { OrPredicate } from './OrPredicate.mjs';
9
9
  * chain.
10
10
  * /
11
11
  */
12
- export type Predicate = AlwaysPredicate | OrPredicate | NotPredicate | AndPredicate | KeyValuePredicate;
12
+ export type Predicate = AndPredicate | OrPredicate | AlwaysPredicate | NotPredicate | KeyValuePredicate;
13
13
  export declare namespace Predicate {
14
14
  function fromJSON(json: any, ignoreUnknownKeys?: boolean, path?: Array<string>): Predicate;
15
15
  }
@@ -8,10 +8,10 @@ export var Predicate;
8
8
  (function (Predicate) {
9
9
  function fromJSON(json, ignoreUnknownKeys = false, path = ['Predicate']) {
10
10
  switch (json.$ktClass) {
11
- case 'com.icure.cardinal.sdk.model.filter.predicate.AlwaysPredicate': return AlwaysPredicate.fromJSON(json, ignoreUnknownKeys);
11
+ case 'com.icure.cardinal.sdk.model.filter.predicate.AndPredicate': return AndPredicate.fromJSON(json, ignoreUnknownKeys);
12
12
  case 'com.icure.cardinal.sdk.model.filter.predicate.OrPredicate': return OrPredicate.fromJSON(json, ignoreUnknownKeys);
13
+ case 'com.icure.cardinal.sdk.model.filter.predicate.AlwaysPredicate': return AlwaysPredicate.fromJSON(json, ignoreUnknownKeys);
13
14
  case 'com.icure.cardinal.sdk.model.filter.predicate.NotPredicate': return NotPredicate.fromJSON(json, ignoreUnknownKeys);
14
- case 'com.icure.cardinal.sdk.model.filter.predicate.AndPredicate': return AndPredicate.fromJSON(json, ignoreUnknownKeys);
15
15
  case 'com.icure.cardinal.sdk.model.filter.predicate.KeyValuePredicate': return KeyValuePredicate.fromJSON(json, ignoreUnknownKeys);
16
16
  default: throw new Error('Unexpected discriminator for Predicate: ' + json.$ktClass);
17
17
  }
package/model.d.mts CHANGED
@@ -181,10 +181,12 @@ export * from './model/filter/predicate/Operator.mjs';
181
181
  export * from './model/filter/predicate/OrPredicate.mjs';
182
182
  export * from './model/filter/predicate/AlwaysPredicate.mjs';
183
183
  export * from './model/filter/predicate/AndPredicate.mjs';
184
+ export * from './model/filter/FilterOptionGroupWithViews.mjs';
184
185
  export * from './model/GroupDeletionReport.mjs';
185
186
  export * from './model/Message.mjs';
186
187
  export * from './model/Agenda.mjs';
187
188
  export * from './model/data/LabelledOccurence.mjs';
189
+ export * from './model/CalendarItemOccupancy.mjs';
188
190
  export * from './model/Form.mjs';
189
191
  export * from './model/Patient.mjs';
190
192
  export * from './model/base/Versionable.mjs';
package/model.mjs CHANGED
@@ -181,10 +181,12 @@ export * from './model/filter/predicate/Operator.mjs';
181
181
  export * from './model/filter/predicate/OrPredicate.mjs';
182
182
  export * from './model/filter/predicate/AlwaysPredicate.mjs';
183
183
  export * from './model/filter/predicate/AndPredicate.mjs';
184
+ export * from './model/filter/FilterOptionGroupWithViews.mjs';
184
185
  export * from './model/GroupDeletionReport.mjs';
185
186
  export * from './model/Message.mjs';
186
187
  export * from './model/Agenda.mjs';
187
188
  export * from './model/data/LabelledOccurence.mjs';
189
+ export * from './model/CalendarItemOccupancy.mjs';
188
190
  export * from './model/Form.mjs';
189
191
  export * from './model/Patient.mjs';
190
192
  export * from './model/base/Versionable.mjs';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@icure/cardinal-sdk",
3
- "version": "2.6.1",
3
+ "version": "2.8.0",
4
4
  "main": "cardinal-sdk-ts.mjs",
5
5
  "types": "cardinal-sdk-ts.d.mts",
6
6
  "devDependencies": {