Class DefaultLogixNGPreferences
- java.lang.Object
-
- jmri.beans.UnboundBean
-
- jmri.beans.Bean
-
- jmri.beans.PreferencesBean
-
- jmri.jmrit.logixng.implementation.DefaultLogixNGPreferences
-
- All Implemented Interfaces:
BeanInterface
,PropertyChangeFirer
,PropertyChangeProvider
,LogixNGPreferences
public final class DefaultLogixNGPreferences extends PreferencesBean implements LogixNGPreferences
Preferences for LogixNG
-
-
Field Summary
-
Fields inherited from class jmri.beans.PreferencesBean
DIRTY, RESTART_REQUIRED
-
Fields inherited from class jmri.beans.Bean
propertyChangeSupport
-
-
Constructor Summary
Constructors Constructor Description DefaultLogixNGPreferences()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
apply(LogixNGPreferences prefs)
Apply other preferences to this classboolean
compareValuesDifferent(LogixNGPreferences prefs)
Compare if the values are different from the other preferences.MaleSocket.ErrorHandlingType
getErrorHandlingType()
Get the default error handling type.boolean
getInstallDebugger()
Get whenether the debugger should be installed or nog.boolean
getShowSystemNameInException()
Get whether system names should be shown or not in exceptions.boolean
getShowSystemUserNames()
Get whenether system names and user names should be visible for actions and expressions.boolean
getStartLogixNGOnStartup()
Get whenether LogixNG should be started when the program starts or a panel is loaded.boolean
getTreeEditorHighlightRow()
Get whether row in tree editor should be highlighted or not.void
save()
Save the preferencesvoid
setErrorHandlingType(MaleSocket.ErrorHandlingType type)
Set the default error handling type.void
setInstallDebugger(boolean value)
Set whenether the debugger should be installed or nog.void
setShowSystemNameInException(boolean value)
Set whether system names should be shown or not in exceptions.void
setShowSystemUserNames(boolean value)
Set whenether system names and user names should be visible for actions and expressions.void
setStartLogixNGOnStartup(boolean value)
Set whenether LogixNG should be started when the program starts or a panel is loaded.void
setTreeEditorHighlightRow(boolean value)
Set whether row in tree editor should be highlighted or not.-
Methods inherited from class jmri.beans.PreferencesBean
firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getProfile, isDirty, isRestartRequired, setIsDirty, setRestartRequired
-
Methods inherited from class jmri.beans.Bean
addPropertyChangeListener, addPropertyChangeListener, fireIndexedPropertyChange, fireIndexedPropertyChange, fireIndexedPropertyChange, getPropertyChangeListeners, getPropertyChangeListeners, isNotifyOnEDT, removePropertyChangeListener, removePropertyChangeListener
-
Methods inherited from class jmri.beans.UnboundBean
getIndexedProperty, getProperty, getPropertyNames, hasIndexedProperty, hasProperty, setIndexedProperty, setProperty
-
-
-
-
Constructor Detail
-
DefaultLogixNGPreferences
public DefaultLogixNGPreferences()
-
-
Method Detail
-
compareValuesDifferent
public boolean compareValuesDifferent(LogixNGPreferences prefs)
Description copied from interface:LogixNGPreferences
Compare if the values are different from the other preferences.- Specified by:
compareValuesDifferent
in interfaceLogixNGPreferences
- Parameters:
prefs
- the other preferences to check- Returns:
- true if preferences differ, false otherwise
-
apply
public void apply(LogixNGPreferences prefs)
Description copied from interface:LogixNGPreferences
Apply other preferences to this class- Specified by:
apply
in interfaceLogixNGPreferences
- Parameters:
prefs
- the other preferences
-
save
public void save()
Description copied from interface:LogixNGPreferences
Save the preferences- Specified by:
save
in interfaceLogixNGPreferences
-
setStartLogixNGOnStartup
public void setStartLogixNGOnStartup(boolean value)
Description copied from interface:LogixNGPreferences
Set whenether LogixNG should be started when the program starts or a panel is loaded.- Specified by:
setStartLogixNGOnStartup
in interfaceLogixNGPreferences
- Parameters:
value
- true if LogixNG should start on program start or when a panel is loaded, false otherwise
-
getStartLogixNGOnStartup
public boolean getStartLogixNGOnStartup()
Description copied from interface:LogixNGPreferences
Get whenether LogixNG should be started when the program starts or a panel is loaded.- Specified by:
getStartLogixNGOnStartup
in interfaceLogixNGPreferences
- Returns:
- true if LogixNG should start on program start or when a panel is loaded, false otherwise
-
setShowSystemUserNames
public void setShowSystemUserNames(boolean value)
Description copied from interface:LogixNGPreferences
Set whenether system names and user names should be visible for actions and expressions.- Specified by:
setShowSystemUserNames
in interfaceLogixNGPreferences
- Parameters:
value
- true if names should be visible, false otherwise
-
getShowSystemUserNames
public boolean getShowSystemUserNames()
Description copied from interface:LogixNGPreferences
Get whenether system names and user names should be visible for actions and expressions.- Specified by:
getShowSystemUserNames
in interfaceLogixNGPreferences
- Returns:
- true if names should be visible, false otherwise
-
setInstallDebugger
public void setInstallDebugger(boolean value)
Description copied from interface:LogixNGPreferences
Set whenether the debugger should be installed or nog.- Specified by:
setInstallDebugger
in interfaceLogixNGPreferences
- Parameters:
value
- true if the debugger should be installed, false otherwise
-
getInstallDebugger
public boolean getInstallDebugger()
Description copied from interface:LogixNGPreferences
Get whenether the debugger should be installed or nog.- Specified by:
getInstallDebugger
in interfaceLogixNGPreferences
- Returns:
- true if the debugger should be installed, false otherwise
-
setErrorHandlingType
public void setErrorHandlingType(MaleSocket.ErrorHandlingType type)
Description copied from interface:LogixNGPreferences
Set the default error handling type.- Specified by:
setErrorHandlingType
in interfaceLogixNGPreferences
- Parameters:
type
- the error handling type
-
getErrorHandlingType
public MaleSocket.ErrorHandlingType getErrorHandlingType()
Description copied from interface:LogixNGPreferences
Get the default error handling type.- Specified by:
getErrorHandlingType
in interfaceLogixNGPreferences
- Returns:
- the error handling type
-
setTreeEditorHighlightRow
public void setTreeEditorHighlightRow(boolean value)
Description copied from interface:LogixNGPreferences
Set whether row in tree editor should be highlighted or not.- Specified by:
setTreeEditorHighlightRow
in interfaceLogixNGPreferences
- Parameters:
value
- true if the row should be highlighted, false otherwise
-
getTreeEditorHighlightRow
public boolean getTreeEditorHighlightRow()
Description copied from interface:LogixNGPreferences
Get whether row in tree editor should be highlighted or not.- Specified by:
getTreeEditorHighlightRow
in interfaceLogixNGPreferences
- Returns:
- true if the row should be highlighted, false otherwise
-
setShowSystemNameInException
public void setShowSystemNameInException(boolean value)
Description copied from interface:LogixNGPreferences
Set whether system names should be shown or not in exceptions.- Specified by:
setShowSystemNameInException
in interfaceLogixNGPreferences
- Parameters:
value
- true if system names should be shown, false otherwise
-
getShowSystemNameInException
public boolean getShowSystemNameInException()
Description copied from interface:LogixNGPreferences
Get whether system names should be shown or not in exceptions.- Specified by:
getShowSystemNameInException
in interfaceLogixNGPreferences
- Returns:
- true if the system names should be shown, false otherwise
-
-