Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@ospin/fct-graph

Package Overview
Dependencies
Maintainers
4
Versions
83
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ospin/fct-graph - npm Package Compare versions

Comparing version 5.1.0 to 5.2.0

src/seeders/slots/AnyInSlotSeeder.js

2

package.json
{
"name": "@ospin/fct-graph",
"author": "danielseehausen",
"version": "5.1.0",
"version": "5.2.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",

@@ -6,2 +6,3 @@ const { v4: uuidv4 } = require('uuid')

const OutputNode = require('../../../functionalities/OutputNode')
const AnyInSlot = require('../../../slots/AnyInSlot')

@@ -52,5 +53,5 @@ function assertIsOutSlot(slot) {

type: InSlot.TYPE,
dataType: outSlot.dataType,
dataType: AnyInSlot.DATA_TYPE,
name: OutputNode.SLOT_NAME,
displayType: outSlot.displayType,
displayType: null,
unit: OutSlot.ANY_UNIT_STRING,

@@ -57,0 +58,0 @@ dataStreams: [],

@@ -7,2 +7,3 @@ const { v4: uuidv4 } = require('uuid')

const OutSlot = require('../../../slots/OutSlot')
const AnyOutSlot = require('../../../slots/AnyOutSlot')

@@ -57,5 +58,5 @@ function assertIsInSlot(slot) {

type: OutSlot.TYPE,
dataType: inSlot.dataType,
dataType: AnyOutSlot.DATA_TYPE,
name: PushIn.SLOT_NAME,
displayType: inSlot.displayType,
displayType: null,
unit: InSlot.ANY_UNIT_STRING,

@@ -62,0 +63,0 @@ dataStreams: [],

@@ -5,2 +5,3 @@ const FloatInSlotSeeder = require('./FloatInSlotSeeder')

const OneOfInSlotSeeder = require('./OneOfInSlotSeeder')
const AnyInSlotSeeder = require('./AnyInSlotSeeder')

@@ -11,2 +12,3 @@ const FloatOutSlotSeeder = require('./FloatOutSlotSeeder')

const OneOfOutSlotSeeder = require('./OneOfOutSlotSeeder')
const AnyOutSlotSeeder = require('./AnyOutSlotSeeder')

@@ -20,2 +22,3 @@ const RandomSlotSeeder = require('./RandomSlotSeeder')

BooleanInSlotSeeder,
AnyInSlotSeeder,
}

@@ -28,2 +31,3 @@

BooleanOutSlotSeeder,
AnyOutSlotSeeder,
}

@@ -30,0 +34,0 @@

@@ -24,2 +24,10 @@ const Joi = require('joi')

_createDataStreamTo(otherSlot, dataStreamData) {
const extendedDataStreamData = {
averagingWindowSize: 1,
...dataStreamData,
}
return super._createDataStreamTo(otherSlot, extendedDataStreamData)
}
serialize() {

@@ -26,0 +34,0 @@ const dataObj = {

@@ -18,2 +18,10 @@ const Joi = require('joi')

_createDataStreamTo(otherSlot, dataStreamData) {
const extendedDataStreamData = {
averagingWindowSize: 1,
...dataStreamData,
}
return super._createDataStreamTo(otherSlot, extendedDataStreamData)
}
}

@@ -20,0 +28,0 @@

@@ -5,2 +5,3 @@ const FloatInSlot = require('../FloatInSlot')

const OneOfInSlot = require('../OneOfInSlot')
const AnyInSlot = require('../AnyInSlot')

@@ -11,2 +12,3 @@ const FloatOutSlot = require('../FloatOutSlot')

const OneOfOutSlot = require('../OneOfOutSlot')
const AnyOutSlot = require('../AnyOutSlot')

@@ -21,2 +23,3 @@ class SlotFactory {

OneOfInSlot,
AnyInSlot,
]

@@ -31,2 +34,3 @@ }

OneOfOutSlot,
AnyOutSlot,
]

@@ -58,2 +62,3 @@ }

[OneOfInSlot.DATA_TYPE]: OneOfInSlot,
[AnyInSlot.DATA_TYPE]: AnyInSlot,
}

@@ -68,2 +73,3 @@ }

[OneOfOutSlot.DATA_TYPE]: OneOfOutSlot,
[AnyOutSlot.DATA_TYPE]: AnyOutSlot,
}

@@ -70,0 +76,0 @@ }

@@ -12,2 +12,3 @@ const SlotFactory = require('./factories/SlotFactory')

const OneOfInSlot = require('./OneOfInSlot')
const AnyInSlot = require('./AnyInSlot')

@@ -18,2 +19,3 @@ const BooleanOutSlot = require('./BooleanOutSlot')

const OneOfOutSlot = require('./OneOfOutSlot')
const AnyOutSlot = require('./AnyOutSlot')

@@ -33,2 +35,3 @@ module.exports = {

OneOfInSlot,
AnyInSlot,

@@ -39,3 +42,4 @@ BooleanOutSlot,

OneOfOutSlot,
AnyOutSlot,
}

@@ -26,2 +26,10 @@ const Joi = require('joi')

_createDataStreamTo(otherSlot, dataStreamData) {
const extendedDataStreamData = {
averagingWindowSize: 1,
...dataStreamData,
}
return super._createDataStreamTo(otherSlot, extendedDataStreamData)
}
serialize() {

@@ -28,0 +36,0 @@ const dataObj = {

@@ -18,2 +18,10 @@ const Joi = require('joi')

_createDataStreamTo(otherSlot, dataStreamData) {
const extendedDataStreamData = {
averagingWindowSize: 1,
...dataStreamData,
}
return super._createDataStreamTo(otherSlot, extendedDataStreamData)
}
}

@@ -20,0 +28,0 @@

@@ -17,2 +17,4 @@ const Joi = require('joi')

static get ANY_DATA_TYPE() { return 'any' }
static get UNITLESS_UNIT() { return '-' }

@@ -23,3 +25,7 @@

static _assertSlotDataTypesCompatible(slotA, slotB) {
if (slotA.dataType !== slotB.dataType) {
if (
slotA.dataType !== slotB.dataType
&& slotA.dataType !== Slot.ANY_DATA_TYPE
&& slotB.dataType !== Slot.ANY_DATA_TYPE
) {
throw new SlotConnectionError(slotA, slotB, 'dataTypes must match between slots')

@@ -26,0 +32,0 @@ }

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc