jmri.progdebugger
Class DebugProgrammerManager

java.lang.Object
  extended by jmri.managers.DefaultProgrammerManager
      extended by jmri.progdebugger.DebugProgrammerManager
All Implemented Interfaces:
ProgrammerManager

public class DebugProgrammerManager
extends DefaultProgrammerManager

Provides an implementation of ProgrammerManager for the debug programmer. It will consistently return the same ProgDebugger instance for a given request.

It uses the DefaultProgrammerManager to handle the service mode operations.

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

Constructor Summary
DebugProgrammerManager()
           
 
Method Summary
 Programmer getAddressedProgrammer(boolean pLongAddress, int pAddress)
          Gain access to a Addressed Mode Programmer without reservation.
 boolean isAddressedModePossible()
          Debug programmer does provide Ops Mode
 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, isGlobalProgrammerAvailable, releaseAddressedProgrammer, releaseGlobalProgrammer, reserveGlobalProgrammer
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DebugProgrammerManager

public DebugProgrammerManager()
Method Detail

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

isAddressedModePossible

public boolean isAddressedModePossible()
Debug programmer does provide Ops Mode

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


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