Class

Scope

Scope(name, idopt)

Class representing a Scope
Constructor

# new Scope(name, idopt)

Parameters:
Name Type Attributes Description
name string name of the circuit
id number <optional>
a random id for the circuit

View Source circuit.js, line 228

Methods

# addInputs()

Adds all inputs to simulationQueue

View Source circuit.js, line 299

# centerFocus()

Function which centers the circuit to the correct zoom level

View Source circuit.js, line 356

# checkDependency()

Checks if this circuit contains directly or indirectly scope with id Recursive nature

View Source circuit.js, line 321

# clockTick()

Ticks clocks recursively -- needs to be deprecated and synchronize all clocks with a global clock

View Source circuit.js, line 312

# detectCycle()

Function to detect the nodes that are creating cyclic paths in the circuit

View Source circuit.js, line 405

# findNodeIndexById(nodeId)

Function to find the index of a node in globalScope.allNodes
Parameters:
Name Type Description
nodeId string id of a node

View Source circuit.js, line 525

# fixLayout()

helper function to reduce layout size

View Source circuit.js, line 345

# getAllSelectedComponents()

Function to find the currently selected components (when multiple components are selected) on the canvas

View Source circuit.js, line 544

# getCurrentlySelectedComponent()

Function to find the currently selected component on the canvas

View Source circuit.js, line 537

# getDependencies()

Get dependency list - list of all circuits, this circuit depends on

View Source circuit.js, line 333

# highlightNodes(array)

Function to highlight the nodes in the currently selected circuit
Parameters:
Name Type Description
array Array.<Array> id's of the nodes, that we want to highlight

View Source circuit.js, line 507

# loadCircuit()

Function to load a circuit using circuit data

View Source circuit.js, line 382

# modifyCurrentlySelectedComponent()

Function to modify the currently selected component's object in the globalScope takes the property which needs to modify and the modified value as parameters

View Source circuit.js, line 553

# previous()

Function to retrieve the previous stable state of the circuit

View Source circuit.js, line 393

# reset()

Resets all nodes recursively

View Source circuit.js, line 286