de.erichseifert.gral.util
Class SettingChangeEvent

java.lang.Object
  extended by java.util.EventObject
      extended by de.erichseifert.gral.util.SettingChangeEvent
All Implemented Interfaces:
Serializable

public class SettingChangeEvent
extends EventObject

Class for handling event data of settings.

See Also:
SettingsListener, Serialized Form

Constructor Summary
SettingChangeEvent(Object source, Settings.Key key, Object valOld, Object valNew, boolean defaultSetting)
          Creates a new event object with the specified values.
 
Method Summary
 Settings.Key getKey()
          Returns the key of the changed setting.
 Object getValNew()
          Returns the new value.
 Object getValOld()
          Returns the old value.
 boolean isDefaultSetting()
          Returns whether the setting is a default setting.
 
Methods inherited from class java.util.EventObject
getSource, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SettingChangeEvent

public SettingChangeEvent(Object source,
                          Settings.Key key,
                          Object valOld,
                          Object valNew,
                          boolean defaultSetting)
Creates a new event object with the specified values.

Parameters:
source - The object on which the Event initially occurred.
key - Key of the setting.
valOld - Old value.
valNew - New value.
defaultSetting - true if a default setting has changed.
Method Detail

getKey

public Settings.Key getKey()
Returns the key of the changed setting.

Returns:
Key.

getValOld

public Object getValOld()
Returns the old value.

Returns:
Old value

getValNew

public Object getValNew()
Returns the new value.

Returns:
New value

isDefaultSetting

public boolean isDefaultSetting()
Returns whether the setting is a default setting.

Returns:
true or false


Copyright © 2009-2010. All Rights Reserved.