Class SubcircuitBindingContext
The binding context for a Subcircuit.
Inherited Members
Namespace: SpiceSharp.Components.Subcircuits
Assembly: SpiceSharp.dll
Syntax
public class SubcircuitBindingContext : ComponentBindingContext, IComponentBindingContext, IBindingContext
Constructors
SubcircuitBindingContext(IComponent, SubcircuitSimulation, IBehaviorContainer)
Initializes a new instance of the SubcircuitBindingContext class.
Declaration
public SubcircuitBindingContext(IComponent component, SubcircuitSimulation simulation, IBehaviorContainer behaviors)
Parameters
Type | Name | Description |
---|---|---|
IComponent | component | The component creating the behavior. |
SubcircuitSimulation | simulation | The simulation for which behaviors are created. |
IBehaviorContainer | behaviors | The behaviors created by the entity. |
Exceptions
Type | Condition |
---|---|
ArgumentNullException | Thrown if |
Properties
Bridges
Gets the node bridges.
Declaration
public IReadOnlyList<Bridge<string>> Bridges { get; }
Property Value
Type | Description |
---|---|
IReadOnlyList<Bridge<string>> | The bridges. |
LocalBehaviors
Gets the current simulation entity behaviors.
Declaration
public IBehaviorContainerCollection LocalBehaviors { get; }
Property Value
Type | Description |
---|---|
IBehaviorContainerCollection |
Methods
AddLocalState<TState>(TState)
Sets the state of the local simulation to another one.
Declaration
public void AddLocalState<TState>(TState state) where TState : ISimulationState
Parameters
Type | Name | Description |
---|---|---|
TState | state | The state. |
Type Parameters
Name | Description |
---|---|
TState | The type of the state. |
GetBehaviors<B>()
Gets the behaviors from the local simulation.
Declaration
public BehaviorList<B> GetBehaviors<B>() where B : IBehavior
Returns
Type | Description |
---|---|
BehaviorList<B> | The list of behaviors. |
Type Parameters
Name | Description |
---|---|
B | The behavior type. |