Package jmri
Interface SystemConnectionMemo
- All Superinterfaces:
PropertyChangeProvider
- All Known Subinterfaces:
ConfiguringSystemConnectionMemo
- All Known Implementing Classes:
AcelaSystemConnectionMemo,AnymaDMX_SystemConnectionMemo,BiDiBSystemConnectionMemo,CanSystemConnectionMemo,CaptiveSystemConnectionMemo,CdBSystemConnectionMemo,CMRISystemConnectionMemo,Dcc4PcSystemConnectionMemo,DCCppSystemConnectionMemo,DefaultSystemConnectionMemo,DirectSystemConnectionMemo,EasyDccSystemConnectionMemo,EcosSystemConnectionMemo,EliteXNetSystemConnectionMemo,GrapevineSystemConnectionMemo,HexFileSystemConnectionMemo,IEEE802154SystemConnectionMemo,InternalSystemConnectionMemo,IpocsSystemConnectionMemo,JMRIClientSystemConnectionMemo,LocoNetSystemConnectionMemo,MapleSystemConnectionMemo,MarklinSystemConnectionMemo,MqttSystemConnectionMemo,MrcSystemConnectionMemo,Mx1SystemConnectionMemo,NceSystemConnectionMemo,OakTreeSystemConnectionMemo,PR2SystemConnectionMemo,PR3SystemConnectionMemo,PR4SystemConnectionMemo,QsiSystemConnectionMemo,RaspberryPiSystemConnectionMemo,RfidSystemConnectionMemo,RpsSystemConnectionMemo,SecsiSystemConnectionMemo,SerialSystemConnectionMemo,SerialSystemConnectionMemo,SpecificSystemConnectionMemo,SpecificSystemConnectionMemo,SpecificSystemConnectionMemo,SpecificSystemConnectionMemo,SpecificSystemConnectionMemo,SpeedoSystemConnectionMemo,SprogSystemConnectionMemo,SRCPBusConnectionMemo,SRCPSystemConnectionMemo,TamsSystemConnectionMemo,TmccSystemConnectionMemo,UhlenbrockSystemConnectionMemo,UsbDcs210PlusSystemConnectionMemo,UsbDcs240PlusSystemConnectionMemo,UsbDcs240SystemConnectionMemo,UsbDcs52SystemConnectionMemo,XBeeConnectionMemo,XNetSystemConnectionMemo,XpaSystemConnectionMemo,Z21SystemConnectionMemo
Lightweight interface denoting that a system is active, and provide
general information.
Objects of specific subtypes of this are registered in the
InstanceManager to activate their particular system.
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionvoiddispose()<T> TGet a manager for a specific type.Provide a factory for getting startup actions.intGet the Default connection specific OutputInterval to wait between/before commands are sent.booleanGet if the System Connection is currently Disabled.<B extends NamedBean>
Comparator<B>getNamedBeanComparator(Class<B> type) Get the Comparator to be used for two NamedBeans.intGet the connection specific OutputInterval to wait between/before commands are sent, configured in AdapterConfig.Provide access to the system prefix string.Provide access to the system user name string.booleanisDirty()Get if connection is dirty.booleanbooleanCheck if this connection provides a specific manager type.voidregister()Store in InstanceManager with proper ID for later retrieval as a generic system.voidsetDisabled(boolean disabled) Set if the System Connection is currently Disabled.voidsetOutputInterval(int newInterval) booleansetSystemPrefix(String systemPrefix) Set the system prefix.booleansetUserName(String userName) Set the user name for the system connection.Methods inherited from interface jmri.beans.PropertyChangeProvider
addPropertyChangeListener, addPropertyChangeListener, getPropertyChangeListeners, getPropertyChangeListeners, removePropertyChangeListener, removePropertyChangeListener
-
Field Details
-
DISABLED
- See Also:
-
USER_NAME
- See Also:
-
SYSTEM_PREFIX
- See Also:
-
INTERVAL
- See Also:
-
STORE
- See Also:
-
DEREGISTER
- See Also:
-
-
Method Details
-
dispose
void dispose() -
get
Get a manager for a specific type. This method must return a non-null value ifprovides(java.lang.Class)is true for the type, and must return null if provides() is false for the type.- Type Parameters:
T- Type of manager to get- Parameters:
type- Type of manager to get- Returns:
- The manager or null if provides() is false for T
- See Also:
-
getActionFactory
Provide a factory for getting startup actions.This is a bound, read-only, property under the name "actionFactory".
- Returns:
- the factory
-
getDisabled
boolean getDisabled()Get if the System Connection is currently Disabled.- Returns:
- true if Disabled, else false.
-
getNamedBeanComparator
Get the Comparator to be used for two NamedBeans. This is typically anNamedBeanComparator, but may be any Comparator that works for this connection type.- Type Parameters:
B- the type of NamedBean- Parameters:
type- the class of NamedBean- Returns:
- the Comparator
-
getSystemPrefix
Provide access to the system prefix string.This was previously called the "System letter".
- Returns:
- System prefix
-
getUserName
Provide access to the system user name string.This was previously fixed at configuration time.
- Returns:
- User name of the connection
-
isDirty
boolean isDirty()Get if connection is dirty. Checked fields are disabled, prefix, userName- Returns:
- true if changed since loaded
-
isRestartRequired
boolean isRestartRequired() -
provides
Check if this connection provides a specific manager type. This method must return false if a manager for the specific type is not provided, and must return true if a manager for the specific type is provided.- Parameters:
c- The class type for the manager to be provided- Returns:
- true if the specified manager is provided
- See Also:
-
register
void register()Store in InstanceManager with proper ID for later retrieval as a generic system. -
setDisabled
Set if the System Connection is currently Disabled.disabledAsLoaded is only set once. Sends PropertyChange on change of disabled status.
- Parameters:
disabled- true to disable, false to enable.
-
setSystemPrefix
Set the system prefix.- Parameters:
systemPrefix- prefix to use for this system connection- Returns:
- true if the system prefix could be set
- Throws:
NullPointerException- if systemPrefix is null
-
setUserName
Set the user name for the system connection.- Parameters:
userName- user name to use for this system connection- Returns:
- true if the user name could be set
- Throws:
NullPointerException- if name is null
-
getOutputInterval
int getOutputInterval()Get the connection specific OutputInterval to wait between/before commands are sent, configured in AdapterConfig. Used inAbstractTurnout.setCommandedStateAtInterval(int).- Returns:
- the output interval time in ms
-
getDefaultOutputInterval
int getDefaultOutputInterval()Get the Default connection specific OutputInterval to wait between/before commands are sent.- Returns:
- the default output interval time in ms.
-
setOutputInterval
-