From 07174e98e222d09e6792e7a4d282cd2f832503d2 Mon Sep 17 00:00:00 2001 From: "Hofstetter Benjamin (extern)" Date: Fri, 16 Aug 2024 14:56:24 +0200 Subject: [PATCH] fix --- .../service/model/hierarchy-node.model.ts | 46 +++++++++---------- proxy.conf.json | 6 +-- 2 files changed, 26 insertions(+), 26 deletions(-) diff --git a/projects/blueprint/src/app/features/configuration/topology/service/model/hierarchy-node.model.ts b/projects/blueprint/src/app/features/configuration/topology/service/model/hierarchy-node.model.ts index ca20720..6212351 100644 --- a/projects/blueprint/src/app/features/configuration/topology/service/model/hierarchy-node.model.ts +++ b/projects/blueprint/src/app/features/configuration/topology/service/model/hierarchy-node.model.ts @@ -5,60 +5,60 @@ import { ClownfaceObject } from '@blueprint/model/clownface-object/clownface-obj export class HierarchyNode extends ClownfaceObject { - private _children: HierarchyNode[] | null = null; - private _targetClass: string | null = null; - private _label: string | null = null; - private _classLabel: string | null = null; - private _parent: HierarchyNode | null | undefined = undefined; + #_children: HierarchyNode[] | null = null; + #_targetClass: string | null = null; + #_label: string | null = null; + #_classLabel: string | null = null; + #_parent: HierarchyNode | null | undefined = undefined; constructor(cfNode: GraphPointer) { super(cfNode); } get label(): string { - if (this._label === null) { - this._label = this._node.out(rdfs.labelNamedNode).value ?? ''; + if (this.#_label === null) { + this.#_label = this._node.out(rdfs.labelNamedNode).value ?? ''; } - return this.label; + return this.#_label; } get children(): HierarchyNode[] { - if (this._children === null) { - this._children = this._node.out(shacl.propertyNamedNode).out(shacl.nodeNamedNode).map(childNode => new HierarchyNode(childNode)); + if (this.#_children === null) { + this.#_children = this._node.out(shacl.propertyNamedNode).out(shacl.nodeNamedNode).map(childNode => new HierarchyNode(childNode)); } - return this._children; + return this.#_children; } get targetClass(): string { - if (this._targetClass === null) { + if (this.#_targetClass === null) { const targetClasses = this._node.out(shacl.targetClassNamedNode).values; if (targetClasses.length === 0) { console.warn(`No targetClass found for node ${this.iri}. Use an empty string.`); - this._targetClass = ''; + this.#_targetClass = ''; } else { if (targetClasses.length > 1) { console.warn(`Expected exactly one targetClass for node ${this.iri}. Found ${targetClasses.length}. Use the first one.`); } - this._targetClass = targetClasses[0]; + this.#_targetClass = targetClasses[0]; } } - return this._targetClass; + return this.#_targetClass; } get classLabel(): string { - if (this._classLabel === null) { + if (this.#_classLabel === null) { const classLabels = this._node.out(shacl.targetClassNamedNode).in(shacl.targetNodeNamedNode).out(rdfs.labelNamedNode).values; if (classLabels.length === 0) { console.warn(`No classLabel found for node ${this.iri}. Use an empty string.`); - this._classLabel = ''; + this.#_classLabel = ''; } else { if (classLabels.length > 1) { console.warn(`Expected exactly one classLabel for node ${this.iri}. Found ${classLabels.length}. Use the first one.`); } - this._classLabel = classLabels[0]; + this.#_classLabel = classLabels[0]; } } - return this._classLabel; + return this.#_classLabel; } get pathToParent(): string | null { @@ -117,18 +117,18 @@ export class HierarchyNode extends ClownfaceObject { get parent(): HierarchyNode | null { - if (this._parent === undefined) { + if (this.#_parent === undefined) { const parent = this._node.in(shacl.nodeNamedNode).in(shacl.propertyNamedNode); if (parent.values.length === 0) { - this._parent = null; + this.#_parent = null; } else { if (parent.values.length > 1) { console.warn(`Expected exactly one parent for node ${this.iri}. Found ${parent.values.length}. Use the first one.`); } - this._parent = new HierarchyNode(parent.toArray()[0]); + this.#_parent = new HierarchyNode(parent.toArray()[0]); } } - return this._parent; + return this.#_parent; } } diff --git a/proxy.conf.json b/proxy.conf.json index 862acaf..9f9e829 100644 --- a/proxy.conf.json +++ b/proxy.conf.json @@ -1,10 +1,10 @@ { "/query": { "target_1": "https://ld.aws.zazukoians.org/query", - "target_2": "https://ld.flux.zazuko.com/query", - "target": "http://localhost:8080/query", + "target_334": "https://ld.flux.zazuko.com/query", + "target_12": "http://localhost:8080/query", "target_4": "https://ld.aws.zazukoians.org/query", - "target_11": "http://127.0.0.1:7200/repositories/edc", + "target": "http://127.0.0.1:7200/repositories/blueprint", "headers": { "Connection": "keep-alive" },