Interface CatalogTreeManager
- All Superinterfaces:
Manager<CatalogTree>,PropertyChangeProvider,SilenceablePropertyChangeProvider,VetoableChangeProvider
- All Known Implementing Classes:
DefaultCatalogTreeManager
CatalogTree objects are obtained from a CatalogTreeManager, which in turn is generally located from the InstanceManager.
Much of the book-keeping is implemented in the AbstractCatalogTreeManager class, which can form the basis for a system-specific implementation.
This file is part of JMRI.
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.
-
Nested Class Summary
Nested classes/interfaces inherited from interface jmri.Manager
Manager.ManagerDataEvent<E extends NamedBean>, Manager.ManagerDataListener<E extends NamedBean>, Manager.NameValidity -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String[]static final String[]static final String[]Fields inherited from interface jmri.Manager
ANALOGIOS, AUDIO, BLOCKBOSS, BLOCKS, CONDITIONALS, CTCDATA, ENTRYEXIT, IDTAGS, LAYOUTBLOCKS, LIGHTS, LOGIXNG_ANALOG_ACTIONS, LOGIXNG_ANALOG_EXPRESSIONS, LOGIXNG_CONDITIONALNGS, LOGIXNG_DIGITAL_ACTIONS, LOGIXNG_DIGITAL_BOOLEAN_ACTIONS, LOGIXNG_DIGITAL_EXPRESSIONS, LOGIXNG_GLOBAL_VARIABLES, LOGIXNG_MODULES, LOGIXNG_STRING_ACTIONS, LOGIXNG_STRING_EXPRESSIONS, LOGIXNG_TABLES, LOGIXNGS, LOGIXS, MEMORIES, METERFRAMES, METERS, OBLOCKS, PANELFILES, PROPERTY_BEANS, PROPERTY_CAN_DELETE, PROPERTY_DISPLAY_LIST_NAME, PROPERTY_DO_DELETE, PROPERTY_DO_NOT_DELETE, PROPERTY_LENGTH, REPORTERS, ROUTES, SECTIONS, SENSORGROUPS, SENSORS, SIGNALGROUPS, SIGNALHEADS, SIGNALMASTLOGICS, SIGNALMASTS, STRINGIOS, TIMEBASE, TRANSITS, TURNOUTS, WARRANTS -
Method Summary
Modifier and TypeMethodDescriptiongetBySystemName(String systemName) Locate an instance based on a system name.getByUserName(String userName) Locate an instance based on a user name.getCatalogTree(String name) Locate via user name, then system name if needed.voidindexChanged(boolean changed) booleanbooleanvoidnewCatalogTree(String systemName, String userName) Get a CatalogTree instance with the specified system and user names.voidMethods inherited from interface jmri.Manager
addDataListener, deleteBean, deregister, dispose, getBeanTypeHandled, getBeanTypeHandled, getEntryToolTip, getKnownBeanProperties, getMemo, getNamedBean, getNamedBeanClass, getNamedBeanSet, getObjectCount, getSubSystemNamePrefix, getSystemNamePrefix, getSystemPrefix, getXMLOrder, isValidSystemNameFormat, makeSystemName, makeSystemName, makeSystemName, register, removeDataListener, setDataListenerMute, typeLetter, validateBadCharsInSystemNameFormat, validateIntegerSystemNameFormat, validateNmraAccessorySystemNameFormat, validateSystemNameFormat, validateSystemNameFormat, validateSystemNameFormatOnlyNumeric, validateSystemNamePrefix, validateTrimmedMin1NumberSystemNameFormat, validateTrimmedSystemNameFormat, validateUppercaseTrimmedSystemNameFormat, validSystemNameFormatMethods inherited from interface jmri.beans.PropertyChangeProvider
addPropertyChangeListener, addPropertyChangeListener, getPropertyChangeListeners, getPropertyChangeListeners, removePropertyChangeListener, removePropertyChangeListenerMethods inherited from interface jmri.beans.SilenceablePropertyChangeProvider
setPropertyChangesSilencedMethods inherited from interface jmri.beans.VetoableChangeProvider
addVetoableChangeListener, addVetoableChangeListener, getVetoableChangeListeners, getVetoableChangeListeners, removeVetoableChangeListener, removeVetoableChangeListener
-
Field Details
-
IMAGE_FILTER
-
SOUND_FILTER
-
SCRIPT_FILTER
-
-
Method Details
-
getCatalogTree
Locate via user name, then system name if needed. If that fails, return null- Parameters:
name- CatalogTree object to locate- Returns:
- null if no match found
-
getBySystemName
Locate an instance based on a system name. Returns null if no instance already exists.- Specified by:
getBySystemNamein interfaceManager<CatalogTree>- Parameters:
systemName- CatalogTree object to locate- Returns:
- requested CatalogTree object or null if none exists
-
getByUserName
Locate an instance based on a user name. Returns null if no instance already exists.- Specified by:
getByUserNamein interfaceManager<CatalogTree>- Parameters:
userName- CatalogTree object to locate- Returns:
- requested CatalogTree object or null if none exists
-
newCatalogTree
@Nonnull CatalogTree newCatalogTree(@Nonnull String systemName, String userName) throws IllegalArgumentException Get a CatalogTree instance with the specified system and user names. Note that two calls with the same arguments will get the same instance; there is only one CatalogTree object representing a given physical CatalogTree and therefore only one with a specific system or user name.This will always return a valid object reference; a new object will be created if necessary. In that case:
- If a null reference is given for user name, no user name will be associated with the CatalogTree object created; a valid system name must be provided
- If both names are provided, the system name defines the hardware access of the desired CatalogTree, and the user address is associated with it. The system name must be valid.
- Parameters:
systemName- system name for new CatalogTreeuserName- user name for new CatalogTree- Returns:
- requested CatalogTree object (never null)
- Throws:
IllegalArgumentException- if unable to create.
-
storeImageIndex
void storeImageIndex() -
loadImageIndex
void loadImageIndex() -
isIndexChanged
boolean isIndexChanged() -
isIndexLoaded
boolean isIndexLoaded() -
indexChanged
-