jmri.jmrix.rps
Class Transmitter

java.lang.Object
  extended by jmri.jmrix.rps.Transmitter
All Implemented Interfaces:
EventListener, ThrottleListener

public class Transmitter
extends Object
implements ThrottleListener

Represents a RPS transmitter, generally a locomotive.

The "ID" is used to identify this transmitter in RPS. The "rosterName" is the name (ID) of the roster entry this was originally created from.

Author:
Bob Jacobsen Copyright (C) 2006, 2008

Method Summary
 int getAddress()
           
 String getID()
           
 Measurement getLastMeasurement()
           
 String getRosterName()
           
 boolean isLongAddress()
           
 boolean isPolled()
           
 void notifyFailedThrottleRequest(DccLocoAddress address, String reason)
          Get notification that an attempt to request a throttle has failed
 void notifyThrottleFound(DccThrottle t)
          Get notification that a throttle has been found as you requested.
 void setAddress(int address)
           
 void setID(String id)
           
 void setLastMeasurement(Measurement last)
           
 void setLongAddress(boolean longAddress)
           
 void setPolled(boolean polled)
           
 void setRosterName(String rosterName)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getID

public String getID()

setID

public void setID(String id)

getRosterName

public String getRosterName()

setRosterName

public void setRosterName(String rosterName)

isLongAddress

public boolean isLongAddress()

setLongAddress

public void setLongAddress(boolean longAddress)

getAddress

public int getAddress()

setAddress

public void setAddress(int address)

isPolled

public boolean isPolled()

setPolled

public void setPolled(boolean polled)

setLastMeasurement

public void setLastMeasurement(Measurement last)

getLastMeasurement

public Measurement getLastMeasurement()

notifyThrottleFound

public void notifyThrottleFound(DccThrottle t)
Description copied from interface: ThrottleListener
Get notification that a throttle has been found as you requested.

Specified by:
notifyThrottleFound in interface ThrottleListener
Parameters:
t - An instantiation of the DccThrottle with the address requested.

notifyFailedThrottleRequest

public void notifyFailedThrottleRequest(DccLocoAddress address,
                                        String reason)
Description copied from interface: ThrottleListener
Get notification that an attempt to request a throttle has failed

Specified by:
notifyFailedThrottleRequest in interface ThrottleListener
Parameters:
address - DccLocoAddress of the failed loco request.
reason - The reason why the throttle request failed.


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