Skip to content

Circuit

A Circuit contains devices and connectors

Constructors
Circuit() Empty Circuit Constructor
CircuitCircuit Copy Constructor Duplicate circuit
Properties
Connectors Observable Collection of Connectors
Devices Observable Collection of devices
Name Circuit Name. Used primarly for subcircuits
Methods
AddConnectionPin, Pin Add connection between two pins.Return None if fail.
AddConnectionPin, PointI Add connection between a pin and a point. Return None if fail.
AddConnectionPointI, Pin Add connection between a point and a pin. Return None if fail.
AddConnectionPointI, PointI Add connection between two points. Return None if fail.
AddDevicestring, int, int, int, bool, bool Add a device instance to the design.
CreateSubsystemIMovable\[\] Replace all the items by a new subcircuit containing them. Try to maintain connections.
GetConnectorAtPointI Return the connector with a connector segment passing through the point. Return None if there is no connector at this location.
GetConnectorConnectedToPin Return the connector connected to p. return None if the pin is not connected.
GetConnectorsConnectedToDevice Return all the connectors connected to a given device.
GetConnectorSegmentsAtPointI, bool Returns the list of connector segments where the distance to the point is zero. Return None if none.
GetDeviceByNamestring Return the device with a given name
GetDevicePinsAtPointI Return the pins located at p. Return empty list if there is no pins
GetDevicesByLibraryItemNamestring Return a list of devices with a given library name Ex: "Resistor"
GetPinsConnectedToPin Return the list of pins connected to this pin through a connector
GetSelectableItemAtPointI Return the selectable item Drawing Elements \+ Connectors
GetSelectableItemsInRectangleI, bool, bool Return the elements contained in the rectangle
GetVariableValuestring Find the variable of the given name and return its value.
IsConnectedPin Return true if the pin is connected to a connector or to another device pin
MoveItemIMovable, PointI Move a single item
MoveItemsList<IMovable>, PointI, int, bool, bool Move a bunch of items in the design. Maintains connections
RemoveConnector Remove the connector from this circuit.
RemoveIMovable Remove item from circuit Device or Connector segment
RemoveICollection<IMovable> Remove a collection of item from the circuit
SetVariableValuestring, string Create or find the variable of the given name and assign the value to it.