@shaclmate/compiler 2.0.18 → 2.0.20
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/_ShapesGraphToAstTransformer/transformNodeShapeToAstType.js +10 -0
- package/dist/_ShapesGraphToAstTransformer/transformPropertyShapeToAstObjectTypeProperty.js +1 -0
- package/dist/ast/ObjectType.d.ts +8 -0
- package/dist/enums/IdentifierMintingStrategy.d.ts +1 -1
- package/dist/generators/ts/ListType.js +3 -2
- package/dist/generators/ts/ObjectType.d.ts +4 -0
- package/dist/generators/ts/ObjectType.js +46 -7
- package/dist/generators/ts/ObjectUnionType.js +1 -1
- package/dist/generators/ts/TypeFactory.js +84 -35
- package/dist/generators/ts/_ObjectType/IdentifierPrefixProperty.d.ts +34 -0
- package/dist/generators/ts/_ObjectType/IdentifierPrefixProperty.js +98 -0
- package/dist/generators/ts/_ObjectType/IdentifierProperty.d.ts +4 -6
- package/dist/generators/ts/_ObjectType/IdentifierProperty.js +53 -71
- package/dist/generators/ts/_ObjectType/Property.d.ts +7 -6
- package/dist/generators/ts/_ObjectType/Property.js +0 -6
- package/dist/generators/ts/_ObjectType/ShaclProperty.d.ts +3 -3
- package/dist/generators/ts/_ObjectType/ShaclProperty.js +7 -7
- package/dist/generators/ts/_ObjectType/TypeDiscriminatorProperty.d.ts +6 -4
- package/dist/generators/ts/_ObjectType/TypeDiscriminatorProperty.js +12 -9
- package/dist/generators/ts/_ObjectType/classDeclaration.js +4 -9
- package/dist/generators/ts/_ObjectType/fromJsonFunctionDeclarations.js +5 -5
- package/dist/generators/ts/_ObjectType/fromRdfFunctionDeclarations.js +6 -6
- package/dist/generators/ts/_ObjectType/hashFunctionDeclarations.d.ts +4 -0
- package/dist/generators/ts/_ObjectType/hashFunctionDeclarations.js +18 -0
- package/dist/generators/ts/_ObjectType/hashFunctionOrMethodDeclarations.d.ts +13 -0
- package/dist/generators/ts/_ObjectType/hashFunctionOrMethodDeclarations.js +97 -0
- package/dist/generators/ts/_ObjectType/index.d.ts +2 -1
- package/dist/generators/ts/_ObjectType/index.js +2 -1
- package/dist/generators/ts/_ObjectType/interfaceDeclaration.js +1 -1
- package/dist/generators/ts/_ObjectType/jsonZodSchemaFunctionDeclaration.js +1 -1
- package/dist/generators/ts/_ObjectType/toJsonFunctionOrMethodDeclaration.js +5 -5
- package/dist/generators/ts/_ObjectType/toJsonReturnType.js +2 -4
- package/dist/input/NodeShape.d.ts +1 -0
- package/dist/input/NodeShape.js +11 -8
- package/dist/input/Ontology.d.ts +2 -0
- package/dist/input/Ontology.js +8 -2
- package/dist/input/PropertyShape.js +3 -3
- package/dist/input/generated.d.ts +67 -63
- package/dist/input/generated.js +181 -159
- package/dist/input/tsFeatures.d.ts +1 -1
- package/dist/input/tsFeatures.js +14 -14
- package/package.json +7 -7
- package/dist/generators/ts/_ObjectType/hashFunctionDeclaration.d.ts +0 -5
- package/dist/generators/ts/_ObjectType/hashFunctionDeclaration.js +0 -20
- package/dist/generators/ts/_ObjectType/hashFunctionOrMethodDeclaration.d.ts +0 -11
- package/dist/generators/ts/_ObjectType/hashFunctionOrMethodDeclaration.js +0 -64
package/dist/input/generated.js
CHANGED
|
@@ -4,9 +4,10 @@ import * as rdfjsResource from "rdfjs-resource";
|
|
|
4
4
|
import { PropertyPath } from "./PropertyPath.js";
|
|
5
5
|
export var BaseShaclCoreShape;
|
|
6
6
|
(function (BaseShaclCoreShape) {
|
|
7
|
-
function
|
|
7
|
+
function _propertiesFromRdf({ ignoreRdfType: _ignoreRdfType, languageIn: _languageIn, resource: _resource,
|
|
8
8
|
// @ts-ignore
|
|
9
9
|
..._context }) {
|
|
10
|
+
const identifier = _resource.identifier;
|
|
10
11
|
const _andEither = purify.Either.of([
|
|
11
12
|
..._resource
|
|
12
13
|
.values(dataFactory.namedNode("http://www.w3.org/ns/shacl#and"), {
|
|
@@ -122,7 +123,6 @@ export var BaseShaclCoreShape;
|
|
|
122
123
|
return _hasValuesEither;
|
|
123
124
|
}
|
|
124
125
|
const hasValues = _hasValuesEither.unsafeCoerce();
|
|
125
|
-
const identifier = _resource.identifier;
|
|
126
126
|
const _in_Either = purify.Either.of(_resource
|
|
127
127
|
.values(dataFactory.namedNode("http://www.w3.org/ns/shacl#in"), {
|
|
128
128
|
unique: true,
|
|
@@ -439,6 +439,7 @@ export var BaseShaclCoreShape;
|
|
|
439
439
|
}
|
|
440
440
|
const xone = _xoneEither.unsafeCoerce();
|
|
441
441
|
return purify.Either.of({
|
|
442
|
+
identifier,
|
|
442
443
|
and,
|
|
443
444
|
classes,
|
|
444
445
|
comments,
|
|
@@ -446,7 +447,6 @@ export var BaseShaclCoreShape;
|
|
|
446
447
|
deactivated,
|
|
447
448
|
flags,
|
|
448
449
|
hasValues,
|
|
449
|
-
identifier,
|
|
450
450
|
in_,
|
|
451
451
|
isDefinedBy,
|
|
452
452
|
labels,
|
|
@@ -467,14 +467,14 @@ export var BaseShaclCoreShape;
|
|
|
467
467
|
xone,
|
|
468
468
|
});
|
|
469
469
|
}
|
|
470
|
-
BaseShaclCoreShape.
|
|
470
|
+
BaseShaclCoreShape._propertiesFromRdf = _propertiesFromRdf;
|
|
471
471
|
})(BaseShaclCoreShape || (BaseShaclCoreShape = {}));
|
|
472
472
|
export var ShaclCorePropertyShape;
|
|
473
473
|
(function (ShaclCorePropertyShape) {
|
|
474
|
-
function
|
|
474
|
+
function _propertiesFromRdf({ ignoreRdfType: _ignoreRdfType, languageIn: _languageIn, resource: _resource,
|
|
475
475
|
// @ts-ignore
|
|
476
476
|
..._context }) {
|
|
477
|
-
const _super0Either = BaseShaclCoreShape.
|
|
477
|
+
const _super0Either = BaseShaclCoreShape._propertiesFromRdf({
|
|
478
478
|
..._context,
|
|
479
479
|
ignoreRdfType: true,
|
|
480
480
|
languageIn: _languageIn,
|
|
@@ -492,6 +492,8 @@ export var ShaclCorePropertyShape;
|
|
|
492
492
|
predicate: dataFactory.namedNode("http://www.w3.org/ns/shacl#PropertyShape"),
|
|
493
493
|
}));
|
|
494
494
|
}
|
|
495
|
+
const identifier = _resource.identifier;
|
|
496
|
+
const type = "ShaclCorePropertyShape";
|
|
495
497
|
const _defaultValueEither = purify.Either.of(_resource
|
|
496
498
|
.values(dataFactory.namedNode("http://www.w3.org/ns/shacl#defaultValue"), { unique: true })
|
|
497
499
|
.head()
|
|
@@ -542,7 +544,6 @@ export var ShaclCorePropertyShape;
|
|
|
542
544
|
return _groupsEither;
|
|
543
545
|
}
|
|
544
546
|
const groups = _groupsEither.unsafeCoerce();
|
|
545
|
-
const identifier = _resource.identifier;
|
|
546
547
|
const _namesEither = purify.Either.of([
|
|
547
548
|
..._resource
|
|
548
549
|
.values(dataFactory.namedNode("http://www.w3.org/ns/shacl#name"), {
|
|
@@ -597,7 +598,6 @@ export var ShaclCorePropertyShape;
|
|
|
597
598
|
return _pathEither;
|
|
598
599
|
}
|
|
599
600
|
const path = _pathEither.unsafeCoerce();
|
|
600
|
-
const type = "ShaclCorePropertyShape";
|
|
601
601
|
const _uniqueLangEither = purify.Either.of(_resource
|
|
602
602
|
.values(dataFactory.namedNode("http://www.w3.org/ns/shacl#uniqueLang"), { unique: true })
|
|
603
603
|
.head()
|
|
@@ -609,30 +609,30 @@ export var ShaclCorePropertyShape;
|
|
|
609
609
|
const uniqueLang = _uniqueLangEither.unsafeCoerce();
|
|
610
610
|
return purify.Either.of({
|
|
611
611
|
..._super0,
|
|
612
|
+
identifier,
|
|
613
|
+
type,
|
|
612
614
|
defaultValue,
|
|
613
615
|
descriptions,
|
|
614
616
|
groups,
|
|
615
|
-
identifier,
|
|
616
617
|
names,
|
|
617
618
|
order,
|
|
618
619
|
path,
|
|
619
|
-
type,
|
|
620
620
|
uniqueLang,
|
|
621
621
|
});
|
|
622
622
|
}
|
|
623
|
-
ShaclCorePropertyShape.
|
|
623
|
+
ShaclCorePropertyShape._propertiesFromRdf = _propertiesFromRdf;
|
|
624
624
|
function fromRdf(parameters) {
|
|
625
|
-
return ShaclCorePropertyShape.
|
|
625
|
+
return ShaclCorePropertyShape._propertiesFromRdf(parameters);
|
|
626
626
|
}
|
|
627
627
|
ShaclCorePropertyShape.fromRdf = fromRdf;
|
|
628
628
|
ShaclCorePropertyShape.fromRdfType = dataFactory.namedNode("http://www.w3.org/ns/shacl#PropertyShape");
|
|
629
629
|
})(ShaclCorePropertyShape || (ShaclCorePropertyShape = {}));
|
|
630
630
|
export var ShaclmatePropertyShape;
|
|
631
631
|
(function (ShaclmatePropertyShape) {
|
|
632
|
-
function
|
|
632
|
+
function _propertiesFromRdf({ ignoreRdfType: _ignoreRdfType, languageIn: _languageIn, resource: _resource,
|
|
633
633
|
// @ts-ignore
|
|
634
634
|
..._context }) {
|
|
635
|
-
const _super0Either = ShaclCorePropertyShape.
|
|
635
|
+
const _super0Either = ShaclCorePropertyShape._propertiesFromRdf({
|
|
636
636
|
..._context,
|
|
637
637
|
ignoreRdfType: true,
|
|
638
638
|
languageIn: _languageIn,
|
|
@@ -650,8 +650,10 @@ export var ShaclmatePropertyShape;
|
|
|
650
650
|
predicate: dataFactory.namedNode("http://www.w3.org/ns/shacl#PropertyShape"),
|
|
651
651
|
}));
|
|
652
652
|
}
|
|
653
|
+
const identifier = _resource.identifier;
|
|
654
|
+
const type = "ShaclmatePropertyShape";
|
|
653
655
|
const _externEither = purify.Either.of(_resource
|
|
654
|
-
.values(dataFactory.namedNode("http://
|
|
656
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#extern"), { unique: true })
|
|
655
657
|
.head()
|
|
656
658
|
.chain((_value) => _value.toBoolean())
|
|
657
659
|
.toMaybe());
|
|
@@ -659,9 +661,8 @@ export var ShaclmatePropertyShape;
|
|
|
659
661
|
return _externEither;
|
|
660
662
|
}
|
|
661
663
|
const extern = _externEither.unsafeCoerce();
|
|
662
|
-
const identifier = _resource.identifier;
|
|
663
664
|
const _mutableEither = purify.Either.of(_resource
|
|
664
|
-
.values(dataFactory.namedNode("http://
|
|
665
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#mutable"), { unique: true })
|
|
665
666
|
.head()
|
|
666
667
|
.chain((_value) => _value.toBoolean())
|
|
667
668
|
.toMaybe());
|
|
@@ -670,7 +671,7 @@ export var ShaclmatePropertyShape;
|
|
|
670
671
|
}
|
|
671
672
|
const mutable = _mutableEither.unsafeCoerce();
|
|
672
673
|
const _nameEither = purify.Either.of(_resource
|
|
673
|
-
.values(dataFactory.namedNode("http://
|
|
674
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#name"), { unique: true })
|
|
674
675
|
.head()
|
|
675
676
|
.chain((_value) => _value.toString())
|
|
676
677
|
.toMaybe());
|
|
@@ -678,24 +679,23 @@ export var ShaclmatePropertyShape;
|
|
|
678
679
|
return _nameEither;
|
|
679
680
|
}
|
|
680
681
|
const name = _nameEither.unsafeCoerce();
|
|
681
|
-
const type = "ShaclmatePropertyShape";
|
|
682
682
|
const _visibilityEither = purify.Either.of(_resource
|
|
683
|
-
.values(dataFactory.namedNode("http://
|
|
683
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#visibility"), { unique: true })
|
|
684
684
|
.head()
|
|
685
685
|
.chain((_value) => _value.toIri().chain((iri) => {
|
|
686
686
|
switch (iri.value) {
|
|
687
|
-
case "http://
|
|
687
|
+
case "http://purl.org/shaclmate/ontology#_Visibility_Private":
|
|
688
688
|
return purify.Either.of(iri);
|
|
689
|
-
case "http://
|
|
689
|
+
case "http://purl.org/shaclmate/ontology#_Visibility_Protected":
|
|
690
690
|
return purify.Either.of(iri);
|
|
691
|
-
case "http://
|
|
691
|
+
case "http://purl.org/shaclmate/ontology#_Visibility_Public":
|
|
692
692
|
return purify.Either.of(iri);
|
|
693
693
|
default:
|
|
694
694
|
return purify.Left(new rdfjsResource.Resource.MistypedValueError({
|
|
695
695
|
actualValue: iri,
|
|
696
|
-
expectedValueType: 'rdfjs.NamedNode<"http://
|
|
696
|
+
expectedValueType: 'rdfjs.NamedNode<"http://purl.org/shaclmate/ontology#_Visibility_Private" | "http://purl.org/shaclmate/ontology#_Visibility_Protected" | "http://purl.org/shaclmate/ontology#_Visibility_Public">',
|
|
697
697
|
focusResource: _resource,
|
|
698
|
-
predicate: dataFactory.namedNode("http://
|
|
698
|
+
predicate: dataFactory.namedNode("http://purl.org/shaclmate/ontology#visibility"),
|
|
699
699
|
}));
|
|
700
700
|
}
|
|
701
701
|
}))
|
|
@@ -706,24 +706,24 @@ export var ShaclmatePropertyShape;
|
|
|
706
706
|
const visibility = _visibilityEither.unsafeCoerce();
|
|
707
707
|
return purify.Either.of({
|
|
708
708
|
..._super0,
|
|
709
|
-
extern,
|
|
710
709
|
identifier,
|
|
710
|
+
type,
|
|
711
|
+
extern,
|
|
711
712
|
mutable,
|
|
712
713
|
name,
|
|
713
|
-
type,
|
|
714
714
|
visibility,
|
|
715
715
|
});
|
|
716
716
|
}
|
|
717
|
-
ShaclmatePropertyShape.
|
|
717
|
+
ShaclmatePropertyShape._propertiesFromRdf = _propertiesFromRdf;
|
|
718
718
|
function fromRdf(parameters) {
|
|
719
|
-
return ShaclmatePropertyShape.
|
|
719
|
+
return ShaclmatePropertyShape._propertiesFromRdf(parameters);
|
|
720
720
|
}
|
|
721
721
|
ShaclmatePropertyShape.fromRdf = fromRdf;
|
|
722
722
|
ShaclmatePropertyShape.fromRdfType = dataFactory.namedNode("http://www.w3.org/ns/shacl#PropertyShape");
|
|
723
723
|
})(ShaclmatePropertyShape || (ShaclmatePropertyShape = {}));
|
|
724
724
|
export var OwlOntology;
|
|
725
725
|
(function (OwlOntology) {
|
|
726
|
-
function
|
|
726
|
+
function _propertiesFromRdf({ ignoreRdfType: _ignoreRdfType, languageIn: _languageIn, resource: _resource,
|
|
727
727
|
// @ts-ignore
|
|
728
728
|
..._context }) {
|
|
729
729
|
if (!_ignoreRdfType &&
|
|
@@ -735,6 +735,7 @@ export var OwlOntology;
|
|
|
735
735
|
}));
|
|
736
736
|
}
|
|
737
737
|
const identifier = _resource.identifier;
|
|
738
|
+
const type = "OwlOntology";
|
|
738
739
|
const _labelsEither = purify.Either.of([
|
|
739
740
|
..._resource
|
|
740
741
|
.values(dataFactory.namedNode("http://www.w3.org/2000/01/rdf-schema#label"), { unique: true })
|
|
@@ -760,22 +761,21 @@ export var OwlOntology;
|
|
|
760
761
|
return _labelsEither;
|
|
761
762
|
}
|
|
762
763
|
const labels = _labelsEither.unsafeCoerce();
|
|
763
|
-
|
|
764
|
-
return purify.Either.of({ identifier, labels, type });
|
|
764
|
+
return purify.Either.of({ identifier, type, labels });
|
|
765
765
|
}
|
|
766
|
-
OwlOntology.
|
|
766
|
+
OwlOntology._propertiesFromRdf = _propertiesFromRdf;
|
|
767
767
|
function fromRdf(parameters) {
|
|
768
|
-
return OwlOntology.
|
|
768
|
+
return OwlOntology._propertiesFromRdf(parameters);
|
|
769
769
|
}
|
|
770
770
|
OwlOntology.fromRdf = fromRdf;
|
|
771
771
|
OwlOntology.fromRdfType = dataFactory.namedNode("http://www.w3.org/2002/07/owl#Ontology");
|
|
772
772
|
})(OwlOntology || (OwlOntology = {}));
|
|
773
773
|
export var ShaclmateOntology;
|
|
774
774
|
(function (ShaclmateOntology) {
|
|
775
|
-
function
|
|
775
|
+
function _propertiesFromRdf({ ignoreRdfType: _ignoreRdfType, languageIn: _languageIn, resource: _resource,
|
|
776
776
|
// @ts-ignore
|
|
777
777
|
..._context }) {
|
|
778
|
-
const _super0Either = OwlOntology.
|
|
778
|
+
const _super0Either = OwlOntology._propertiesFromRdf({
|
|
779
779
|
..._context,
|
|
780
780
|
ignoreRdfType: true,
|
|
781
781
|
languageIn: _languageIn,
|
|
@@ -794,8 +794,9 @@ export var ShaclmateOntology;
|
|
|
794
794
|
}));
|
|
795
795
|
}
|
|
796
796
|
const identifier = _resource.identifier;
|
|
797
|
+
const type = "ShaclmateOntology";
|
|
797
798
|
const _tsDataFactoryVariableEither = purify.Either.of(_resource
|
|
798
|
-
.values(dataFactory.namedNode("http://
|
|
799
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsDataFactoryVariable"), { unique: true })
|
|
799
800
|
.head()
|
|
800
801
|
.chain((_value) => _value.toString())
|
|
801
802
|
.toMaybe());
|
|
@@ -805,46 +806,46 @@ export var ShaclmateOntology;
|
|
|
805
806
|
const tsDataFactoryVariable = _tsDataFactoryVariableEither.unsafeCoerce();
|
|
806
807
|
const _tsFeatureExcludesEither = purify.Either.of([
|
|
807
808
|
..._resource
|
|
808
|
-
.values(dataFactory.namedNode("http://
|
|
809
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsFeatureExclude"), { unique: true })
|
|
809
810
|
.flatMap((_item) => _item
|
|
810
811
|
.toValues()
|
|
811
812
|
.head()
|
|
812
813
|
.chain((_value) => _value.toIri().chain((iri) => {
|
|
813
814
|
switch (iri.value) {
|
|
814
|
-
case "http://
|
|
815
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_All":
|
|
815
816
|
return purify.Either.of(iri);
|
|
816
|
-
case "http://
|
|
817
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Create":
|
|
817
818
|
return purify.Either.of(iri);
|
|
818
|
-
case "http://
|
|
819
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Equals":
|
|
819
820
|
return purify.Either.of(iri);
|
|
820
|
-
case "http://
|
|
821
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_FromJson":
|
|
821
822
|
return purify.Either.of(iri);
|
|
822
|
-
case "http://
|
|
823
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_FromRdf":
|
|
823
824
|
return purify.Either.of(iri);
|
|
824
|
-
case "http://
|
|
825
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Hash":
|
|
825
826
|
return purify.Either.of(iri);
|
|
826
|
-
case "http://
|
|
827
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Json":
|
|
827
828
|
return purify.Either.of(iri);
|
|
828
|
-
case "http://
|
|
829
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_JsonSchema":
|
|
829
830
|
return purify.Either.of(iri);
|
|
830
|
-
case "http://
|
|
831
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_JsonUiSchema":
|
|
831
832
|
return purify.Either.of(iri);
|
|
832
|
-
case "http://
|
|
833
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_None":
|
|
833
834
|
return purify.Either.of(iri);
|
|
834
|
-
case "http://
|
|
835
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Rdf":
|
|
835
836
|
return purify.Either.of(iri);
|
|
836
|
-
case "http://
|
|
837
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Sparql":
|
|
837
838
|
return purify.Either.of(iri);
|
|
838
|
-
case "http://
|
|
839
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_ToJson":
|
|
839
840
|
return purify.Either.of(iri);
|
|
840
|
-
case "http://
|
|
841
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_ToRdf":
|
|
841
842
|
return purify.Either.of(iri);
|
|
842
843
|
default:
|
|
843
844
|
return purify.Left(new rdfjsResource.Resource.MistypedValueError({
|
|
844
845
|
actualValue: iri,
|
|
845
|
-
expectedValueType: 'rdfjs.NamedNode<"http://
|
|
846
|
+
expectedValueType: 'rdfjs.NamedNode<"http://purl.org/shaclmate/ontology#_TsFeature_All" | "http://purl.org/shaclmate/ontology#_TsFeature_Create" | "http://purl.org/shaclmate/ontology#_TsFeature_Equals" | "http://purl.org/shaclmate/ontology#_TsFeature_FromJson" | "http://purl.org/shaclmate/ontology#_TsFeature_FromRdf" | "http://purl.org/shaclmate/ontology#_TsFeature_Hash" | "http://purl.org/shaclmate/ontology#_TsFeature_Json" | "http://purl.org/shaclmate/ontology#_TsFeature_JsonSchema" | "http://purl.org/shaclmate/ontology#_TsFeature_JsonUiSchema" | "http://purl.org/shaclmate/ontology#_TsFeature_None" | "http://purl.org/shaclmate/ontology#_TsFeature_Rdf" | "http://purl.org/shaclmate/ontology#_TsFeature_Sparql" | "http://purl.org/shaclmate/ontology#_TsFeature_ToJson" | "http://purl.org/shaclmate/ontology#_TsFeature_ToRdf">',
|
|
846
847
|
focusResource: _resource,
|
|
847
|
-
predicate: dataFactory.namedNode("http://
|
|
848
|
+
predicate: dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsFeatureExclude"),
|
|
848
849
|
}));
|
|
849
850
|
}
|
|
850
851
|
}))
|
|
@@ -857,46 +858,46 @@ export var ShaclmateOntology;
|
|
|
857
858
|
const tsFeatureExcludes = _tsFeatureExcludesEither.unsafeCoerce();
|
|
858
859
|
const _tsFeatureIncludesEither = purify.Either.of([
|
|
859
860
|
..._resource
|
|
860
|
-
.values(dataFactory.namedNode("http://
|
|
861
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsFeatureInclude"), { unique: true })
|
|
861
862
|
.flatMap((_item) => _item
|
|
862
863
|
.toValues()
|
|
863
864
|
.head()
|
|
864
865
|
.chain((_value) => _value.toIri().chain((iri) => {
|
|
865
866
|
switch (iri.value) {
|
|
866
|
-
case "http://
|
|
867
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_All":
|
|
867
868
|
return purify.Either.of(iri);
|
|
868
|
-
case "http://
|
|
869
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Create":
|
|
869
870
|
return purify.Either.of(iri);
|
|
870
|
-
case "http://
|
|
871
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Equals":
|
|
871
872
|
return purify.Either.of(iri);
|
|
872
|
-
case "http://
|
|
873
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_FromJson":
|
|
873
874
|
return purify.Either.of(iri);
|
|
874
|
-
case "http://
|
|
875
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_FromRdf":
|
|
875
876
|
return purify.Either.of(iri);
|
|
876
|
-
case "http://
|
|
877
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Hash":
|
|
877
878
|
return purify.Either.of(iri);
|
|
878
|
-
case "http://
|
|
879
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Json":
|
|
879
880
|
return purify.Either.of(iri);
|
|
880
|
-
case "http://
|
|
881
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_JsonSchema":
|
|
881
882
|
return purify.Either.of(iri);
|
|
882
|
-
case "http://
|
|
883
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_JsonUiSchema":
|
|
883
884
|
return purify.Either.of(iri);
|
|
884
|
-
case "http://
|
|
885
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_None":
|
|
885
886
|
return purify.Either.of(iri);
|
|
886
|
-
case "http://
|
|
887
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Rdf":
|
|
887
888
|
return purify.Either.of(iri);
|
|
888
|
-
case "http://
|
|
889
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Sparql":
|
|
889
890
|
return purify.Either.of(iri);
|
|
890
|
-
case "http://
|
|
891
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_ToJson":
|
|
891
892
|
return purify.Either.of(iri);
|
|
892
|
-
case "http://
|
|
893
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_ToRdf":
|
|
893
894
|
return purify.Either.of(iri);
|
|
894
895
|
default:
|
|
895
896
|
return purify.Left(new rdfjsResource.Resource.MistypedValueError({
|
|
896
897
|
actualValue: iri,
|
|
897
|
-
expectedValueType: 'rdfjs.NamedNode<"http://
|
|
898
|
+
expectedValueType: 'rdfjs.NamedNode<"http://purl.org/shaclmate/ontology#_TsFeature_All" | "http://purl.org/shaclmate/ontology#_TsFeature_Create" | "http://purl.org/shaclmate/ontology#_TsFeature_Equals" | "http://purl.org/shaclmate/ontology#_TsFeature_FromJson" | "http://purl.org/shaclmate/ontology#_TsFeature_FromRdf" | "http://purl.org/shaclmate/ontology#_TsFeature_Hash" | "http://purl.org/shaclmate/ontology#_TsFeature_Json" | "http://purl.org/shaclmate/ontology#_TsFeature_JsonSchema" | "http://purl.org/shaclmate/ontology#_TsFeature_JsonUiSchema" | "http://purl.org/shaclmate/ontology#_TsFeature_None" | "http://purl.org/shaclmate/ontology#_TsFeature_Rdf" | "http://purl.org/shaclmate/ontology#_TsFeature_Sparql" | "http://purl.org/shaclmate/ontology#_TsFeature_ToJson" | "http://purl.org/shaclmate/ontology#_TsFeature_ToRdf">',
|
|
898
899
|
focusResource: _resource,
|
|
899
|
-
predicate: dataFactory.namedNode("http://
|
|
900
|
+
predicate: dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsFeatureInclude"),
|
|
900
901
|
}));
|
|
901
902
|
}
|
|
902
903
|
}))
|
|
@@ -909,7 +910,7 @@ export var ShaclmateOntology;
|
|
|
909
910
|
const tsFeatureIncludes = _tsFeatureIncludesEither.unsafeCoerce();
|
|
910
911
|
const _tsImportsEither = purify.Either.of([
|
|
911
912
|
..._resource
|
|
912
|
-
.values(dataFactory.namedNode("http://
|
|
913
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsImport"), { unique: true })
|
|
913
914
|
.flatMap((_item) => _item
|
|
914
915
|
.toValues()
|
|
915
916
|
.head()
|
|
@@ -922,20 +923,20 @@ export var ShaclmateOntology;
|
|
|
922
923
|
}
|
|
923
924
|
const tsImports = _tsImportsEither.unsafeCoerce();
|
|
924
925
|
const _tsObjectDeclarationTypeEither = purify.Either.of(_resource
|
|
925
|
-
.values(dataFactory.namedNode("http://
|
|
926
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsObjectDeclarationType"), { unique: true })
|
|
926
927
|
.head()
|
|
927
928
|
.chain((_value) => _value.toIri().chain((iri) => {
|
|
928
929
|
switch (iri.value) {
|
|
929
|
-
case "http://
|
|
930
|
+
case "http://purl.org/shaclmate/ontology#_TsObjectDeclarationType_Class":
|
|
930
931
|
return purify.Either.of(iri);
|
|
931
|
-
case "http://
|
|
932
|
+
case "http://purl.org/shaclmate/ontology#_TsObjectDeclarationType_Interface":
|
|
932
933
|
return purify.Either.of(iri);
|
|
933
934
|
default:
|
|
934
935
|
return purify.Left(new rdfjsResource.Resource.MistypedValueError({
|
|
935
936
|
actualValue: iri,
|
|
936
|
-
expectedValueType: 'rdfjs.NamedNode<"http://
|
|
937
|
+
expectedValueType: 'rdfjs.NamedNode<"http://purl.org/shaclmate/ontology#_TsObjectDeclarationType_Class" | "http://purl.org/shaclmate/ontology#_TsObjectDeclarationType_Interface">',
|
|
937
938
|
focusResource: _resource,
|
|
938
|
-
predicate: dataFactory.namedNode("http://
|
|
939
|
+
predicate: dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsObjectDeclarationType"),
|
|
939
940
|
}));
|
|
940
941
|
}
|
|
941
942
|
}))
|
|
@@ -944,8 +945,17 @@ export var ShaclmateOntology;
|
|
|
944
945
|
return _tsObjectDeclarationTypeEither;
|
|
945
946
|
}
|
|
946
947
|
const tsObjectDeclarationType = _tsObjectDeclarationTypeEither.unsafeCoerce();
|
|
948
|
+
const _tsObjectIdentifierPrefixPropertyNameEither = purify.Either.of(_resource
|
|
949
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsObjectIdentifierPrefixPropertyName"), { unique: true })
|
|
950
|
+
.head()
|
|
951
|
+
.chain((_value) => _value.toString())
|
|
952
|
+
.toMaybe());
|
|
953
|
+
if (_tsObjectIdentifierPrefixPropertyNameEither.isLeft()) {
|
|
954
|
+
return _tsObjectIdentifierPrefixPropertyNameEither;
|
|
955
|
+
}
|
|
956
|
+
const tsObjectIdentifierPrefixPropertyName = _tsObjectIdentifierPrefixPropertyNameEither.unsafeCoerce();
|
|
947
957
|
const _tsObjectIdentifierPropertyNameEither = purify.Either.of(_resource
|
|
948
|
-
.values(dataFactory.namedNode("http://
|
|
958
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsObjectIdentifierPropertyName"), { unique: true })
|
|
949
959
|
.head()
|
|
950
960
|
.chain((_value) => _value.toString())
|
|
951
961
|
.toMaybe());
|
|
@@ -954,7 +964,7 @@ export var ShaclmateOntology;
|
|
|
954
964
|
}
|
|
955
965
|
const tsObjectIdentifierPropertyName = _tsObjectIdentifierPropertyNameEither.unsafeCoerce();
|
|
956
966
|
const _tsObjectTypeDiscriminatorPropertyNameEither = purify.Either.of(_resource
|
|
957
|
-
.values(dataFactory.namedNode("http://
|
|
967
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsObjectTypeDiscriminatorPropertyName"), { unique: true })
|
|
958
968
|
.head()
|
|
959
969
|
.chain((_value) => _value.toString())
|
|
960
970
|
.toMaybe());
|
|
@@ -962,33 +972,33 @@ export var ShaclmateOntology;
|
|
|
962
972
|
return _tsObjectTypeDiscriminatorPropertyNameEither;
|
|
963
973
|
}
|
|
964
974
|
const tsObjectTypeDiscriminatorPropertyName = _tsObjectTypeDiscriminatorPropertyNameEither.unsafeCoerce();
|
|
965
|
-
const type = "ShaclmateOntology";
|
|
966
975
|
return purify.Either.of({
|
|
967
976
|
..._super0,
|
|
968
977
|
identifier,
|
|
978
|
+
type,
|
|
969
979
|
tsDataFactoryVariable,
|
|
970
980
|
tsFeatureExcludes,
|
|
971
981
|
tsFeatureIncludes,
|
|
972
982
|
tsImports,
|
|
973
983
|
tsObjectDeclarationType,
|
|
984
|
+
tsObjectIdentifierPrefixPropertyName,
|
|
974
985
|
tsObjectIdentifierPropertyName,
|
|
975
986
|
tsObjectTypeDiscriminatorPropertyName,
|
|
976
|
-
type,
|
|
977
987
|
});
|
|
978
988
|
}
|
|
979
|
-
ShaclmateOntology.
|
|
989
|
+
ShaclmateOntology._propertiesFromRdf = _propertiesFromRdf;
|
|
980
990
|
function fromRdf(parameters) {
|
|
981
|
-
return ShaclmateOntology.
|
|
991
|
+
return ShaclmateOntology._propertiesFromRdf(parameters);
|
|
982
992
|
}
|
|
983
993
|
ShaclmateOntology.fromRdf = fromRdf;
|
|
984
994
|
ShaclmateOntology.fromRdfType = dataFactory.namedNode("http://www.w3.org/2002/07/owl#Ontology");
|
|
985
995
|
})(ShaclmateOntology || (ShaclmateOntology = {}));
|
|
986
996
|
export var ShaclCoreNodeShape;
|
|
987
997
|
(function (ShaclCoreNodeShape) {
|
|
988
|
-
function
|
|
998
|
+
function _propertiesFromRdf({ ignoreRdfType: _ignoreRdfType, languageIn: _languageIn, resource: _resource,
|
|
989
999
|
// @ts-ignore
|
|
990
1000
|
..._context }) {
|
|
991
|
-
const _super0Either = BaseShaclCoreShape.
|
|
1001
|
+
const _super0Either = BaseShaclCoreShape._propertiesFromRdf({
|
|
992
1002
|
..._context,
|
|
993
1003
|
ignoreRdfType: true,
|
|
994
1004
|
languageIn: _languageIn,
|
|
@@ -1006,6 +1016,8 @@ export var ShaclCoreNodeShape;
|
|
|
1006
1016
|
predicate: dataFactory.namedNode("http://www.w3.org/ns/shacl#NodeShape"),
|
|
1007
1017
|
}));
|
|
1008
1018
|
}
|
|
1019
|
+
const identifier = _resource.identifier;
|
|
1020
|
+
const type = "ShaclCoreNodeShape";
|
|
1009
1021
|
const _closedEither = purify.Either.of(_resource
|
|
1010
1022
|
.values(dataFactory.namedNode("http://www.w3.org/ns/shacl#closed"), {
|
|
1011
1023
|
unique: true,
|
|
@@ -1017,7 +1029,6 @@ export var ShaclCoreNodeShape;
|
|
|
1017
1029
|
return _closedEither;
|
|
1018
1030
|
}
|
|
1019
1031
|
const closed = _closedEither.unsafeCoerce();
|
|
1020
|
-
const identifier = _resource.identifier;
|
|
1021
1032
|
const _ignoredPropertiesEither = purify.Either.of(_resource
|
|
1022
1033
|
.values(dataFactory.namedNode("http://www.w3.org/ns/shacl#ignoredProperties"), { unique: true })
|
|
1023
1034
|
.head()
|
|
@@ -1049,29 +1060,28 @@ export var ShaclCoreNodeShape;
|
|
|
1049
1060
|
return _propertiesEither;
|
|
1050
1061
|
}
|
|
1051
1062
|
const properties = _propertiesEither.unsafeCoerce();
|
|
1052
|
-
const type = "ShaclCoreNodeShape";
|
|
1053
1063
|
return purify.Either.of({
|
|
1054
1064
|
..._super0,
|
|
1055
|
-
closed,
|
|
1056
1065
|
identifier,
|
|
1066
|
+
type,
|
|
1067
|
+
closed,
|
|
1057
1068
|
ignoredProperties,
|
|
1058
1069
|
properties,
|
|
1059
|
-
type,
|
|
1060
1070
|
});
|
|
1061
1071
|
}
|
|
1062
|
-
ShaclCoreNodeShape.
|
|
1072
|
+
ShaclCoreNodeShape._propertiesFromRdf = _propertiesFromRdf;
|
|
1063
1073
|
function fromRdf(parameters) {
|
|
1064
|
-
return ShaclCoreNodeShape.
|
|
1074
|
+
return ShaclCoreNodeShape._propertiesFromRdf(parameters);
|
|
1065
1075
|
}
|
|
1066
1076
|
ShaclCoreNodeShape.fromRdf = fromRdf;
|
|
1067
1077
|
ShaclCoreNodeShape.fromRdfType = dataFactory.namedNode("http://www.w3.org/ns/shacl#NodeShape");
|
|
1068
1078
|
})(ShaclCoreNodeShape || (ShaclCoreNodeShape = {}));
|
|
1069
1079
|
export var ShaclmateNodeShape;
|
|
1070
1080
|
(function (ShaclmateNodeShape) {
|
|
1071
|
-
function
|
|
1081
|
+
function _propertiesFromRdf({ ignoreRdfType: _ignoreRdfType, languageIn: _languageIn, resource: _resource,
|
|
1072
1082
|
// @ts-ignore
|
|
1073
1083
|
..._context }) {
|
|
1074
|
-
const _super0Either = ShaclCoreNodeShape.
|
|
1084
|
+
const _super0Either = ShaclCoreNodeShape._propertiesFromRdf({
|
|
1075
1085
|
..._context,
|
|
1076
1086
|
ignoreRdfType: true,
|
|
1077
1087
|
languageIn: _languageIn,
|
|
@@ -1089,8 +1099,10 @@ export var ShaclmateNodeShape;
|
|
|
1089
1099
|
predicate: dataFactory.namedNode("http://www.w3.org/ns/shacl#NodeShape"),
|
|
1090
1100
|
}));
|
|
1091
1101
|
}
|
|
1102
|
+
const identifier = _resource.identifier;
|
|
1103
|
+
const type = "ShaclmateNodeShape";
|
|
1092
1104
|
const _abstractEither = purify.Either.of(_resource
|
|
1093
|
-
.values(dataFactory.namedNode("http://
|
|
1105
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#abstract"), { unique: true })
|
|
1094
1106
|
.head()
|
|
1095
1107
|
.chain((_value) => _value.toBoolean())
|
|
1096
1108
|
.toMaybe());
|
|
@@ -1099,7 +1111,7 @@ export var ShaclmateNodeShape;
|
|
|
1099
1111
|
}
|
|
1100
1112
|
const abstract = _abstractEither.unsafeCoerce();
|
|
1101
1113
|
const _export_Either = purify.Either.of(_resource
|
|
1102
|
-
.values(dataFactory.namedNode("http://
|
|
1114
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#export"), { unique: true })
|
|
1103
1115
|
.head()
|
|
1104
1116
|
.chain((_value) => _value.toBoolean())
|
|
1105
1117
|
.toMaybe());
|
|
@@ -1108,7 +1120,7 @@ export var ShaclmateNodeShape;
|
|
|
1108
1120
|
}
|
|
1109
1121
|
const export_ = _export_Either.unsafeCoerce();
|
|
1110
1122
|
const _externEither = purify.Either.of(_resource
|
|
1111
|
-
.values(dataFactory.namedNode("http://
|
|
1123
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#extern"), { unique: true })
|
|
1112
1124
|
.head()
|
|
1113
1125
|
.chain((_value) => _value.toBoolean())
|
|
1114
1126
|
.toMaybe());
|
|
@@ -1117,7 +1129,7 @@ export var ShaclmateNodeShape;
|
|
|
1117
1129
|
}
|
|
1118
1130
|
const extern = _externEither.unsafeCoerce();
|
|
1119
1131
|
const _fromRdfTypeEither = purify.Either.of(_resource
|
|
1120
|
-
.values(dataFactory.namedNode("http://
|
|
1132
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#fromRdfType"), { unique: true })
|
|
1121
1133
|
.head()
|
|
1122
1134
|
.chain((_value) => _value.toIri())
|
|
1123
1135
|
.toMaybe());
|
|
@@ -1125,22 +1137,23 @@ export var ShaclmateNodeShape;
|
|
|
1125
1137
|
return _fromRdfTypeEither;
|
|
1126
1138
|
}
|
|
1127
1139
|
const fromRdfType = _fromRdfTypeEither.unsafeCoerce();
|
|
1128
|
-
const identifier = _resource.identifier;
|
|
1129
1140
|
const _identifierMintingStrategyEither = purify.Either.of(_resource
|
|
1130
|
-
.values(dataFactory.namedNode("http://
|
|
1141
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#identifierMintingStrategy"), { unique: true })
|
|
1131
1142
|
.head()
|
|
1132
1143
|
.chain((_value) => _value.toIri().chain((iri) => {
|
|
1133
1144
|
switch (iri.value) {
|
|
1134
|
-
case "http://
|
|
1145
|
+
case "http://purl.org/shaclmate/ontology#_IdentifierMintingStrategy_BlankNode":
|
|
1146
|
+
return purify.Either.of(iri);
|
|
1147
|
+
case "http://purl.org/shaclmate/ontology#_IdentifierMintingStrategy_SHA256":
|
|
1135
1148
|
return purify.Either.of(iri);
|
|
1136
|
-
case "http://
|
|
1149
|
+
case "http://purl.org/shaclmate/ontology#_IdentifierMintingStrategy_UUIDv4":
|
|
1137
1150
|
return purify.Either.of(iri);
|
|
1138
1151
|
default:
|
|
1139
1152
|
return purify.Left(new rdfjsResource.Resource.MistypedValueError({
|
|
1140
1153
|
actualValue: iri,
|
|
1141
|
-
expectedValueType: 'rdfjs.NamedNode<"http://
|
|
1154
|
+
expectedValueType: 'rdfjs.NamedNode<"http://purl.org/shaclmate/ontology#_IdentifierMintingStrategy_BlankNode" | "http://purl.org/shaclmate/ontology#_IdentifierMintingStrategy_SHA256" | "http://purl.org/shaclmate/ontology#_IdentifierMintingStrategy_UUIDv4">',
|
|
1142
1155
|
focusResource: _resource,
|
|
1143
|
-
predicate: dataFactory.namedNode("http://
|
|
1156
|
+
predicate: dataFactory.namedNode("http://purl.org/shaclmate/ontology#identifierMintingStrategy"),
|
|
1144
1157
|
}));
|
|
1145
1158
|
}
|
|
1146
1159
|
}))
|
|
@@ -1150,7 +1163,7 @@ export var ShaclmateNodeShape;
|
|
|
1150
1163
|
}
|
|
1151
1164
|
const identifierMintingStrategy = _identifierMintingStrategyEither.unsafeCoerce();
|
|
1152
1165
|
const _mutableEither = purify.Either.of(_resource
|
|
1153
|
-
.values(dataFactory.namedNode("http://
|
|
1166
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#mutable"), { unique: true })
|
|
1154
1167
|
.head()
|
|
1155
1168
|
.chain((_value) => _value.toBoolean())
|
|
1156
1169
|
.toMaybe());
|
|
@@ -1159,7 +1172,7 @@ export var ShaclmateNodeShape;
|
|
|
1159
1172
|
}
|
|
1160
1173
|
const mutable = _mutableEither.unsafeCoerce();
|
|
1161
1174
|
const _nameEither = purify.Either.of(_resource
|
|
1162
|
-
.values(dataFactory.namedNode("http://
|
|
1175
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#name"), { unique: true })
|
|
1163
1176
|
.head()
|
|
1164
1177
|
.chain((_value) => _value.toString())
|
|
1165
1178
|
.toMaybe());
|
|
@@ -1169,7 +1182,7 @@ export var ShaclmateNodeShape;
|
|
|
1169
1182
|
const name = _nameEither.unsafeCoerce();
|
|
1170
1183
|
const _toRdfTypesEither = purify.Either.of([
|
|
1171
1184
|
..._resource
|
|
1172
|
-
.values(dataFactory.namedNode("http://
|
|
1185
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#toRdfType"), { unique: true })
|
|
1173
1186
|
.flatMap((_item) => _item
|
|
1174
1187
|
.toValues()
|
|
1175
1188
|
.head()
|
|
@@ -1183,46 +1196,46 @@ export var ShaclmateNodeShape;
|
|
|
1183
1196
|
const toRdfTypes = _toRdfTypesEither.unsafeCoerce();
|
|
1184
1197
|
const _tsFeatureExcludesEither = purify.Either.of([
|
|
1185
1198
|
..._resource
|
|
1186
|
-
.values(dataFactory.namedNode("http://
|
|
1199
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsFeatureExclude"), { unique: true })
|
|
1187
1200
|
.flatMap((_item) => _item
|
|
1188
1201
|
.toValues()
|
|
1189
1202
|
.head()
|
|
1190
1203
|
.chain((_value) => _value.toIri().chain((iri) => {
|
|
1191
1204
|
switch (iri.value) {
|
|
1192
|
-
case "http://
|
|
1205
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_All":
|
|
1193
1206
|
return purify.Either.of(iri);
|
|
1194
|
-
case "http://
|
|
1207
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Create":
|
|
1195
1208
|
return purify.Either.of(iri);
|
|
1196
|
-
case "http://
|
|
1209
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Equals":
|
|
1197
1210
|
return purify.Either.of(iri);
|
|
1198
|
-
case "http://
|
|
1211
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_FromJson":
|
|
1199
1212
|
return purify.Either.of(iri);
|
|
1200
|
-
case "http://
|
|
1213
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_FromRdf":
|
|
1201
1214
|
return purify.Either.of(iri);
|
|
1202
|
-
case "http://
|
|
1215
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Hash":
|
|
1203
1216
|
return purify.Either.of(iri);
|
|
1204
|
-
case "http://
|
|
1217
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Json":
|
|
1205
1218
|
return purify.Either.of(iri);
|
|
1206
|
-
case "http://
|
|
1219
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_JsonSchema":
|
|
1207
1220
|
return purify.Either.of(iri);
|
|
1208
|
-
case "http://
|
|
1221
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_JsonUiSchema":
|
|
1209
1222
|
return purify.Either.of(iri);
|
|
1210
|
-
case "http://
|
|
1223
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_None":
|
|
1211
1224
|
return purify.Either.of(iri);
|
|
1212
|
-
case "http://
|
|
1225
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Rdf":
|
|
1213
1226
|
return purify.Either.of(iri);
|
|
1214
|
-
case "http://
|
|
1227
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Sparql":
|
|
1215
1228
|
return purify.Either.of(iri);
|
|
1216
|
-
case "http://
|
|
1229
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_ToJson":
|
|
1217
1230
|
return purify.Either.of(iri);
|
|
1218
|
-
case "http://
|
|
1231
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_ToRdf":
|
|
1219
1232
|
return purify.Either.of(iri);
|
|
1220
1233
|
default:
|
|
1221
1234
|
return purify.Left(new rdfjsResource.Resource.MistypedValueError({
|
|
1222
1235
|
actualValue: iri,
|
|
1223
|
-
expectedValueType: 'rdfjs.NamedNode<"http://
|
|
1236
|
+
expectedValueType: 'rdfjs.NamedNode<"http://purl.org/shaclmate/ontology#_TsFeature_All" | "http://purl.org/shaclmate/ontology#_TsFeature_Create" | "http://purl.org/shaclmate/ontology#_TsFeature_Equals" | "http://purl.org/shaclmate/ontology#_TsFeature_FromJson" | "http://purl.org/shaclmate/ontology#_TsFeature_FromRdf" | "http://purl.org/shaclmate/ontology#_TsFeature_Hash" | "http://purl.org/shaclmate/ontology#_TsFeature_Json" | "http://purl.org/shaclmate/ontology#_TsFeature_JsonSchema" | "http://purl.org/shaclmate/ontology#_TsFeature_JsonUiSchema" | "http://purl.org/shaclmate/ontology#_TsFeature_None" | "http://purl.org/shaclmate/ontology#_TsFeature_Rdf" | "http://purl.org/shaclmate/ontology#_TsFeature_Sparql" | "http://purl.org/shaclmate/ontology#_TsFeature_ToJson" | "http://purl.org/shaclmate/ontology#_TsFeature_ToRdf">',
|
|
1224
1237
|
focusResource: _resource,
|
|
1225
|
-
predicate: dataFactory.namedNode("http://
|
|
1238
|
+
predicate: dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsFeatureExclude"),
|
|
1226
1239
|
}));
|
|
1227
1240
|
}
|
|
1228
1241
|
}))
|
|
@@ -1235,46 +1248,46 @@ export var ShaclmateNodeShape;
|
|
|
1235
1248
|
const tsFeatureExcludes = _tsFeatureExcludesEither.unsafeCoerce();
|
|
1236
1249
|
const _tsFeatureIncludesEither = purify.Either.of([
|
|
1237
1250
|
..._resource
|
|
1238
|
-
.values(dataFactory.namedNode("http://
|
|
1251
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsFeatureInclude"), { unique: true })
|
|
1239
1252
|
.flatMap((_item) => _item
|
|
1240
1253
|
.toValues()
|
|
1241
1254
|
.head()
|
|
1242
1255
|
.chain((_value) => _value.toIri().chain((iri) => {
|
|
1243
1256
|
switch (iri.value) {
|
|
1244
|
-
case "http://
|
|
1257
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_All":
|
|
1245
1258
|
return purify.Either.of(iri);
|
|
1246
|
-
case "http://
|
|
1259
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Create":
|
|
1247
1260
|
return purify.Either.of(iri);
|
|
1248
|
-
case "http://
|
|
1261
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Equals":
|
|
1249
1262
|
return purify.Either.of(iri);
|
|
1250
|
-
case "http://
|
|
1263
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_FromJson":
|
|
1251
1264
|
return purify.Either.of(iri);
|
|
1252
|
-
case "http://
|
|
1265
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_FromRdf":
|
|
1253
1266
|
return purify.Either.of(iri);
|
|
1254
|
-
case "http://
|
|
1267
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Hash":
|
|
1255
1268
|
return purify.Either.of(iri);
|
|
1256
|
-
case "http://
|
|
1269
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Json":
|
|
1257
1270
|
return purify.Either.of(iri);
|
|
1258
|
-
case "http://
|
|
1271
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_JsonSchema":
|
|
1259
1272
|
return purify.Either.of(iri);
|
|
1260
|
-
case "http://
|
|
1273
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_JsonUiSchema":
|
|
1261
1274
|
return purify.Either.of(iri);
|
|
1262
|
-
case "http://
|
|
1275
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_None":
|
|
1263
1276
|
return purify.Either.of(iri);
|
|
1264
|
-
case "http://
|
|
1277
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Rdf":
|
|
1265
1278
|
return purify.Either.of(iri);
|
|
1266
|
-
case "http://
|
|
1279
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_Sparql":
|
|
1267
1280
|
return purify.Either.of(iri);
|
|
1268
|
-
case "http://
|
|
1281
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_ToJson":
|
|
1269
1282
|
return purify.Either.of(iri);
|
|
1270
|
-
case "http://
|
|
1283
|
+
case "http://purl.org/shaclmate/ontology#_TsFeature_ToRdf":
|
|
1271
1284
|
return purify.Either.of(iri);
|
|
1272
1285
|
default:
|
|
1273
1286
|
return purify.Left(new rdfjsResource.Resource.MistypedValueError({
|
|
1274
1287
|
actualValue: iri,
|
|
1275
|
-
expectedValueType: 'rdfjs.NamedNode<"http://
|
|
1288
|
+
expectedValueType: 'rdfjs.NamedNode<"http://purl.org/shaclmate/ontology#_TsFeature_All" | "http://purl.org/shaclmate/ontology#_TsFeature_Create" | "http://purl.org/shaclmate/ontology#_TsFeature_Equals" | "http://purl.org/shaclmate/ontology#_TsFeature_FromJson" | "http://purl.org/shaclmate/ontology#_TsFeature_FromRdf" | "http://purl.org/shaclmate/ontology#_TsFeature_Hash" | "http://purl.org/shaclmate/ontology#_TsFeature_Json" | "http://purl.org/shaclmate/ontology#_TsFeature_JsonSchema" | "http://purl.org/shaclmate/ontology#_TsFeature_JsonUiSchema" | "http://purl.org/shaclmate/ontology#_TsFeature_None" | "http://purl.org/shaclmate/ontology#_TsFeature_Rdf" | "http://purl.org/shaclmate/ontology#_TsFeature_Sparql" | "http://purl.org/shaclmate/ontology#_TsFeature_ToJson" | "http://purl.org/shaclmate/ontology#_TsFeature_ToRdf">',
|
|
1276
1289
|
focusResource: _resource,
|
|
1277
|
-
predicate: dataFactory.namedNode("http://
|
|
1290
|
+
predicate: dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsFeatureInclude"),
|
|
1278
1291
|
}));
|
|
1279
1292
|
}
|
|
1280
1293
|
}))
|
|
@@ -1287,7 +1300,7 @@ export var ShaclmateNodeShape;
|
|
|
1287
1300
|
const tsFeatureIncludes = _tsFeatureIncludesEither.unsafeCoerce();
|
|
1288
1301
|
const _tsImportsEither = purify.Either.of([
|
|
1289
1302
|
..._resource
|
|
1290
|
-
.values(dataFactory.namedNode("http://
|
|
1303
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsImport"), { unique: true })
|
|
1291
1304
|
.flatMap((_item) => _item
|
|
1292
1305
|
.toValues()
|
|
1293
1306
|
.head()
|
|
@@ -1300,20 +1313,20 @@ export var ShaclmateNodeShape;
|
|
|
1300
1313
|
}
|
|
1301
1314
|
const tsImports = _tsImportsEither.unsafeCoerce();
|
|
1302
1315
|
const _tsObjectDeclarationTypeEither = purify.Either.of(_resource
|
|
1303
|
-
.values(dataFactory.namedNode("http://
|
|
1316
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsObjectDeclarationType"), { unique: true })
|
|
1304
1317
|
.head()
|
|
1305
1318
|
.chain((_value) => _value.toIri().chain((iri) => {
|
|
1306
1319
|
switch (iri.value) {
|
|
1307
|
-
case "http://
|
|
1320
|
+
case "http://purl.org/shaclmate/ontology#_TsObjectDeclarationType_Class":
|
|
1308
1321
|
return purify.Either.of(iri);
|
|
1309
|
-
case "http://
|
|
1322
|
+
case "http://purl.org/shaclmate/ontology#_TsObjectDeclarationType_Interface":
|
|
1310
1323
|
return purify.Either.of(iri);
|
|
1311
1324
|
default:
|
|
1312
1325
|
return purify.Left(new rdfjsResource.Resource.MistypedValueError({
|
|
1313
1326
|
actualValue: iri,
|
|
1314
|
-
expectedValueType: 'rdfjs.NamedNode<"http://
|
|
1327
|
+
expectedValueType: 'rdfjs.NamedNode<"http://purl.org/shaclmate/ontology#_TsObjectDeclarationType_Class" | "http://purl.org/shaclmate/ontology#_TsObjectDeclarationType_Interface">',
|
|
1315
1328
|
focusResource: _resource,
|
|
1316
|
-
predicate: dataFactory.namedNode("http://
|
|
1329
|
+
predicate: dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsObjectDeclarationType"),
|
|
1317
1330
|
}));
|
|
1318
1331
|
}
|
|
1319
1332
|
}))
|
|
@@ -1322,8 +1335,17 @@ export var ShaclmateNodeShape;
|
|
|
1322
1335
|
return _tsObjectDeclarationTypeEither;
|
|
1323
1336
|
}
|
|
1324
1337
|
const tsObjectDeclarationType = _tsObjectDeclarationTypeEither.unsafeCoerce();
|
|
1338
|
+
const _tsObjectIdentifierPrefixPropertyNameEither = purify.Either.of(_resource
|
|
1339
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsObjectIdentifierPrefixPropertyName"), { unique: true })
|
|
1340
|
+
.head()
|
|
1341
|
+
.chain((_value) => _value.toString())
|
|
1342
|
+
.toMaybe());
|
|
1343
|
+
if (_tsObjectIdentifierPrefixPropertyNameEither.isLeft()) {
|
|
1344
|
+
return _tsObjectIdentifierPrefixPropertyNameEither;
|
|
1345
|
+
}
|
|
1346
|
+
const tsObjectIdentifierPrefixPropertyName = _tsObjectIdentifierPrefixPropertyNameEither.unsafeCoerce();
|
|
1325
1347
|
const _tsObjectIdentifierPropertyNameEither = purify.Either.of(_resource
|
|
1326
|
-
.values(dataFactory.namedNode("http://
|
|
1348
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsObjectIdentifierPropertyName"), { unique: true })
|
|
1327
1349
|
.head()
|
|
1328
1350
|
.chain((_value) => _value.toString())
|
|
1329
1351
|
.toMaybe());
|
|
@@ -1332,7 +1354,7 @@ export var ShaclmateNodeShape;
|
|
|
1332
1354
|
}
|
|
1333
1355
|
const tsObjectIdentifierPropertyName = _tsObjectIdentifierPropertyNameEither.unsafeCoerce();
|
|
1334
1356
|
const _tsObjectTypeDiscriminatorPropertyNameEither = purify.Either.of(_resource
|
|
1335
|
-
.values(dataFactory.namedNode("http://
|
|
1357
|
+
.values(dataFactory.namedNode("http://purl.org/shaclmate/ontology#tsObjectTypeDiscriminatorPropertyName"), { unique: true })
|
|
1336
1358
|
.head()
|
|
1337
1359
|
.chain((_value) => _value.toString())
|
|
1338
1360
|
.toMaybe());
|
|
@@ -1340,14 +1362,14 @@ export var ShaclmateNodeShape;
|
|
|
1340
1362
|
return _tsObjectTypeDiscriminatorPropertyNameEither;
|
|
1341
1363
|
}
|
|
1342
1364
|
const tsObjectTypeDiscriminatorPropertyName = _tsObjectTypeDiscriminatorPropertyNameEither.unsafeCoerce();
|
|
1343
|
-
const type = "ShaclmateNodeShape";
|
|
1344
1365
|
return purify.Either.of({
|
|
1345
1366
|
..._super0,
|
|
1367
|
+
identifier,
|
|
1368
|
+
type,
|
|
1346
1369
|
abstract,
|
|
1347
1370
|
export_,
|
|
1348
1371
|
extern,
|
|
1349
1372
|
fromRdfType,
|
|
1350
|
-
identifier,
|
|
1351
1373
|
identifierMintingStrategy,
|
|
1352
1374
|
mutable,
|
|
1353
1375
|
name,
|
|
@@ -1356,21 +1378,21 @@ export var ShaclmateNodeShape;
|
|
|
1356
1378
|
tsFeatureIncludes,
|
|
1357
1379
|
tsImports,
|
|
1358
1380
|
tsObjectDeclarationType,
|
|
1381
|
+
tsObjectIdentifierPrefixPropertyName,
|
|
1359
1382
|
tsObjectIdentifierPropertyName,
|
|
1360
1383
|
tsObjectTypeDiscriminatorPropertyName,
|
|
1361
|
-
type,
|
|
1362
1384
|
});
|
|
1363
1385
|
}
|
|
1364
|
-
ShaclmateNodeShape.
|
|
1386
|
+
ShaclmateNodeShape._propertiesFromRdf = _propertiesFromRdf;
|
|
1365
1387
|
function fromRdf(parameters) {
|
|
1366
|
-
return ShaclmateNodeShape.
|
|
1388
|
+
return ShaclmateNodeShape._propertiesFromRdf(parameters);
|
|
1367
1389
|
}
|
|
1368
1390
|
ShaclmateNodeShape.fromRdf = fromRdf;
|
|
1369
1391
|
ShaclmateNodeShape.fromRdfType = dataFactory.namedNode("http://www.w3.org/ns/shacl#NodeShape");
|
|
1370
1392
|
})(ShaclmateNodeShape || (ShaclmateNodeShape = {}));
|
|
1371
1393
|
export var ShaclCorePropertyGroup;
|
|
1372
1394
|
(function (ShaclCorePropertyGroup) {
|
|
1373
|
-
function
|
|
1395
|
+
function _propertiesFromRdf({ ignoreRdfType: _ignoreRdfType, languageIn: _languageIn, resource: _resource,
|
|
1374
1396
|
// @ts-ignore
|
|
1375
1397
|
..._context }) {
|
|
1376
1398
|
if (!_ignoreRdfType &&
|
|
@@ -1381,6 +1403,8 @@ export var ShaclCorePropertyGroup;
|
|
|
1381
1403
|
predicate: dataFactory.namedNode("http://www.w3.org/ns/shacl#PropertyGroup"),
|
|
1382
1404
|
}));
|
|
1383
1405
|
}
|
|
1406
|
+
const identifier = _resource.identifier;
|
|
1407
|
+
const type = "ShaclCorePropertyGroup";
|
|
1384
1408
|
const _commentsEither = purify.Either.of([
|
|
1385
1409
|
..._resource
|
|
1386
1410
|
.values(dataFactory.namedNode("http://www.w3.org/2000/01/rdf-schema#comment"), { unique: true })
|
|
@@ -1406,7 +1430,6 @@ export var ShaclCorePropertyGroup;
|
|
|
1406
1430
|
return _commentsEither;
|
|
1407
1431
|
}
|
|
1408
1432
|
const comments = _commentsEither.unsafeCoerce();
|
|
1409
|
-
const identifier = _resource.identifier;
|
|
1410
1433
|
const _labelsEither = purify.Either.of([
|
|
1411
1434
|
..._resource
|
|
1412
1435
|
.values(dataFactory.namedNode("http://www.w3.org/2000/01/rdf-schema#label"), { unique: true })
|
|
@@ -1432,12 +1455,11 @@ export var ShaclCorePropertyGroup;
|
|
|
1432
1455
|
return _labelsEither;
|
|
1433
1456
|
}
|
|
1434
1457
|
const labels = _labelsEither.unsafeCoerce();
|
|
1435
|
-
|
|
1436
|
-
return purify.Either.of({ comments, identifier, labels, type });
|
|
1458
|
+
return purify.Either.of({ identifier, type, comments, labels });
|
|
1437
1459
|
}
|
|
1438
|
-
ShaclCorePropertyGroup.
|
|
1460
|
+
ShaclCorePropertyGroup._propertiesFromRdf = _propertiesFromRdf;
|
|
1439
1461
|
function fromRdf(parameters) {
|
|
1440
|
-
return ShaclCorePropertyGroup.
|
|
1462
|
+
return ShaclCorePropertyGroup._propertiesFromRdf(parameters);
|
|
1441
1463
|
}
|
|
1442
1464
|
ShaclCorePropertyGroup.fromRdf = fromRdf;
|
|
1443
1465
|
ShaclCorePropertyGroup.fromRdfType = dataFactory.namedNode("http://www.w3.org/ns/shacl#PropertyGroup");
|