@qudtlib/core
Advanced tools
Comparing version 5.0.0-beta.0 to 5.0.0
@@ -78,2 +78,11 @@ "use strict"; | ||
} | ||
static currencyFromLocalname(localname) { | ||
return Qudt.unit(Qudt.currencyIriFromLocalname(localname)); | ||
} | ||
static currencyFromLocalnameRequired(localname) { | ||
return Qudt.unitRequired(Qudt.currencyIriFromLocalname(localname)); | ||
} | ||
static currencyIriFromLocalname(localname) { | ||
return Qudt.NAMESPACES.currency.makeIriInNamespace(localname); | ||
} | ||
static quantityKind(quantityKindIri) { | ||
@@ -80,0 +89,0 @@ return exports.config.quantityKinds.get(quantityKindIri); |
@@ -9,2 +9,3 @@ "use strict"; | ||
unit: new namespace_js_1.Namespace("http://qudt.org/vocab/unit/", "unit"), | ||
currency: new namespace_js_1.Namespace("http://qudt.org/vocab/currency/", "cur"), | ||
prefix: new namespace_js_1.Namespace("http://qudt.org/vocab/prefix/", "prefix"), | ||
@@ -11,0 +12,0 @@ systemOfUnits: new namespace_js_1.Namespace("http://qudt.org/vocab/sou/", "sou"), |
@@ -74,2 +74,11 @@ import { Unit } from "./unit.js"; | ||
} | ||
static currencyFromLocalname(localname) { | ||
return Qudt.unit(Qudt.currencyIriFromLocalname(localname)); | ||
} | ||
static currencyFromLocalnameRequired(localname) { | ||
return Qudt.unitRequired(Qudt.currencyIriFromLocalname(localname)); | ||
} | ||
static currencyIriFromLocalname(localname) { | ||
return Qudt.NAMESPACES.currency.makeIriInNamespace(localname); | ||
} | ||
static quantityKind(quantityKindIri) { | ||
@@ -76,0 +85,0 @@ return config.quantityKinds.get(quantityKindIri); |
@@ -6,2 +6,3 @@ import { Namespace } from "./namespace.js"; | ||
unit: new Namespace("http://qudt.org/vocab/unit/", "unit"), | ||
currency: new Namespace("http://qudt.org/vocab/currency/", "cur"), | ||
prefix: new Namespace("http://qudt.org/vocab/prefix/", "prefix"), | ||
@@ -8,0 +9,0 @@ systemOfUnits: new Namespace("http://qudt.org/vocab/sou/", "sou"), |
@@ -24,2 +24,3 @@ import { Unit } from "./unit.js"; | ||
unit: Namespace; | ||
currency: Namespace; | ||
prefix: Namespace; | ||
@@ -56,2 +57,5 @@ systemOfUnits: Namespace; | ||
static unitIriFromLocalname(localname: string): string; | ||
static currencyFromLocalname(localname: string): Unit | undefined; | ||
static currencyFromLocalnameRequired(localname: string): Unit; | ||
static currencyIriFromLocalname(localname: string): string; | ||
static quantityKind(quantityKindIri: string): QuantityKind | undefined; | ||
@@ -58,0 +62,0 @@ static quantityKindRequired(quantityKindIri: string): QuantityKind; |
@@ -6,2 +6,3 @@ import { Namespace } from "./namespace.js"; | ||
unit: Namespace; | ||
currency: Namespace; | ||
prefix: Namespace; | ||
@@ -8,0 +9,0 @@ systemOfUnits: Namespace; |
{ | ||
"name": "@qudtlib/core", | ||
"version": "5.0.0-beta.0", | ||
"version": "5.0.0", | ||
"description": "Data model for QUDTLib", | ||
@@ -55,3 +55,3 @@ "main": "dist/cjs/qudtlib.js", | ||
}, | ||
"gitHead": "4b03bae38ab2889cce62004f43728d3b4698534a" | ||
"gitHead": "0b050f6fb29307c7f395ca9e48ac5fb977cb59c5" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
495362
4046
1