jmri.jmrix.nce
Class NceProgrammerManager

java.lang.Object
  extended by jmri.managers.DefaultProgrammerManager
      extended by jmri.jmrix.nce.NceProgrammerManager
All Implemented Interfaces:
ProgrammerManager

public class NceProgrammerManager
extends DefaultProgrammerManager

Extend DefaultProgrammerManager to provide ops mode programmers for NCE systems

Author:
Bob Jacobsen Copyright (C) 2002
See Also:
ProgrammerManager

Constructor Summary
NceProgrammerManager(NceTrafficController tc, Programmer serviceModeProgrammer)
           
 
Method Summary
 Programmer getAddressedProgrammer(boolean pLongAddress, int pAddress)
          Gain access to a Addressed Mode Programmer without reservation.
 boolean isAddressedModePossible()
          Works with command station to provide Ops Mode, so say it works
 boolean isGlobalProgrammerAvailable()
          Works with PH command station to provide Service Mode and USB connect to PowerCab.
 Programmer reserveAddressedProgrammer(boolean pLongAddress, int pAddress)
          Gain access to a (the) Addressed Mode Programmer, in the process reserving it for yourself.
 
Methods inherited from class jmri.managers.DefaultProgrammerManager
getGlobalProgrammer, releaseAddressedProgrammer, releaseGlobalProgrammer, reserveGlobalProgrammer
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NceProgrammerManager

public NceProgrammerManager(NceTrafficController tc,
                            Programmer serviceModeProgrammer)
Method Detail

isAddressedModePossible

public boolean isAddressedModePossible()
Works with command station to provide Ops Mode, so say it works

Specified by:
isAddressedModePossible in interface ProgrammerManager
Overrides:
isAddressedModePossible in class DefaultProgrammerManager
Returns:
true

isGlobalProgrammerAvailable

public boolean isGlobalProgrammerAvailable()
Works with PH command station to provide Service Mode and USB connect to PowerCab.

Specified by:
isGlobalProgrammerAvailable in interface ProgrammerManager
Overrides:
isGlobalProgrammerAvailable in class DefaultProgrammerManager
Returns:
true if not USB connect to SB3

getAddressedProgrammer

public Programmer getAddressedProgrammer(boolean pLongAddress,
                                         int pAddress)
Description copied from interface: ProgrammerManager
Gain access to a Addressed Mode Programmer without reservation.

Specified by:
getAddressedProgrammer in interface ProgrammerManager
Overrides:
getAddressedProgrammer in class DefaultProgrammerManager
Parameters:
pLongAddress - true if this is a long (14 bit) address, else false
pAddress - Specific decoder address to use.
Returns:
null only if there isn't an Ops Mode Programmer in the system

reserveAddressedProgrammer

public Programmer reserveAddressedProgrammer(boolean pLongAddress,
                                             int pAddress)
Description copied from interface: ProgrammerManager
Gain access to a (the) Addressed Mode Programmer, in the process reserving it for yourself.

Specified by:
reserveAddressedProgrammer in interface ProgrammerManager
Overrides:
reserveAddressedProgrammer in class DefaultProgrammerManager
Parameters:
pLongAddress - true if this is a long (14 bit) address, else false
pAddress - Specific decoder address to use.
Returns:
null if the address is in use by a reserved programmer


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