Package empro :: Module empro :: Module components :: Class Switch
[frames] | no frames]

Class Switch

core.Updatable --+            
                 |            
   core.Selectable --+        
                     |        
 datasource.DataSource --+    
                         |    
CircuitComponentDefinition --+
                             |
                            Switch

A concrete component definition to model multiple transition between open and closed circuits.

Class Hierarchy for Switch
Class Hierarchy for Switch

constructor Switch():

constructor Switch(iName):

Instance Methods
None
addStateTransition(iStartTime, iDuration)
Add a state transition of the switch definition.
list{int}
indexOrder()
Returns a list with transition indices.
None
insertStateTransition(iIndex, iStartTime, iDuration)
Inserts a state transition of the switch definition.
int
numberOfStateTransitions()
The number of state transitions.
None
removeStateTransition(iIndex)
Removes a state transition from the switch definition.
None
replaceStateTransition(iIndex, iStartTime, iDuration)
Replaces a state transition of the switch definition.
 
setStateTransitionDuration(...)
No documentation available.
None
setStateTransitionStartTime(iIndex, iStartTime)
Set the start time of a transition.
None
swapStateTransition(iIndex1, iIndex2)
Swaps two state transitions.
Expression
transitionDuration(iIndex)
The duration of the given transition.
Expression
transitionStartTime(iIndex)
The start time of the given transition.
 
transitionType(iIndex)
The type of the given transition.

Inherited from datasource.DataSource: dataSet, dataSetIds, dataSets, variableIds, variables

Inherited from core.Selectable: clone, isSelected

Inherited from core.Updatable: __enter__, __exit__, hash, isValid, reasonWhyInvalid

Properties
stringNone initialState
The initial state of the switch.

Inherited from core.Selectable: metaData, name, notes

Method Details

addStateTransition(iStartTime, iDuration)

 

Add a state transition of the switch definition. The type of transition is Opening if the state was already closed and vice versa.

Parameters:
  • iStartTime (Expression) - Start of the transition.
  • iDuration (Expression) - Duration of the transition.
Returns: None

insertStateTransition(iIndex, iStartTime, iDuration)

 

Inserts a state transition of the switch definition. The type of transition is Opening if the state was already closed and vice versa.

Parameters:
  • iIndex (int) - Index of where to insert the transition.
  • iStartTime (Expression) - Start of the transition.
  • iDuration (Expression) - Duration of the transition.
Returns: None

removeStateTransition(iIndex)

 

Removes a state transition from the switch definition.

Parameters:
  • iIndex (int) - Index of the transition to remove.
Returns: None

replaceStateTransition(iIndex, iStartTime, iDuration)

 

Replaces a state transition of the switch definition. The type of transition is Opening if the state was already closed and vice versa.

Parameters:
  • iIndex (int) - Index of the transition to replace.
  • iStartTime (Expression) - Start of the transition.
  • iDuration (Expression) - Duration of the transition.
Returns: None

setStateTransitionStartTime(iIndex, iStartTime)

 

Set the start time of a transition.

Parameters:
  • iIndex (int) - Index of the transition.
  • iStartTime (Expression) - New start time of the transition.
Returns: None

swapStateTransition(iIndex1, iIndex2)

 

Swaps two state transitions.

Parameters:
  • iIndex1 (int) - Index of the first transition.
  • iIndex2 (int) - Index of the second transition.
Returns: None

transitionDuration(iIndex)

 

The duration of the given transition.

Parameters:
  • iIndex (int) - Index of the transition.
Returns: Expression

transitionStartTime(iIndex)

 

The start time of the given transition.

Parameters:
  • iIndex (int) - Index of the transition.
Returns: Expression

transitionType(iIndex)

 
The type of the given transition. L{Undefined,Opening,Closing}
@type iIndex: int
@param iIndex: Index of the transition.
@rtype: string
@param: None


Property Details

initialState

The initial state of the switch. {Open,Closed}

Type:
stringNone