jmri.jmrix.loconet.pr2
Class LnPr2PowerManager

java.lang.Object
  extended by jmri.managers.AbstractPowerManager
      extended by jmri.jmrix.loconet.LnPowerManager
          extended by jmri.jmrix.loconet.pr2.LnPr2PowerManager
All Implemented Interfaces:
EventListener, LocoNetListener, PowerManager

public class LnPr2PowerManager
extends LnPowerManager

PowerManager implementation for controlling layout power via PR2

Some of the message formats used in this class are Copyright Digitrax, Inc. and used with permission as part of the JMRI project. That permission does not extend to uses in other software products. If you wish to use this code, algorithm or these message formats outside of JMRI, please contact Digitrax Inc for separate permission.

Author:
Bob Jacobsen Copyright (C) 2001

Field Summary
 
Fields inherited from class jmri.jmrix.loconet.LnPowerManager
power
 
Fields inherited from interface jmri.PowerManager
OFF, ON, UNKNOWN
 
Constructor Summary
LnPr2PowerManager(LocoNetSystemConnectionMemo memo)
           
 
Method Summary
 void dispose()
           
 void message(LocoNetMessage m)
          Member function that will be invoked by a LocoNetInterface implementation to forward a LocoNet message from the layout.
 void setPower(int v)
           
 
Methods inherited from class jmri.jmrix.loconet.LnPowerManager
getPower
 
Methods inherited from class jmri.managers.AbstractPowerManager
addPropertyChangeListener, firePropertyChange, getUserName, removePropertyChangeListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface jmri.PowerManager
addPropertyChangeListener, getUserName, removePropertyChangeListener
 

Constructor Detail

LnPr2PowerManager

public LnPr2PowerManager(LocoNetSystemConnectionMemo memo)
Method Detail

setPower

public void setPower(int v)
              throws JmriException
Specified by:
setPower in interface PowerManager
Overrides:
setPower in class LnPowerManager
Throws:
JmriException

dispose

public void dispose()
Specified by:
dispose in interface PowerManager
Overrides:
dispose in class LnPowerManager

message

public void message(LocoNetMessage m)
Description copied from interface: LocoNetListener
Member function that will be invoked by a LocoNetInterface implementation to forward a LocoNet message from the layout.

Specified by:
message in interface LocoNetListener
Overrides:
message in class LnPowerManager
Parameters:
m - The received LocoNet message. Note that this same object may be presented to multiple users. It should not be modified here.


Copyright © 1997 - 2011 JMRI Community.
JMRI, DecoderPro, PanelPro, SoundPro, DispatcherPro and associated logos are our trademarks.

Additional information on copyright, trademarks and licenses is linked here.
Site hosted by: Get JMRI Model Railroad Interface at SourceForge.net. Fast, secure and Free Open Source software downloads