triangle-types 1.0.241 → 1.0.243

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.
@@ -2,6 +2,7 @@ import { TenantProvision } from "./TenantProvision.js";
2
2
  export declare class Tenant {
3
3
  readonly tenant_id: string;
4
4
  readonly name: string;
5
+ readonly s3_id_img?: string;
5
6
  readonly [x: string]: any;
6
7
  constructor(tenant: Tenant);
7
8
  static is(tenant: any): tenant is Tenant;
@@ -2,17 +2,20 @@ import { TenantProvision } from "./TenantProvision.js";
2
2
  export class Tenant {
3
3
  tenant_id;
4
4
  name;
5
+ s3_id_img;
5
6
  constructor(tenant) {
6
7
  if (!Tenant.is(tenant)) {
7
8
  throw Error("Invalid Input.");
8
9
  }
9
10
  this.tenant_id = tenant.tenant_id;
10
11
  this.name = tenant.name;
12
+ this.s3_id_img = tenant.s3_id_img;
11
13
  }
12
14
  static is(tenant) {
13
15
  return (tenant !== undefined &&
14
16
  typeof tenant.tenant_id === "string" &&
15
- typeof tenant.name === "string");
17
+ typeof tenant.name === "string" &&
18
+ typeof tenant.s3_id_img === "string");
16
19
  }
17
20
  }
18
21
  export class TenantAux extends Tenant {
@@ -1,4 +1,5 @@
1
1
  import { FragmentTypeID } from "../fragments/Fragment.js";
2
+ import { TenantDocument } from "./TenantDocument.js";
2
3
  export declare class TenantDocumentFragment {
3
4
  readonly tenant_document_id: string;
4
5
  readonly tenant_id: string;
@@ -14,3 +15,8 @@ export declare class TenantDocumentFragment {
14
15
  constructor(tenant_document_fragment: TenantDocumentFragment);
15
16
  static is(tenant_document_fragment: any): tenant_document_fragment is TenantDocumentFragment;
16
17
  }
18
+ export declare class TenantDocumentFragmentAux extends TenantDocumentFragment {
19
+ readonly tenant_document: TenantDocument;
20
+ constructor(tenant_document_fragment: TenantDocumentFragment);
21
+ static is(tenant_document_fragment: any): tenant_document_fragment is TenantDocumentFragmentAux;
22
+ }
@@ -1,4 +1,5 @@
1
1
  import { is_fragment_type_id } from "../fragments/Fragment.js";
2
+ import { TenantDocument } from "./TenantDocument.js";
2
3
  export class TenantDocumentFragment {
3
4
  tenant_document_id;
4
5
  tenant_id;
@@ -39,3 +40,17 @@ export class TenantDocumentFragment {
39
40
  (tenant_document_fragment.vector === undefined || Array.isArray(tenant_document_fragment.vector) && tenant_document_fragment.vector.every((coordinate) => typeof coordinate === "number")));
40
41
  }
41
42
  }
43
+ export class TenantDocumentFragmentAux extends TenantDocumentFragment {
44
+ tenant_document;
45
+ constructor(tenant_document_fragment) {
46
+ if (!TenantDocumentFragmentAux.is(tenant_document_fragment)) {
47
+ throw Error("Invalid input.");
48
+ }
49
+ super(tenant_document_fragment);
50
+ this.tenant_document = tenant_document_fragment.tenant_document;
51
+ }
52
+ static is(tenant_document_fragment) {
53
+ return (TenantDocumentFragment.is(tenant_document_fragment) &&
54
+ TenantDocument.is(tenant_document_fragment.tenant_document));
55
+ }
56
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "triangle-types",
3
- "version": "1.0.241",
3
+ "version": "1.0.243",
4
4
  "main": "dist/src/index.js",
5
5
  "types": "dist/src/index.d.ts",
6
6
  "scripts": {
@@ -3,6 +3,7 @@ import { TenantProvision } from "./TenantProvision"
3
3
  export class Tenant {
4
4
  readonly tenant_id : string
5
5
  readonly name : string
6
+ readonly s3_id_img? : string
6
7
  readonly [x : string] : any
7
8
 
8
9
  constructor(tenant : Tenant) {
@@ -11,13 +12,15 @@ export class Tenant {
11
12
  }
12
13
  this.tenant_id = tenant.tenant_id
13
14
  this.name = tenant.name
15
+ this.s3_id_img = tenant.s3_id_img
14
16
  }
15
17
 
16
18
  static is(tenant : any) : tenant is Tenant {
17
19
  return (
18
20
  tenant !== undefined &&
19
21
  typeof tenant.tenant_id === "string" &&
20
- typeof tenant.name === "string"
22
+ typeof tenant.name === "string" &&
23
+ typeof tenant.s3_id_img === "string"
21
24
  )
22
25
  }
23
26
  }
@@ -1,4 +1,5 @@
1
1
  import { FragmentTypeID, is_fragment_type_id } from "../fragments/Fragment"
2
+ import { TenantDocument } from "./TenantDocument"
2
3
 
3
4
  export class TenantDocumentFragment {
4
5
  readonly tenant_document_id : string
@@ -44,4 +45,24 @@ export class TenantDocumentFragment {
44
45
  (tenant_document_fragment.vector === undefined || Array.isArray(tenant_document_fragment.vector) && tenant_document_fragment.vector.every((coordinate : any) => typeof coordinate === "number"))
45
46
  )
46
47
  }
48
+ }
49
+
50
+ export class TenantDocumentFragmentAux extends TenantDocumentFragment {
51
+ readonly tenant_document : TenantDocument
52
+
53
+
54
+ constructor(tenant_document_fragment : TenantDocumentFragment) {
55
+ if (!TenantDocumentFragmentAux.is(tenant_document_fragment)) {
56
+ throw Error("Invalid input.")
57
+ }
58
+ super(tenant_document_fragment)
59
+ this.tenant_document = tenant_document_fragment.tenant_document
60
+ }
61
+
62
+ static is(tenant_document_fragment : any) : tenant_document_fragment is TenantDocumentFragmentAux {
63
+ return (
64
+ TenantDocumentFragment.is(tenant_document_fragment) &&
65
+ TenantDocument.is(tenant_document_fragment.tenant_document)
66
+ )
67
+ }
47
68
  }