@ospin/fct-graph
Advanced tools
Comparing version 2.4.12 to 2.5.0
{ | ||
"name": "@ospin/fct-graph", | ||
"author": "danielseehausen", | ||
"version": "2.4.12", | ||
"version": "2.5.0", | ||
"description": "Graph data structure with conditional edges via 'slots' on nodes. Intended to represent physical and virtual functionalities on a device.", | ||
@@ -6,0 +6,0 @@ "main": "index.js", |
@@ -106,2 +106,6 @@ const Joi = require('joi') | ||
getFctById(fctId) { | ||
return this.functionalities.find(({ id }) => id === fctId) | ||
} | ||
} | ||
@@ -108,0 +112,0 @@ |
const Joi = require('joi') | ||
const RegexUtils = require('../utils/RegexUtils') | ||
const InSlot = require('../slots/InSlot') | ||
const OutSlot = require('../slots/OutSlot') | ||
const SlotFactory = require('../slots/factories/SlotFactory') | ||
@@ -57,2 +59,14 @@ | ||
getInSlots() { | ||
return this.slots.filter(({ type }) => type === InSlot.TYPE) | ||
} | ||
getOutSlots() { | ||
return this.slots.filter(({ type }) => type === OutSlot.TYPE) | ||
} | ||
getSlotByName(slotName) { | ||
return this.slots.find(({ name }) => name === slotName) | ||
} | ||
/* ******************************************************************* | ||
@@ -59,0 +73,0 @@ * GRAPH ACTIONS |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
105430
1901