|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjmri.managers.AbstractManager
jmri.TransitManager
public class TransitManager
Implementation of a Transit Manager
This doesn't need an interface, since Transits are globaly implemented, instead of being system-specific.
Note that Transit system names must begin with IZ, and be followed by a string, usually, but not always, a number. All alphabetic characters in a Transit system name must be upper case. This is enforced when a Transit is created.
JMRI is free software; you can redistribute it and/or modify it under the terms of version 2 of the GNU General Public License as published by the Free Software Foundation. See the "COPYING" file for a copy of this license.
JMRI is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
| Field Summary | |
|---|---|
(package private) static TransitManager |
_instance
|
(package private) int |
lastAutoTransitRef
|
(package private) static org.slf4j.Logger |
log
|
(package private) DecimalFormat |
paddedNumber
|
| Fields inherited from class jmri.managers.AbstractManager |
|---|
_tsys, _tuser |
| Fields inherited from interface jmri.Manager |
|---|
AUDIO, BLOCKBOSS, BLOCKS, CONDITIONALS, ENTRYEXIT, IDTAGS, LAYOUTBLOCKS, LIGHTS, LOGIXS, MEMORIES, OBLOCKS, PANELFILES, REPORTERS, ROUTES, SECTIONS, SENSORGROUPS, SENSORS, SIGNALGROUPS, SIGNALHEADS, SIGNALMASTLOGICS, SIGNALMASTS, TIMEBASE, TRANSITS, TURNOUTS, WARRANTS |
| Constructor Summary | |
|---|---|
TransitManager()
|
|
| Method Summary | |
|---|---|
Transit |
createNewTransit(String userName)
For use with User GUI, to allow the auto generation of systemNames, where the user can optionally supply a username. |
Transit |
createNewTransit(String systemName,
String userName)
Method to create a new Transit if the Transit does not exist Returns null if a Transit with the same systemName or userName already exists, or if there is trouble creating a new Transit. |
void |
deleteTransit(Transit z)
Remove an existing Transit |
Transit |
getBySystemName(String name)
|
Transit |
getByUserName(String key)
|
ArrayList<Transit> |
getListUsingSection(Section s)
Returns a list of Transits which use a specified Section |
String |
getSystemPrefix()
Provides access to the system prefix string. |
Transit |
getTransit(String name)
Method to get an existing Transit. |
int |
getXMLOrder()
|
static TransitManager |
instance()
|
char |
typeLetter()
|
| Methods inherited from class jmri.managers.AbstractManager |
|---|
addPropertyChangeListener, deregister, dispose, firePropertyChange, getBeanBySystemName, getBeanByUserName, getInstanceBySystemName, getInstanceByUserName, getNamedBean, getNamedBeanList, getSystemNameArray, getSystemNameList, makeSystemName, propertyChange, register, registerSelf, removePropertyChangeListener, systemLetter |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface java.beans.PropertyChangeListener |
|---|
propertyChange |
| Field Detail |
|---|
DecimalFormat paddedNumber
int lastAutoTransitRef
static TransitManager _instance
static org.slf4j.Logger log
| Constructor Detail |
|---|
public TransitManager()
| Method Detail |
|---|
public int getXMLOrder()
getXMLOrder in interface ManagergetXMLOrder in class AbstractManagerpublic String getSystemPrefix()
Manager
getSystemPrefix in interface Managerpublic char typeLetter()
typeLetter in interface Manager
public Transit createNewTransit(String systemName,
String userName)
public Transit createNewTransit(String userName)
public Transit getTransit(String name)
name -
public Transit getBySystemName(String name)
public Transit getByUserName(String key)
public void deleteTransit(Transit z)
public ArrayList<Transit> getListUsingSection(Section s)
public static TransitManager instance()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||