Class StepControlController
- java.lang.Object
-
- org.bidib.wizard.mvc.stepcontrol.controller.StepControlController
-
- All Implemented Interfaces:
org.bidib.wizard.api.model.listener.CvDefinitionListener,org.bidib.wizard.api.model.listener.PortListListener,AccessoryRequestListener,StepControlControllerInterface
public class StepControlController extends Object implements org.bidib.wizard.api.model.listener.CvDefinitionListener, StepControlControllerInterface, org.bidib.wizard.api.model.listener.PortListListener
-
-
Field Summary
-
Fields inherited from interface org.bidib.wizard.mvc.stepcontrol.controller.StepControlControllerInterface
ACCESSORY_ID_CONTROLLING, ACCESSORY_ID_OPERATING, ACCESSORY_ID_SOUND, ASPECT_ID_HOMING, ASPECT_ID_OPERATING, MAX_CONFIGURED_ASPECTS
-
-
Constructor Summary
Constructors Constructor Description StepControlController(MainModel mainModel, FeedbackPortStatusChangeProvider feedbackPortStatusChangeProvider, StatusBar statusBar)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidactivateAspect(org.bidib.wizard.api.model.Accessory accessory, int aspectNumber)Activate the aspect.voidcvDefinitionChanged()voidcvDefinitionValuesChanged(boolean read, List<String> changedNames)StepControlPanelgetComponent()com.jgoodies.common.collect.ArrayListModel<StepControlAspect>getConfigureAspectsListModel()Class<?>getPortClass()org.bidib.wizard.api.model.NodeInterfacegetSelectedNode()voidlistChanged()voidrefreshPorts()voidscheduleAccessoryStateCheck()voidsetMotorPortValue(org.bidib.wizard.model.ports.MotorPort motorPort)Set the new value of the motor port.voidsetSoundActive(boolean soundActive)Set the sound active or mute.voidstart(TabStatusListener tabStatusListener)voidstoreAccessory(org.bidib.wizard.api.model.Accessory accessory)Store the accessory on the node.voidtriggerLoadCvValues()Trigger load the CV values of the step control.voidtriggerSoundPort(int portId, org.bidib.wizard.model.status.SoundPortStatus soundPortStatus)
-
-
-
Constructor Detail
-
StepControlController
public StepControlController(MainModel mainModel, FeedbackPortStatusChangeProvider feedbackPortStatusChangeProvider, StatusBar statusBar)
-
-
Method Detail
-
start
public void start(TabStatusListener tabStatusListener)
-
getComponent
public StepControlPanel getComponent()
-
triggerLoadCvValues
public void triggerLoadCvValues()
Description copied from interface:StepControlControllerInterfaceTrigger load the CV values of the step control.- Specified by:
triggerLoadCvValuesin interfaceStepControlControllerInterface
-
cvDefinitionChanged
public void cvDefinitionChanged()
- Specified by:
cvDefinitionChangedin interfaceorg.bidib.wizard.api.model.listener.CvDefinitionListener
-
cvDefinitionValuesChanged
public void cvDefinitionValuesChanged(boolean read, List<String> changedNames)- Specified by:
cvDefinitionValuesChangedin interfaceorg.bidib.wizard.api.model.listener.CvDefinitionListener
-
getConfigureAspectsListModel
public com.jgoodies.common.collect.ArrayListModel<StepControlAspect> getConfigureAspectsListModel()
- Specified by:
getConfigureAspectsListModelin interfaceStepControlControllerInterface- Returns:
- the list model of aspects
-
getSelectedNode
public org.bidib.wizard.api.model.NodeInterface getSelectedNode()
-
scheduleAccessoryStateCheck
public void scheduleAccessoryStateCheck()
-
setMotorPortValue
public void setMotorPortValue(org.bidib.wizard.model.ports.MotorPort motorPort)
Description copied from interface:StepControlControllerInterfaceSet the new value of the motor port.- Specified by:
setMotorPortValuein interfaceStepControlControllerInterface- Parameters:
motorPort- the motor port
-
getPortClass
public Class<?> getPortClass()
- Specified by:
getPortClassin interfaceorg.bidib.wizard.api.model.listener.PortListListener
-
triggerSoundPort
public void triggerSoundPort(int portId, org.bidib.wizard.model.status.SoundPortStatus soundPortStatus)- Specified by:
triggerSoundPortin interfaceStepControlControllerInterface- Parameters:
portId- the sound port to triggersoundPortStatus- the sound port status
-
listChanged
public void listChanged()
- Specified by:
listChangedin interfaceorg.bidib.wizard.api.model.listener.PortListListener
-
refreshPorts
public void refreshPorts()
- Specified by:
refreshPortsin interfaceorg.bidib.wizard.api.model.listener.PortListListener
-
setSoundActive
public void setSoundActive(boolean soundActive)
Description copied from interface:StepControlControllerInterfaceSet the sound active or mute.- Specified by:
setSoundActivein interfaceStepControlControllerInterface- Parameters:
soundActive- the sound active flag
-
activateAspect
public void activateAspect(org.bidib.wizard.api.model.Accessory accessory, int aspectNumber)Description copied from interface:AccessoryRequestListenerActivate the aspect.- Specified by:
activateAspectin interfaceAccessoryRequestListener- Parameters:
accessory- the accessoryaspectNumber- the aspect number
-
storeAccessory
public void storeAccessory(org.bidib.wizard.api.model.Accessory accessory)
Description copied from interface:AccessoryRequestListenerStore the accessory on the node.- Specified by:
storeAccessoryin interfaceAccessoryRequestListener- Parameters:
accessory- the accessory
-
-