@hestia-earth/schema
Version:
HESTIA Schema
164 lines (163 loc) • 7.13 kB
JavaScript
;
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
Object.defineProperty(exports, "__esModule", { value: true });
exports.Input = exports.inputUniquenessFields = exports.inputTermTermType = exports.InputCostStatsDefinition = exports.InputPriceStatsDefinition = exports.InputMethodClassification = exports.InputStatsDefinition = void 0;
// auto-generated content
var types_1 = require("./types");
var Term_1 = require("./Term");
var InputStatsDefinition;
(function (InputStatsDefinition) {
InputStatsDefinition["animals"] = "animals";
InputStatsDefinition["cycles"] = "cycles";
InputStatsDefinition["modelled"] = "modelled";
InputStatsDefinition["other observations"] = "other observations";
InputStatsDefinition["regions"] = "regions";
InputStatsDefinition["replications"] = "replications";
InputStatsDefinition["simulated"] = "simulated";
InputStatsDefinition["sites"] = "sites";
InputStatsDefinition["spatial"] = "spatial";
InputStatsDefinition["time"] = "time";
})(InputStatsDefinition = exports.InputStatsDefinition || (exports.InputStatsDefinition = {}));
var InputMethodClassification;
(function (InputMethodClassification) {
InputMethodClassification["consistent external sources"] = "consistent external sources";
InputMethodClassification["estimated with assumptions"] = "estimated with assumptions";
InputMethodClassification["expert opinion"] = "expert opinion";
InputMethodClassification["inconsistent external sources"] = "inconsistent external sources";
InputMethodClassification["modelled"] = "modelled";
InputMethodClassification["non-verified survey data"] = "non-verified survey data";
InputMethodClassification["physical measurement"] = "physical measurement";
InputMethodClassification["unsourced assumption"] = "unsourced assumption";
InputMethodClassification["verified survey data"] = "verified survey data";
})(InputMethodClassification = exports.InputMethodClassification || (exports.InputMethodClassification = {}));
var InputPriceStatsDefinition;
(function (InputPriceStatsDefinition) {
InputPriceStatsDefinition["cycles"] = "cycles";
InputPriceStatsDefinition["cycles and time"] = "cycles and time";
InputPriceStatsDefinition["time"] = "time";
})(InputPriceStatsDefinition = exports.InputPriceStatsDefinition || (exports.InputPriceStatsDefinition = {}));
var InputCostStatsDefinition;
(function (InputCostStatsDefinition) {
InputCostStatsDefinition["cycles"] = "cycles";
InputCostStatsDefinition["cycles and time"] = "cycles and time";
InputCostStatsDefinition["time"] = "time";
})(InputCostStatsDefinition = exports.InputCostStatsDefinition || (exports.InputCostStatsDefinition = {}));
/**
* Contains all the TermTermType with override on the Input.
* Note: it does not contain the default TermTermType on related Blank Nodes.
*/
exports.inputTermTermType = {
term: [
Term_1.TermTermType.biologicalControlAgent,
Term_1.TermTermType.electricity,
Term_1.TermTermType.feedFoodAdditive,
Term_1.TermTermType.fuel,
Term_1.TermTermType.material,
Term_1.TermTermType.inorganicFertiliser,
Term_1.TermTermType.organicFertiliser,
Term_1.TermTermType.fertiliserBrandName,
Term_1.TermTermType.biochar,
Term_1.TermTermType.pesticideAI,
Term_1.TermTermType.pesticideBrandName,
Term_1.TermTermType.processingAid,
Term_1.TermTermType.seed,
Term_1.TermTermType.otherOrganicChemical,
Term_1.TermTermType.otherInorganicChemical,
Term_1.TermTermType.soilAmendment,
Term_1.TermTermType.substrate,
Term_1.TermTermType.water,
Term_1.TermTermType.animalProduct,
Term_1.TermTermType.crop,
Term_1.TermTermType.forage,
Term_1.TermTermType.liveAnimal,
Term_1.TermTermType.liveAquaticSpecies,
Term_1.TermTermType.excreta,
Term_1.TermTermType.processedFood,
Term_1.TermTermType.veterinaryDrug,
Term_1.TermTermType.waste
],
model: [
Term_1.TermTermType.model
],
operation: [
Term_1.TermTermType.operation
],
country: [
Term_1.TermTermType.region
],
region: [
Term_1.TermTermType.region
],
all: [
Term_1.TermTermType.biologicalControlAgent,
Term_1.TermTermType.electricity,
Term_1.TermTermType.feedFoodAdditive,
Term_1.TermTermType.fuel,
Term_1.TermTermType.material,
Term_1.TermTermType.inorganicFertiliser,
Term_1.TermTermType.organicFertiliser,
Term_1.TermTermType.fertiliserBrandName,
Term_1.TermTermType.biochar,
Term_1.TermTermType.pesticideAI,
Term_1.TermTermType.pesticideBrandName,
Term_1.TermTermType.processingAid,
Term_1.TermTermType.seed,
Term_1.TermTermType.otherOrganicChemical,
Term_1.TermTermType.otherInorganicChemical,
Term_1.TermTermType.soilAmendment,
Term_1.TermTermType.substrate,
Term_1.TermTermType.water,
Term_1.TermTermType.animalProduct,
Term_1.TermTermType.crop,
Term_1.TermTermType.forage,
Term_1.TermTermType.liveAnimal,
Term_1.TermTermType.liveAquaticSpecies,
Term_1.TermTermType.excreta,
Term_1.TermTermType.processedFood,
Term_1.TermTermType.veterinaryDrug,
Term_1.TermTermType.waste,
Term_1.TermTermType.model,
Term_1.TermTermType.operation,
Term_1.TermTermType.region
]
};
/**
* Contains all the fields that make the blank nodes unique.
*/
exports.inputUniquenessFields = {
properties: ['term.@id',
'key.@id',
'value',
'share',
'date',
'startDate',
'endDate'],
transport: ['term.@id',
'value',
'distance']
};
/**
* An Input used during the [Cycle](/schema/Cycle) or [Transformation](/schema/Transformation). Each Input must be unique, and the fields which determine uniqueness are defined in the <code>[inputs](/schema/Cycle#inputs)</code> field of the Cycle or [Transformation](/schema/Transformation#inputs).
*/
var Input = /** @class */ (function (_super) {
__extends(Input, _super);
function Input() {
return _super !== null && _super.apply(this, arguments) || this;
}
return Input;
}(types_1.JSON));
exports.Input = Input;