@nmshd/content 1.2.1 → 2.0.0-alpha.1
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.
- package/dist/attributes/Attribute.d.ts +9 -13
- package/dist/attributes/Attribute.js +26 -24
- package/dist/attributes/Attribute.js.map +1 -1
- package/dist/attributes/AttributeName.d.ts +16 -0
- package/dist/attributes/AttributeName.js +62 -0
- package/dist/attributes/AttributeName.js.map +1 -0
- package/dist/attributes/AttributeNamespace.d.ts +8 -0
- package/dist/attributes/AttributeNamespace.js +13 -0
- package/dist/attributes/AttributeNamespace.js.map +1 -0
- package/dist/buildInformation.js +4 -4
- package/dist/index.d.ts +3 -1
- package/dist/index.js +3 -1
- package/dist/index.js.map +1 -1
- package/dist/relationships/RelationshipCreationChangeRequestBody.d.ts +29 -0
- package/dist/relationships/RelationshipCreationChangeRequestBody.js +56 -0
- package/dist/relationships/RelationshipCreationChangeRequestBody.js.map +1 -0
- package/dist/relationships/RelationshipCreationChangeResponseBody.d.ts +0 -0
- package/dist/relationships/RelationshipCreationChangeResponseBody.js +2 -0
- package/dist/relationships/RelationshipCreationChangeResponseBody.js.map +1 -0
- package/dist/relationships/RelationshipExistsAction.d.ts +7 -0
- package/dist/{attributes/types/birth/BirthDay.js → relationships/RelationshipExistsAction.js} +7 -8
- package/dist/relationships/RelationshipExistsAction.js.map +1 -0
- package/dist/relationships/RelationshipExistsMessageAction.d.ts +11 -0
- package/dist/{attributes/types/address/HouseNumber.js → relationships/RelationshipExistsMessageAction.js} +10 -10
- package/dist/relationships/RelationshipExistsMessageAction.js.map +1 -0
- package/dist/relationships/RelationshipTemplateBody.d.ts +42 -0
- package/dist/relationships/RelationshipTemplateBody.js +73 -0
- package/dist/relationships/RelationshipTemplateBody.js.map +1 -0
- package/dist/requests/AttributesRequest.d.ts +49 -0
- package/dist/requests/AttributesRequest.js +65 -0
- package/dist/requests/AttributesRequest.js.map +1 -0
- package/lib-web/nmshd.content.js +121 -1923
- package/lib-web/nmshd.content.min.js +1 -1
- package/package.json +7 -7
- package/dist/attributes/AbstractAttributeValue.d.ts +0 -9
- package/dist/attributes/AbstractAttributeValue.js +0 -8
- package/dist/attributes/AbstractAttributeValue.js.map +0 -1
- package/dist/attributes/index.d.ts +0 -3
- package/dist/attributes/index.js +0 -20
- package/dist/attributes/index.js.map +0 -1
- package/dist/attributes/types/AbstractDay.d.ts +0 -7
- package/dist/attributes/types/AbstractDay.js +0 -26
- package/dist/attributes/types/AbstractDay.js.map +0 -1
- package/dist/attributes/types/AbstractMonth.d.ts +0 -25
- package/dist/attributes/types/AbstractMonth.js +0 -44
- package/dist/attributes/types/AbstractMonth.js.map +0 -1
- package/dist/attributes/types/AbstractYear.d.ts +0 -4
- package/dist/attributes/types/AbstractYear.js +0 -23
- package/dist/attributes/types/AbstractYear.js.map +0 -1
- package/dist/attributes/types/AttributeList.d.ts +0 -1
- package/dist/attributes/types/AttributeList.js +0 -37
- package/dist/attributes/types/AttributeList.js.map +0 -1
- package/dist/attributes/types/AttributeTypeMapping.d.ts +0 -1
- package/dist/attributes/types/AttributeTypeMapping.js +0 -9
- package/dist/attributes/types/AttributeTypeMapping.js.map +0 -1
- package/dist/attributes/types/address/AbstractAddress.d.ts +0 -4
- package/dist/attributes/types/address/AbstractAddress.js +0 -23
- package/dist/attributes/types/address/AbstractAddress.js.map +0 -1
- package/dist/attributes/types/address/City.d.ts +0 -4
- package/dist/attributes/types/address/City.js +0 -26
- package/dist/attributes/types/address/City.js.map +0 -1
- package/dist/attributes/types/address/Country.d.ts +0 -4
- package/dist/attributes/types/address/Country.js +0 -26
- package/dist/attributes/types/address/Country.js.map +0 -1
- package/dist/attributes/types/address/DeliveryBoxAddress.d.ts +0 -13
- package/dist/attributes/types/address/DeliveryBoxAddress.js +0 -55
- package/dist/attributes/types/address/DeliveryBoxAddress.js.map +0 -1
- package/dist/attributes/types/address/HouseNumber.d.ts +0 -4
- package/dist/attributes/types/address/HouseNumber.js.map +0 -1
- package/dist/attributes/types/address/PostOfficeBoxAddress.d.ts +0 -12
- package/dist/attributes/types/address/PostOfficeBoxAddress.js +0 -50
- package/dist/attributes/types/address/PostOfficeBoxAddress.js.map +0 -1
- package/dist/attributes/types/address/State.d.ts +0 -4
- package/dist/attributes/types/address/State.js +0 -26
- package/dist/attributes/types/address/State.js.map +0 -1
- package/dist/attributes/types/address/Street.d.ts +0 -4
- package/dist/attributes/types/address/Street.js +0 -26
- package/dist/attributes/types/address/Street.js.map +0 -1
- package/dist/attributes/types/address/StreetAddress.d.ts +0 -15
- package/dist/attributes/types/address/StreetAddress.js +0 -57
- package/dist/attributes/types/address/StreetAddress.js.map +0 -1
- package/dist/attributes/types/address/ZipCode.d.ts +0 -4
- package/dist/attributes/types/address/ZipCode.js +0 -26
- package/dist/attributes/types/address/ZipCode.js.map +0 -1
- package/dist/attributes/types/address/index.d.ts +0 -10
- package/dist/attributes/types/address/index.js +0 -27
- package/dist/attributes/types/address/index.js.map +0 -1
- package/dist/attributes/types/birth/BirthCity.d.ts +0 -3
- package/dist/attributes/types/birth/BirthCity.js +0 -18
- package/dist/attributes/types/birth/BirthCity.js.map +0 -1
- package/dist/attributes/types/birth/BirthCountry.d.ts +0 -3
- package/dist/attributes/types/birth/BirthCountry.js +0 -18
- package/dist/attributes/types/birth/BirthCountry.js.map +0 -1
- package/dist/attributes/types/birth/BirthDate.d.ts +0 -9
- package/dist/attributes/types/birth/BirthDate.js +0 -39
- package/dist/attributes/types/birth/BirthDate.js.map +0 -1
- package/dist/attributes/types/birth/BirthDay.d.ts +0 -3
- package/dist/attributes/types/birth/BirthDay.js.map +0 -1
- package/dist/attributes/types/birth/BirthMonth.d.ts +0 -3
- package/dist/attributes/types/birth/BirthMonth.js +0 -18
- package/dist/attributes/types/birth/BirthMonth.js.map +0 -1
- package/dist/attributes/types/birth/BirthPlace.d.ts +0 -9
- package/dist/attributes/types/birth/BirthPlace.js +0 -39
- package/dist/attributes/types/birth/BirthPlace.js.map +0 -1
- package/dist/attributes/types/birth/BirthState.d.ts +0 -3
- package/dist/attributes/types/birth/BirthState.js +0 -18
- package/dist/attributes/types/birth/BirthState.js.map +0 -1
- package/dist/attributes/types/birth/BirthYear.d.ts +0 -3
- package/dist/attributes/types/birth/BirthYear.js +0 -18
- package/dist/attributes/types/birth/BirthYear.js.map +0 -1
- package/dist/attributes/types/birth/index.d.ts +0 -8
- package/dist/attributes/types/birth/index.js +0 -25
- package/dist/attributes/types/birth/index.js.map +0 -1
- package/dist/attributes/types/idcard/AbstractIDCard.d.ts +0 -3
- package/dist/attributes/types/idcard/AbstractIDCard.js +0 -8
- package/dist/attributes/types/idcard/AbstractIDCard.js.map +0 -1
- package/dist/attributes/types/idcard/IDCardAuthorityName.d.ts +0 -4
- package/dist/attributes/types/idcard/IDCardAuthorityName.js +0 -26
- package/dist/attributes/types/idcard/IDCardAuthorityName.js.map +0 -1
- package/dist/attributes/types/idcard/IDCardDE.d.ts +0 -11
- package/dist/attributes/types/idcard/IDCardDE.js +0 -45
- package/dist/attributes/types/idcard/IDCardDE.js.map +0 -1
- package/dist/attributes/types/idcard/IDCardIssuingDate.d.ts +0 -4
- package/dist/attributes/types/idcard/IDCardIssuingDate.js +0 -26
- package/dist/attributes/types/idcard/IDCardIssuingDate.js.map +0 -1
- package/dist/attributes/types/idcard/index.d.ts +0 -4
- package/dist/attributes/types/idcard/index.js +0 -21
- package/dist/attributes/types/idcard/index.js.map +0 -1
- package/dist/attributes/types/index.d.ts +0 -6
- package/dist/attributes/types/index.js +0 -23
- package/dist/attributes/types/index.js.map +0 -1
- package/dist/attributes/types/measurements/AbstractMeasurement.d.ts +0 -8
- package/dist/attributes/types/measurements/AbstractMeasurement.js +0 -31
- package/dist/attributes/types/measurements/AbstractMeasurement.js.map +0 -1
- package/dist/attributes/types/measurements/LengthMeasurement.d.ts +0 -18
- package/dist/attributes/types/measurements/LengthMeasurement.js +0 -43
- package/dist/attributes/types/measurements/LengthMeasurement.js.map +0 -1
- package/dist/attributes/types/measurements/index.d.ts +0 -1
- package/dist/attributes/types/measurements/index.js +0 -18
- package/dist/attributes/types/measurements/index.js.map +0 -1
- package/dist/attributes/types/name/AbstractLegalName.d.ts +0 -3
- package/dist/attributes/types/name/AbstractLegalName.js +0 -8
- package/dist/attributes/types/name/AbstractLegalName.js.map +0 -1
- package/dist/attributes/types/name/BirthName.d.ts +0 -4
- package/dist/attributes/types/name/BirthName.js +0 -26
- package/dist/attributes/types/name/BirthName.js.map +0 -1
- package/dist/attributes/types/name/DisplayName.d.ts +0 -4
- package/dist/attributes/types/name/DisplayName.js +0 -26
- package/dist/attributes/types/name/DisplayName.js.map +0 -1
- package/dist/attributes/types/name/GivenName.d.ts +0 -4
- package/dist/attributes/types/name/GivenName.js +0 -26
- package/dist/attributes/types/name/GivenName.js.map +0 -1
- package/dist/attributes/types/name/LegalNameDE.d.ts +0 -11
- package/dist/attributes/types/name/LegalNameDE.js +0 -45
- package/dist/attributes/types/name/LegalNameDE.js.map +0 -1
- package/dist/attributes/types/name/Pseudonym.d.ts +0 -4
- package/dist/attributes/types/name/Pseudonym.js +0 -26
- package/dist/attributes/types/name/Pseudonym.js.map +0 -1
- package/dist/attributes/types/name/Salutation.d.ts +0 -11
- package/dist/attributes/types/name/Salutation.js +0 -45
- package/dist/attributes/types/name/Salutation.js.map +0 -1
- package/dist/attributes/types/name/Surname.d.ts +0 -4
- package/dist/attributes/types/name/Surname.js +0 -26
- package/dist/attributes/types/name/Surname.js.map +0 -1
- package/dist/attributes/types/name/Title.d.ts +0 -4
- package/dist/attributes/types/name/Title.js +0 -26
- package/dist/attributes/types/name/Title.js.map +0 -1
- package/dist/attributes/types/name/index.d.ts +0 -9
- package/dist/attributes/types/name/index.js +0 -26
- package/dist/attributes/types/name/index.js.map +0 -1
- package/dist/attributes/types/person/Age.d.ts +0 -4
- package/dist/attributes/types/person/Age.js +0 -26
- package/dist/attributes/types/person/Age.js.map +0 -1
- package/dist/attributes/types/person/Gender.d.ts +0 -7
- package/dist/attributes/types/person/Gender.js +0 -29
- package/dist/attributes/types/person/Gender.js.map +0 -1
- package/dist/attributes/types/person/PersonEyeColor.d.ts +0 -4
- package/dist/attributes/types/person/PersonEyeColor.js +0 -26
- package/dist/attributes/types/person/PersonEyeColor.js.map +0 -1
- package/dist/attributes/types/person/PersonHeight.d.ts +0 -4
- package/dist/attributes/types/person/PersonHeight.js +0 -29
- package/dist/attributes/types/person/PersonHeight.js.map +0 -1
- package/dist/attributes/types/person/Sex.d.ts +0 -7
- package/dist/attributes/types/person/Sex.js +0 -29
- package/dist/attributes/types/person/Sex.js.map +0 -1
- package/dist/attributes/types/person/index.d.ts +0 -5
- package/dist/attributes/types/person/index.js +0 -22
- package/dist/attributes/types/person/index.js.map +0 -1
|
@@ -1,28 +1,24 @@
|
|
|
1
1
|
import { CoreDate, CoreSerializable, ICoreDate, ICoreSerializable } from "@nmshd/transport";
|
|
2
2
|
import { ContentJSON } from "../ContentJSON";
|
|
3
|
-
import { AbstractAttributeValue, AbstractAttributeValueJSON, IAbstractAttributeValue } from "./AbstractAttributeValue";
|
|
4
3
|
export interface AttributeJSON extends ContentJSON {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
tags?: string[];
|
|
4
|
+
name: string;
|
|
5
|
+
value: any;
|
|
8
6
|
validFrom?: string;
|
|
9
7
|
validTo?: string;
|
|
10
8
|
}
|
|
11
9
|
export interface IAttribute extends ICoreSerializable {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
tags?: string[] | undefined;
|
|
10
|
+
name: string;
|
|
11
|
+
value: any;
|
|
15
12
|
validFrom?: ICoreDate;
|
|
16
13
|
validTo?: ICoreDate;
|
|
17
14
|
}
|
|
18
15
|
export declare class Attribute extends CoreSerializable implements IAttribute {
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
content: AbstractAttributeValue;
|
|
22
|
-
createdAt: CoreDate;
|
|
23
|
-
tags?: string[];
|
|
16
|
+
name: string;
|
|
17
|
+
value: any;
|
|
24
18
|
validFrom?: CoreDate;
|
|
25
19
|
validTo?: CoreDate;
|
|
20
|
+
get namespace(): string | undefined;
|
|
21
|
+
get attribute(): string | undefined;
|
|
26
22
|
static from(value: IAttribute): Attribute;
|
|
27
|
-
static fromJSON(
|
|
23
|
+
static fromJSON(value: AttributeJSON): Attribute;
|
|
28
24
|
}
|
|
@@ -13,41 +13,43 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
13
13
|
exports.Attribute = void 0;
|
|
14
14
|
const ts_serval_1 = require("@js-soft/ts-serval");
|
|
15
15
|
const transport_1 = require("@nmshd/transport");
|
|
16
|
-
const ts_simple_nameof_1 = require("ts-simple-nameof");
|
|
17
|
-
const AbstractAttributeValue_1 = require("./AbstractAttributeValue");
|
|
18
16
|
let Attribute = Attribute_1 = class Attribute extends transport_1.CoreSerializable {
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
17
|
+
get namespace() {
|
|
18
|
+
if (!this.name)
|
|
19
|
+
return undefined;
|
|
20
|
+
const ar = this.name.split(".");
|
|
21
|
+
if (ar.length <= 1)
|
|
22
|
+
return undefined;
|
|
23
|
+
return ar[0];
|
|
24
|
+
}
|
|
25
|
+
get attribute() {
|
|
26
|
+
if (!this.name)
|
|
27
|
+
return undefined;
|
|
28
|
+
const ar = this.name.split(".");
|
|
29
|
+
return ar.pop();
|
|
28
30
|
}
|
|
29
31
|
static from(value) {
|
|
30
|
-
return super.
|
|
32
|
+
return super.from(value, Attribute_1);
|
|
31
33
|
}
|
|
32
|
-
static fromJSON(
|
|
33
|
-
return
|
|
34
|
+
static fromJSON(value) {
|
|
35
|
+
return this.from({
|
|
36
|
+
name: value.name,
|
|
37
|
+
value: value.value,
|
|
38
|
+
validFrom: value.validFrom ? transport_1.CoreDate.from(value.validFrom) : undefined,
|
|
39
|
+
validTo: value.validTo ? transport_1.CoreDate.from(value.validTo) : undefined
|
|
40
|
+
});
|
|
34
41
|
}
|
|
35
42
|
};
|
|
36
43
|
__decorate([
|
|
37
|
-
(0, ts_serval_1.validate)(),
|
|
38
44
|
(0, ts_serval_1.serialize)(),
|
|
39
|
-
__metadata("design:type", AbstractAttributeValue_1.AbstractAttributeValue)
|
|
40
|
-
], Attribute.prototype, "content", void 0);
|
|
41
|
-
__decorate([
|
|
42
45
|
(0, ts_serval_1.validate)(),
|
|
43
|
-
(
|
|
44
|
-
|
|
45
|
-
], Attribute.prototype, "createdAt", void 0);
|
|
46
|
+
__metadata("design:type", String)
|
|
47
|
+
], Attribute.prototype, "name", void 0);
|
|
46
48
|
__decorate([
|
|
47
|
-
(0, ts_serval_1.serialize)({
|
|
49
|
+
(0, ts_serval_1.serialize)({ any: true }),
|
|
48
50
|
(0, ts_serval_1.validate)({ nullable: true }),
|
|
49
|
-
__metadata("design:type",
|
|
50
|
-
], Attribute.prototype, "
|
|
51
|
+
__metadata("design:type", Object)
|
|
52
|
+
], Attribute.prototype, "value", void 0);
|
|
51
53
|
__decorate([
|
|
52
54
|
(0, ts_serval_1.serialize)(),
|
|
53
55
|
(0, ts_serval_1.validate)({ nullable: true }),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Attribute.js","sourceRoot":"","sources":["../../src/attributes/Attribute.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,kDAA8D;AAC9D,gDAA2F;
|
|
1
|
+
{"version":3,"file":"Attribute.js","sourceRoot":"","sources":["../../src/attributes/Attribute.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,kDAA8D;AAC9D,gDAA2F;AAkB3F,IAAa,SAAS,iBAAtB,MAAa,SAAU,SAAQ,4BAAgB;IAiB3C,IAAW,SAAS;QAChB,IAAI,CAAC,IAAI,CAAC,IAAI;YAAE,OAAO,SAAS,CAAA;QAChC,MAAM,EAAE,GAAG,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAA;QAC/B,IAAI,EAAE,CAAC,MAAM,IAAI,CAAC;YAAE,OAAO,SAAS,CAAA;QACpC,OAAO,EAAE,CAAC,CAAC,CAAC,CAAA;IAChB,CAAC;IAED,IAAW,SAAS;QAChB,IAAI,CAAC,IAAI,CAAC,IAAI;YAAE,OAAO,SAAS,CAAA;QAChC,MAAM,EAAE,GAAG,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAA;QAC/B,OAAO,EAAE,CAAC,GAAG,EAAE,CAAA;IACnB,CAAC;IAEM,MAAM,CAAC,IAAI,CAAC,KAAiB;QAChC,OAAO,KAAK,CAAC,IAAI,CAAC,KAAK,EAAE,WAAS,CAAc,CAAA;IACpD,CAAC;IAEM,MAAM,CAAC,QAAQ,CAAC,KAAoB;QACvC,OAAO,IAAI,CAAC,IAAI,CAAC;YACb,IAAI,EAAE,KAAK,CAAC,IAAI;YAChB,KAAK,EAAE,KAAK,CAAC,KAAK;YAClB,SAAS,EAAE,KAAK,CAAC,SAAS,CAAC,CAAC,CAAC,oBAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,SAAS;YACvE,OAAO,EAAE,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,oBAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,SAAS;SACpE,CAAC,CAAA;IACN,CAAC;CACJ,CAAA;AAvCG;IAFC,IAAA,qBAAS,GAAE;IACX,IAAA,oBAAQ,GAAE;;uCACQ;AAInB;IAFC,IAAA,qBAAS,EAAC,EAAE,GAAG,EAAE,IAAI,EAAE,CAAC;IACxB,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;wCACZ;AAIjB;IAFC,IAAA,qBAAS,GAAE;IACX,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;8BACV,oBAAQ;4CAAA;AAI3B;IAFC,IAAA,qBAAS,GAAE;IACX,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;8BACZ,oBAAQ;0CAAA;AAfhB,SAAS;IADrB,IAAA,gBAAI,EAAC,WAAW,CAAC;GACL,SAAS,CA0CrB;AA1CY,8BAAS"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Serializable } from "@js-soft/ts-serval";
|
|
2
|
+
export interface IAttributeName {
|
|
3
|
+
name: string;
|
|
4
|
+
}
|
|
5
|
+
export declare class AttributeName extends Serializable implements IAttributeName {
|
|
6
|
+
set name(value: string);
|
|
7
|
+
get name(): string;
|
|
8
|
+
protected _name: string;
|
|
9
|
+
constructor(name: string);
|
|
10
|
+
protected checkName(name: string, throwError?: boolean): Error | null;
|
|
11
|
+
static from(value: any): AttributeName;
|
|
12
|
+
static deserialize(value: string): AttributeName;
|
|
13
|
+
toString(): string;
|
|
14
|
+
serialize(): string;
|
|
15
|
+
toJSON(): string;
|
|
16
|
+
}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
var AttributeName_1;
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
exports.AttributeName = void 0;
|
|
14
|
+
const ts_serval_1 = require("@js-soft/ts-serval");
|
|
15
|
+
let AttributeName = AttributeName_1 = class AttributeName extends ts_serval_1.Serializable {
|
|
16
|
+
constructor(name) {
|
|
17
|
+
super();
|
|
18
|
+
this.checkName(name);
|
|
19
|
+
this._name = name;
|
|
20
|
+
}
|
|
21
|
+
set name(value) {
|
|
22
|
+
this.checkName(value);
|
|
23
|
+
this._name = value;
|
|
24
|
+
}
|
|
25
|
+
get name() {
|
|
26
|
+
return this._name;
|
|
27
|
+
}
|
|
28
|
+
checkName(name, throwError = true) {
|
|
29
|
+
let err;
|
|
30
|
+
if (!name) {
|
|
31
|
+
err = new Error("error.content.attribute.nameMustBeSet");
|
|
32
|
+
}
|
|
33
|
+
if (err && throwError) {
|
|
34
|
+
throw err;
|
|
35
|
+
}
|
|
36
|
+
return null;
|
|
37
|
+
}
|
|
38
|
+
static from(value) {
|
|
39
|
+
if (typeof value === "string") {
|
|
40
|
+
return new AttributeName_1(value);
|
|
41
|
+
}
|
|
42
|
+
return new AttributeName_1(value.name);
|
|
43
|
+
}
|
|
44
|
+
static deserialize(value) {
|
|
45
|
+
return new AttributeName_1(value);
|
|
46
|
+
}
|
|
47
|
+
toString() {
|
|
48
|
+
return this._name;
|
|
49
|
+
}
|
|
50
|
+
serialize() {
|
|
51
|
+
return this._name;
|
|
52
|
+
}
|
|
53
|
+
toJSON() {
|
|
54
|
+
return this._name;
|
|
55
|
+
}
|
|
56
|
+
};
|
|
57
|
+
AttributeName = AttributeName_1 = __decorate([
|
|
58
|
+
(0, ts_serval_1.type)("AttributeName"),
|
|
59
|
+
__metadata("design:paramtypes", [String])
|
|
60
|
+
], AttributeName);
|
|
61
|
+
exports.AttributeName = AttributeName;
|
|
62
|
+
//# sourceMappingURL=AttributeName.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AttributeName.js","sourceRoot":"","sources":["../../src/attributes/AttributeName.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,kDAAuD;AAOvD,IAAa,aAAa,qBAA1B,MAAa,aAAc,SAAQ,wBAAY;IAU3C,YAAmB,IAAY;QAC3B,KAAK,EAAE,CAAA;QACP,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,CAAA;QACpB,IAAI,CAAC,KAAK,GAAG,IAAI,CAAA;IACrB,CAAC;IAbD,IAAW,IAAI,CAAC,KAAa;QACzB,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,CAAA;QACrB,IAAI,CAAC,KAAK,GAAG,KAAK,CAAA;IACtB,CAAC;IACD,IAAW,IAAI;QACX,OAAO,IAAI,CAAC,KAAK,CAAA;IACrB,CAAC;IASS,SAAS,CAAC,IAAY,EAAE,UAAU,GAAG,IAAI;QAC/C,IAAI,GAAG,CAAA;QACP,IAAI,CAAC,IAAI,EAAE;YACP,GAAG,GAAG,IAAI,KAAK,CAAC,uCAAuC,CAAC,CAAA;SAC3D;QACD,IAAI,GAAG,IAAI,UAAU,EAAE;YACnB,MAAM,GAAG,CAAA;SACZ;QACD,OAAO,IAAI,CAAA;IACf,CAAC;IAEM,MAAM,CAAC,IAAI,CAAC,KAAU;QACzB,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;YAC3B,OAAO,IAAI,eAAa,CAAC,KAAK,CAAC,CAAA;SAClC;QAED,OAAO,IAAI,eAAa,CAAC,KAAK,CAAC,IAAI,CAAC,CAAA;IACxC,CAAC;IAEM,MAAM,CAAC,WAAW,CAAC,KAAa;QACnC,OAAO,IAAI,eAAa,CAAC,KAAK,CAAC,CAAA;IACnC,CAAC;IAEM,QAAQ;QACX,OAAO,IAAI,CAAC,KAAK,CAAA;IACrB,CAAC;IACM,SAAS;QACZ,OAAO,IAAI,CAAC,KAAK,CAAA;IACrB,CAAC;IACM,MAAM;QACT,OAAO,IAAI,CAAC,KAAK,CAAA;IACrB,CAAC;CACJ,CAAA;AAhDY,aAAa;IADzB,IAAA,gBAAI,EAAC,eAAe,CAAC;;GACT,aAAa,CAgDzB;AAhDY,sCAAa"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AttributeNamespaces = void 0;
|
|
4
|
+
var AttributeNamespaces;
|
|
5
|
+
(function (AttributeNamespaces) {
|
|
6
|
+
AttributeNamespaces[AttributeNamespaces["Person"] = 0] = "Person";
|
|
7
|
+
AttributeNamespaces[AttributeNamespaces["Thing"] = 1] = "Thing";
|
|
8
|
+
AttributeNamespaces[AttributeNamespaces["Address"] = 2] = "Address";
|
|
9
|
+
AttributeNamespaces[AttributeNamespaces["Payment"] = 3] = "Payment";
|
|
10
|
+
AttributeNamespaces[AttributeNamespaces["Communication"] = 4] = "Communication";
|
|
11
|
+
AttributeNamespaces[AttributeNamespaces["Corporation"] = 5] = "Corporation";
|
|
12
|
+
})(AttributeNamespaces = exports.AttributeNamespaces || (exports.AttributeNamespaces = {}));
|
|
13
|
+
//# sourceMappingURL=AttributeNamespace.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AttributeNamespace.js","sourceRoot":"","sources":["../../src/attributes/AttributeNamespace.ts"],"names":[],"mappings":";;;AAAA,IAAY,mBAOX;AAPD,WAAY,mBAAmB;IAC3B,iEAAQ,CAAA;IACR,+DAAO,CAAA;IACP,mEAAS,CAAA;IACT,mEAAS,CAAA;IACT,+EAAe,CAAA;IACf,2EAAa,CAAA;AACjB,CAAC,EAPW,mBAAmB,GAAnB,2BAAmB,KAAnB,2BAAmB,QAO9B"}
|
package/dist/buildInformation.js
CHANGED
|
@@ -5,10 +5,10 @@ const ts_serval_1 = require("@js-soft/ts-serval");
|
|
|
5
5
|
const crypto_1 = require("@nmshd/crypto");
|
|
6
6
|
const transport_1 = require("@nmshd/transport");
|
|
7
7
|
exports.buildInformation = {
|
|
8
|
-
version: "
|
|
9
|
-
build: "
|
|
10
|
-
date: "2022-03-
|
|
11
|
-
commit: "
|
|
8
|
+
version: "2.0.0-alpha.1",
|
|
9
|
+
build: "17",
|
|
10
|
+
date: "2022-03-21T11:25:06+00:00",
|
|
11
|
+
commit: "b34e617b64f951607047c86733d19f2cac3e4119",
|
|
12
12
|
dependencies: {"@js-soft/logging-abstractions":"^1.0.0"},
|
|
13
13
|
libraries: {
|
|
14
14
|
serval: ts_serval_1.buildInformation,
|
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
export * from "./attributes";
|
|
1
|
+
export * from "./attributes/Attribute";
|
|
2
|
+
export * from "./attributes/AttributeName";
|
|
3
|
+
export * from "./attributes/AttributeNamespace";
|
|
2
4
|
export * from "./authorizations/Authorization";
|
|
3
5
|
export * from "./buildInformation";
|
|
4
6
|
export * from "./ContentJSON";
|
package/dist/index.js
CHANGED
|
@@ -14,7 +14,9 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./attributes"), exports);
|
|
17
|
+
__exportStar(require("./attributes/Attribute"), exports);
|
|
18
|
+
__exportStar(require("./attributes/AttributeName"), exports);
|
|
19
|
+
__exportStar(require("./attributes/AttributeNamespace"), exports);
|
|
18
20
|
__exportStar(require("./authorizations/Authorization"), exports);
|
|
19
21
|
__exportStar(require("./buildInformation"), exports);
|
|
20
22
|
__exportStar(require("./ContentJSON"), exports);
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,yDAAsC;AACtC,6DAA0C;AAC1C,kEAA+C;AAC/C,iEAA8C;AAC9C,qDAAkC;AAClC,gDAA6B;AAC7B,0CAAuB;AACvB,kDAA+B;AAC/B,yDAAsC;AACtC,qEAAkD;AAClD,oEAAiD"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { ISerializableAsync, SerializableAsync } from "@js-soft/ts-serval";
|
|
2
|
+
import { Attribute, AttributeJSON, IAttribute } from "../attributes/Attribute";
|
|
3
|
+
import { Authorization, AuthorizationJSON, IAuthorization } from "../authorizations/Authorization";
|
|
4
|
+
import { ContentJSON } from "../ContentJSON";
|
|
5
|
+
export interface RelationshipCreationChangeRequestBodyJSON extends ContentJSON {
|
|
6
|
+
title?: string;
|
|
7
|
+
sessionIdentifier?: string;
|
|
8
|
+
metadata?: any;
|
|
9
|
+
sharedAttributes?: AttributeJSON[];
|
|
10
|
+
sharedCertificates?: any[];
|
|
11
|
+
sharedAuthorizations?: AuthorizationJSON[];
|
|
12
|
+
}
|
|
13
|
+
export interface IRelationshipCreationChangeRequestBody extends ISerializableAsync {
|
|
14
|
+
title?: string;
|
|
15
|
+
sessionIdentifier?: string;
|
|
16
|
+
metadata?: any;
|
|
17
|
+
sharedAttributes?: IAttribute[];
|
|
18
|
+
sharedCertificates?: any[];
|
|
19
|
+
sharedAuthorizations?: IAuthorization[];
|
|
20
|
+
}
|
|
21
|
+
export declare class RelationshipCreationChangeRequestBody extends SerializableAsync implements IRelationshipCreationChangeRequestBody {
|
|
22
|
+
title?: string;
|
|
23
|
+
sessionIdentifier?: string;
|
|
24
|
+
metadata?: any;
|
|
25
|
+
sharedAttributes?: Attribute[];
|
|
26
|
+
sharedCertificates?: any[];
|
|
27
|
+
sharedAuthorizations?: Authorization[];
|
|
28
|
+
static from(value: IRelationshipCreationChangeRequestBody): Promise<RelationshipCreationChangeRequestBody>;
|
|
29
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
var RelationshipCreationChangeRequestBody_1;
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
exports.RelationshipCreationChangeRequestBody = void 0;
|
|
14
|
+
const ts_serval_1 = require("@js-soft/ts-serval");
|
|
15
|
+
const Attribute_1 = require("../attributes/Attribute");
|
|
16
|
+
const Authorization_1 = require("../authorizations/Authorization");
|
|
17
|
+
let RelationshipCreationChangeRequestBody = RelationshipCreationChangeRequestBody_1 = class RelationshipCreationChangeRequestBody extends ts_serval_1.SerializableAsync {
|
|
18
|
+
static async from(value) {
|
|
19
|
+
return (await super.from(value, RelationshipCreationChangeRequestBody_1));
|
|
20
|
+
}
|
|
21
|
+
};
|
|
22
|
+
__decorate([
|
|
23
|
+
(0, ts_serval_1.serialize)(),
|
|
24
|
+
(0, ts_serval_1.validate)({ nullable: true }),
|
|
25
|
+
__metadata("design:type", String)
|
|
26
|
+
], RelationshipCreationChangeRequestBody.prototype, "title", void 0);
|
|
27
|
+
__decorate([
|
|
28
|
+
(0, ts_serval_1.serialize)(),
|
|
29
|
+
(0, ts_serval_1.validate)({ nullable: true }),
|
|
30
|
+
__metadata("design:type", String)
|
|
31
|
+
], RelationshipCreationChangeRequestBody.prototype, "sessionIdentifier", void 0);
|
|
32
|
+
__decorate([
|
|
33
|
+
(0, ts_serval_1.serialize)({ any: true }),
|
|
34
|
+
(0, ts_serval_1.validate)({ nullable: true }),
|
|
35
|
+
__metadata("design:type", Object)
|
|
36
|
+
], RelationshipCreationChangeRequestBody.prototype, "metadata", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
(0, ts_serval_1.serialize)({ type: Attribute_1.Attribute }),
|
|
39
|
+
(0, ts_serval_1.validate)({ nullable: true }),
|
|
40
|
+
__metadata("design:type", Array)
|
|
41
|
+
], RelationshipCreationChangeRequestBody.prototype, "sharedAttributes", void 0);
|
|
42
|
+
__decorate([
|
|
43
|
+
(0, ts_serval_1.serialize)(),
|
|
44
|
+
(0, ts_serval_1.validate)({ nullable: true }),
|
|
45
|
+
__metadata("design:type", Array)
|
|
46
|
+
], RelationshipCreationChangeRequestBody.prototype, "sharedCertificates", void 0);
|
|
47
|
+
__decorate([
|
|
48
|
+
(0, ts_serval_1.serialize)({ type: Authorization_1.Authorization }),
|
|
49
|
+
(0, ts_serval_1.validate)({ nullable: true }),
|
|
50
|
+
__metadata("design:type", Array)
|
|
51
|
+
], RelationshipCreationChangeRequestBody.prototype, "sharedAuthorizations", void 0);
|
|
52
|
+
RelationshipCreationChangeRequestBody = RelationshipCreationChangeRequestBody_1 = __decorate([
|
|
53
|
+
(0, ts_serval_1.type)("RelationshipCreationChangeRequestBody")
|
|
54
|
+
], RelationshipCreationChangeRequestBody);
|
|
55
|
+
exports.RelationshipCreationChangeRequestBody = RelationshipCreationChangeRequestBody;
|
|
56
|
+
//# sourceMappingURL=RelationshipCreationChangeRequestBody.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RelationshipCreationChangeRequestBody.js","sourceRoot":"","sources":["../../src/relationships/RelationshipCreationChangeRequestBody.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,kDAAqG;AACrG,uDAA8E;AAC9E,mEAAkG;AAsBlG,IAAa,qCAAqC,6CAAlD,MAAa,qCACT,SAAQ,6BAAiB;IA2BlB,MAAM,CAAC,KAAK,CAAC,IAAI,CACpB,KAA6C;QAE7C,OAAO,CAAC,MAAM,KAAK,CAAC,IAAI,CAAC,KAAK,EAAE,uCAAqC,CAAC,CAA0C,CAAA;IACpH,CAAC;CACJ,CAAA;AA3BG;IAFC,IAAA,qBAAS,GAAE;IACX,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;oEACR;AAIrB;IAFC,IAAA,qBAAS,GAAE;IACX,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;gFACI;AAIjC;IAFC,IAAA,qBAAS,EAAC,EAAE,GAAG,EAAE,IAAI,EAAE,CAAC;IACxB,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;uEACR;AAIrB;IAFC,IAAA,qBAAS,EAAC,EAAE,IAAI,EAAE,qBAAS,EAAE,CAAC;IAC9B,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;+EACQ;AAIrC;IAFC,IAAA,qBAAS,GAAE;IACX,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;iFACI;AAIjC;IAFC,IAAA,qBAAS,EAAC,EAAE,IAAI,EAAE,6BAAa,EAAE,CAAC;IAClC,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;mFACgB;AA1BpC,qCAAqC;IADjD,IAAA,gBAAI,EAAC,uCAAuC,CAAC;GACjC,qCAAqC,CAiCjD;AAjCY,sFAAqC"}
|
|
File without changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RelationshipCreationChangeResponseBody.js","sourceRoot":"","sources":["../../src/relationships/RelationshipCreationChangeResponseBody.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Serializable } from "@js-soft/ts-serval";
|
|
2
|
+
export interface RelationshipExistsActionJSON {
|
|
3
|
+
}
|
|
4
|
+
export interface IRelationshipExistsAction {
|
|
5
|
+
}
|
|
6
|
+
export declare abstract class RelationshipExistsAction extends Serializable implements IRelationshipExistsAction {
|
|
7
|
+
}
|
package/dist/{attributes/types/birth/BirthDay.js → relationships/RelationshipExistsAction.js}
RENAMED
|
@@ -6,13 +6,12 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
6
6
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
7
|
};
|
|
8
8
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
-
exports.
|
|
9
|
+
exports.RelationshipExistsAction = void 0;
|
|
10
10
|
const ts_serval_1 = require("@js-soft/ts-serval");
|
|
11
|
-
|
|
12
|
-
let BirthDay = class BirthDay extends AbstractDay_1.AbstractDay {
|
|
11
|
+
let RelationshipExistsAction = class RelationshipExistsAction extends ts_serval_1.Serializable {
|
|
13
12
|
};
|
|
14
|
-
|
|
15
|
-
(0, ts_serval_1.type)("
|
|
16
|
-
],
|
|
17
|
-
exports.
|
|
18
|
-
//# sourceMappingURL=
|
|
13
|
+
RelationshipExistsAction = __decorate([
|
|
14
|
+
(0, ts_serval_1.type)("RelationshipExistsAction")
|
|
15
|
+
], RelationshipExistsAction);
|
|
16
|
+
exports.RelationshipExistsAction = RelationshipExistsAction;
|
|
17
|
+
//# sourceMappingURL=RelationshipExistsAction.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RelationshipExistsAction.js","sourceRoot":"","sources":["../../src/relationships/RelationshipExistsAction.ts"],"names":[],"mappings":";;;;;;;;;AAAA,kDAAuD;AAOvD,IAAsB,wBAAwB,GAA9C,MAAsB,wBAAyB,SAAQ,wBAAY;CAAwC,CAAA;AAArF,wBAAwB;IAD7C,IAAA,gBAAI,EAAC,0BAA0B,CAAC;GACX,wBAAwB,CAA6D;AAArF,4DAAwB"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ISerializableAsync, SerializableAsync } from "@js-soft/ts-serval";
|
|
2
|
+
import { IRelationshipExistsAction, RelationshipExistsAction, RelationshipExistsActionJSON } from "./RelationshipExistsAction";
|
|
3
|
+
export interface RelationshipExistsMessageActionJSON extends RelationshipExistsActionJSON {
|
|
4
|
+
content: any;
|
|
5
|
+
}
|
|
6
|
+
export interface IRelationshipExistsMessageAction extends IRelationshipExistsAction {
|
|
7
|
+
content: ISerializableAsync;
|
|
8
|
+
}
|
|
9
|
+
export declare class RelationshipExistsMessageAction extends RelationshipExistsAction implements IRelationshipExistsMessageAction {
|
|
10
|
+
content: SerializableAsync;
|
|
11
|
+
}
|
|
@@ -9,18 +9,18 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.
|
|
12
|
+
exports.RelationshipExistsMessageAction = void 0;
|
|
13
13
|
const ts_serval_1 = require("@js-soft/ts-serval");
|
|
14
|
-
const
|
|
15
|
-
let
|
|
14
|
+
const RelationshipExistsAction_1 = require("./RelationshipExistsAction");
|
|
15
|
+
let RelationshipExistsMessageAction = class RelationshipExistsMessageAction extends RelationshipExistsAction_1.RelationshipExistsAction {
|
|
16
16
|
};
|
|
17
17
|
__decorate([
|
|
18
18
|
(0, ts_serval_1.serialize)(),
|
|
19
19
|
(0, ts_serval_1.validate)(),
|
|
20
|
-
__metadata("design:type",
|
|
21
|
-
],
|
|
22
|
-
|
|
23
|
-
(0, ts_serval_1.type)("
|
|
24
|
-
],
|
|
25
|
-
exports.
|
|
26
|
-
//# sourceMappingURL=
|
|
20
|
+
__metadata("design:type", ts_serval_1.SerializableAsync)
|
|
21
|
+
], RelationshipExistsMessageAction.prototype, "content", void 0);
|
|
22
|
+
RelationshipExistsMessageAction = __decorate([
|
|
23
|
+
(0, ts_serval_1.type)("RelationshipExistsMessageAction")
|
|
24
|
+
], RelationshipExistsMessageAction);
|
|
25
|
+
exports.RelationshipExistsMessageAction = RelationshipExistsMessageAction;
|
|
26
|
+
//# sourceMappingURL=RelationshipExistsMessageAction.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RelationshipExistsMessageAction.js","sourceRoot":"","sources":["../../src/relationships/RelationshipExistsMessageAction.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,kDAAqG;AACrG,yEAImC;AAWnC,IAAa,+BAA+B,GAA5C,MAAa,+BACT,SAAQ,mDAAwB;CAMnC,CAAA;AADG;IAFC,IAAA,qBAAS,GAAE;IACX,IAAA,oBAAQ,GAAE;8BACK,6BAAiB;gEAAA;AANxB,+BAA+B;IAD3C,IAAA,gBAAI,EAAC,iCAAiC,CAAC;GAC3B,+BAA+B,CAO3C;AAPY,0EAA+B"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { ISerializableAsync, SerializableAsync } from "@js-soft/ts-serval";
|
|
2
|
+
import { Attribute, AttributeJSON, IAttribute } from "../attributes/Attribute";
|
|
3
|
+
import { Authorization, AuthorizationJSON, IAuthorization } from "../authorizations/Authorization";
|
|
4
|
+
import { ContentJSON } from "../ContentJSON";
|
|
5
|
+
import { AttributesChangeRequest, AttributesChangeRequestJSON, IAttributesChangeRequest } from "../requests/AttributesChangeRequest";
|
|
6
|
+
import { AttributesRequest, AttributesRequestJSON, IAttributesRequest } from "../requests/AttributesRequest";
|
|
7
|
+
import { IRelationshipExistsAction, RelationshipExistsAction, RelationshipExistsActionJSON } from "./RelationshipExistsAction";
|
|
8
|
+
export interface RelationshipTemplateBodyJSON extends ContentJSON {
|
|
9
|
+
title?: string;
|
|
10
|
+
sessionIdentifier?: string;
|
|
11
|
+
metadata?: any;
|
|
12
|
+
sharedAttributes?: AttributeJSON[];
|
|
13
|
+
sharedCertificates?: any[];
|
|
14
|
+
sharedAuthorizations?: AuthorizationJSON[];
|
|
15
|
+
requestedAttributesChanges?: AttributesChangeRequestJSON[];
|
|
16
|
+
requestedAttributes?: AttributesRequestJSON[];
|
|
17
|
+
requestedCertificates?: any[];
|
|
18
|
+
relationshipExistsAction?: RelationshipExistsActionJSON;
|
|
19
|
+
}
|
|
20
|
+
export interface IRelationshipTemplateBody extends ISerializableAsync {
|
|
21
|
+
title?: string;
|
|
22
|
+
sessionIdentifier?: string;
|
|
23
|
+
metadata?: any;
|
|
24
|
+
sharedAttributes?: IAttribute[];
|
|
25
|
+
sharedCertificates?: any[];
|
|
26
|
+
sharedAuthorizations?: IAuthorization[];
|
|
27
|
+
requestedAttributesChanges?: IAttributesChangeRequest[];
|
|
28
|
+
requestedAttributes?: IAttributesRequest[];
|
|
29
|
+
relationshipExistsAction?: IRelationshipExistsAction;
|
|
30
|
+
}
|
|
31
|
+
export declare class RelationshipTemplateBody extends SerializableAsync implements IRelationshipTemplateBody {
|
|
32
|
+
title?: string;
|
|
33
|
+
sessionIdentifier?: string;
|
|
34
|
+
metadata?: any;
|
|
35
|
+
sharedAttributes?: Attribute[];
|
|
36
|
+
sharedCertificates?: any[];
|
|
37
|
+
sharedAuthorizations?: Authorization[];
|
|
38
|
+
requestedAttributesChanges?: AttributesChangeRequest[];
|
|
39
|
+
requestedAttributes?: AttributesRequest[];
|
|
40
|
+
relationshipExistsAction?: RelationshipExistsAction;
|
|
41
|
+
static from(value: IRelationshipTemplateBody): Promise<RelationshipTemplateBody>;
|
|
42
|
+
}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
var RelationshipTemplateBody_1;
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
exports.RelationshipTemplateBody = void 0;
|
|
14
|
+
const ts_serval_1 = require("@js-soft/ts-serval");
|
|
15
|
+
const Attribute_1 = require("../attributes/Attribute");
|
|
16
|
+
const Authorization_1 = require("../authorizations/Authorization");
|
|
17
|
+
const AttributesRequest_1 = require("../requests/AttributesRequest");
|
|
18
|
+
const RelationshipExistsAction_1 = require("./RelationshipExistsAction");
|
|
19
|
+
let RelationshipTemplateBody = RelationshipTemplateBody_1 = class RelationshipTemplateBody extends ts_serval_1.SerializableAsync {
|
|
20
|
+
static async from(value) {
|
|
21
|
+
return (await super.from(value, RelationshipTemplateBody_1));
|
|
22
|
+
}
|
|
23
|
+
};
|
|
24
|
+
__decorate([
|
|
25
|
+
(0, ts_serval_1.serialize)(),
|
|
26
|
+
(0, ts_serval_1.validate)({ nullable: true }),
|
|
27
|
+
__metadata("design:type", String)
|
|
28
|
+
], RelationshipTemplateBody.prototype, "title", void 0);
|
|
29
|
+
__decorate([
|
|
30
|
+
(0, ts_serval_1.serialize)(),
|
|
31
|
+
(0, ts_serval_1.validate)({ nullable: true }),
|
|
32
|
+
__metadata("design:type", String)
|
|
33
|
+
], RelationshipTemplateBody.prototype, "sessionIdentifier", void 0);
|
|
34
|
+
__decorate([
|
|
35
|
+
(0, ts_serval_1.serialize)({ any: true }),
|
|
36
|
+
(0, ts_serval_1.validate)({ nullable: true }),
|
|
37
|
+
__metadata("design:type", Object)
|
|
38
|
+
], RelationshipTemplateBody.prototype, "metadata", void 0);
|
|
39
|
+
__decorate([
|
|
40
|
+
(0, ts_serval_1.serialize)({ type: Attribute_1.Attribute }),
|
|
41
|
+
(0, ts_serval_1.validate)({ nullable: true }),
|
|
42
|
+
__metadata("design:type", Array)
|
|
43
|
+
], RelationshipTemplateBody.prototype, "sharedAttributes", void 0);
|
|
44
|
+
__decorate([
|
|
45
|
+
(0, ts_serval_1.serialize)(),
|
|
46
|
+
(0, ts_serval_1.validate)({ nullable: true }),
|
|
47
|
+
__metadata("design:type", Array)
|
|
48
|
+
], RelationshipTemplateBody.prototype, "sharedCertificates", void 0);
|
|
49
|
+
__decorate([
|
|
50
|
+
(0, ts_serval_1.serialize)({ type: Authorization_1.Authorization }),
|
|
51
|
+
(0, ts_serval_1.validate)({ nullable: true }),
|
|
52
|
+
__metadata("design:type", Array)
|
|
53
|
+
], RelationshipTemplateBody.prototype, "sharedAuthorizations", void 0);
|
|
54
|
+
__decorate([
|
|
55
|
+
(0, ts_serval_1.serialize)({ type: Attribute_1.Attribute }),
|
|
56
|
+
(0, ts_serval_1.validate)({ nullable: true }),
|
|
57
|
+
__metadata("design:type", Array)
|
|
58
|
+
], RelationshipTemplateBody.prototype, "requestedAttributesChanges", void 0);
|
|
59
|
+
__decorate([
|
|
60
|
+
(0, ts_serval_1.serialize)({ type: AttributesRequest_1.AttributesRequest }),
|
|
61
|
+
(0, ts_serval_1.validate)({ nullable: true }),
|
|
62
|
+
__metadata("design:type", Array)
|
|
63
|
+
], RelationshipTemplateBody.prototype, "requestedAttributes", void 0);
|
|
64
|
+
__decorate([
|
|
65
|
+
(0, ts_serval_1.serialize)(),
|
|
66
|
+
(0, ts_serval_1.validate)({ nullable: true }),
|
|
67
|
+
__metadata("design:type", RelationshipExistsAction_1.RelationshipExistsAction)
|
|
68
|
+
], RelationshipTemplateBody.prototype, "relationshipExistsAction", void 0);
|
|
69
|
+
RelationshipTemplateBody = RelationshipTemplateBody_1 = __decorate([
|
|
70
|
+
(0, ts_serval_1.type)("RelationshipTemplateBody")
|
|
71
|
+
], RelationshipTemplateBody);
|
|
72
|
+
exports.RelationshipTemplateBody = RelationshipTemplateBody;
|
|
73
|
+
//# sourceMappingURL=RelationshipTemplateBody.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RelationshipTemplateBody.js","sourceRoot":"","sources":["../../src/relationships/RelationshipTemplateBody.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,kDAAqG;AACrG,uDAA8E;AAC9E,mEAAkG;AAOlG,qEAA4G;AAC5G,yEAImC;AA4BnC,IAAa,wBAAwB,gCAArC,MAAa,wBAAyB,SAAQ,6BAAiB;IAqCpD,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,KAAgC;QACrD,OAAO,CAAC,MAAM,KAAK,CAAC,IAAI,CAAC,KAAK,EAAE,0BAAwB,CAAC,CAA6B,CAAA;IAC1F,CAAC;CACJ,CAAA;AArCG;IAFC,IAAA,qBAAS,GAAE;IACX,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;uDACR;AAIrB;IAFC,IAAA,qBAAS,GAAE;IACX,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;mEACI;AAIjC;IAFC,IAAA,qBAAS,EAAC,EAAE,GAAG,EAAE,IAAI,EAAE,CAAC;IACxB,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;0DACR;AAIrB;IAFC,IAAA,qBAAS,EAAC,EAAE,IAAI,EAAE,qBAAS,EAAE,CAAC;IAC9B,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;kEACQ;AAIrC;IAFC,IAAA,qBAAS,GAAE;IACX,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;oEACI;AAIjC;IAFC,IAAA,qBAAS,EAAC,EAAE,IAAI,EAAE,6BAAa,EAAE,CAAC;IAClC,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;sEACgB;AAI7C;IAFC,IAAA,qBAAS,EAAC,EAAE,IAAI,EAAE,qBAAS,EAAE,CAAC;IAC9B,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;4EACgC;AAI7D;IAFC,IAAA,qBAAS,EAAC,EAAE,IAAI,EAAE,qCAAiB,EAAE,CAAC;IACtC,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;qEACmB;AAIhD;IAFC,IAAA,qBAAS,GAAE;IACX,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;8BACK,mDAAwB;0EAAA;AAnCjD,wBAAwB;IADpC,IAAA,gBAAI,EAAC,0BAA0B,CAAC;GACpB,wBAAwB,CAwCpC;AAxCY,4DAAwB"}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { ISerializableAsync, SerializableAsync } from "@js-soft/ts-serval";
|
|
2
|
+
import { CoreDate, CoreId, ICoreDate, ICoreId } from "@nmshd/transport";
|
|
3
|
+
import { ContentJSON } from "../ContentJSON";
|
|
4
|
+
export interface AttributesRequestJSON extends ContentJSON {
|
|
5
|
+
id?: string;
|
|
6
|
+
key?: string;
|
|
7
|
+
reason?: string;
|
|
8
|
+
expiresAt?: string;
|
|
9
|
+
names: string[];
|
|
10
|
+
required: boolean;
|
|
11
|
+
}
|
|
12
|
+
export interface IAttributesRequest extends ISerializableAsync {
|
|
13
|
+
id?: ICoreId;
|
|
14
|
+
/**
|
|
15
|
+
* The technial key of the request which is submitted back with the answer. This can be used
|
|
16
|
+
* for mapping requests and answers. The key should be unique and non-personal, best a random UUID.
|
|
17
|
+
* @default undefined - no key is used
|
|
18
|
+
*/
|
|
19
|
+
key?: string;
|
|
20
|
+
/**
|
|
21
|
+
* The human-readable reason for this request. This can be used to provide the user with more input
|
|
22
|
+
* why this request is necessary and should be answered.
|
|
23
|
+
* @default undefined - no reason is given
|
|
24
|
+
*/
|
|
25
|
+
reason?: string;
|
|
26
|
+
/**
|
|
27
|
+
* The point in time the request is considered obsolete either technically (e.g. the request is no longer
|
|
28
|
+
* valid or its response is no longer accepted) or from a business perspective (e.g. the request is no longer
|
|
29
|
+
* of interest).
|
|
30
|
+
* @default undefined - the request won't expire
|
|
31
|
+
*/
|
|
32
|
+
expiresAt?: ICoreDate;
|
|
33
|
+
names: string[];
|
|
34
|
+
/**
|
|
35
|
+
* Whether or not this attribute request is required or optional
|
|
36
|
+
* @default undefined - the attribute request is optional
|
|
37
|
+
*/
|
|
38
|
+
required?: boolean;
|
|
39
|
+
}
|
|
40
|
+
export declare class AttributesRequest extends SerializableAsync implements IAttributesRequest {
|
|
41
|
+
id?: CoreId;
|
|
42
|
+
key?: string;
|
|
43
|
+
reason?: string;
|
|
44
|
+
expiresAt?: CoreDate;
|
|
45
|
+
names: string[];
|
|
46
|
+
required?: boolean;
|
|
47
|
+
static from(value: IAttributesRequest): Promise<AttributesRequest>;
|
|
48
|
+
static fromJSON(value: AttributesRequestJSON): Promise<AttributesRequest>;
|
|
49
|
+
}
|