Class RenderSettingsEvent

java.lang.Object
com.google.web.bindery.event.shared.Event<RenderSettingsEvent.Handler>
com.google.gwt.event.shared.GwtEvent<RenderSettingsEvent.Handler>
com.levigo.jadice.web.client.event.JadiceEvent<RenderSettingsEvent.Handler>
com.levigo.jadice.web.client.settings.RenderSettingsEvent

public class RenderSettingsEvent extends JadiceEvent<RenderSettingsEvent.Handler>
This event gets delivered whenever a RenderSettings property change happens.

This event provides access to the name, the old and new value of the changed property. If the new value is a primitive type (such as int or boolean) it must be wrapped as the corresponding java.lang.* object type (such as Integer or Boolean).

Null values may be provided for the old and the new values if their true values are not known.

A reference of the changed RenderSettings can be obtained by a call of JadiceEvent.getSource(). If available, the RenderControls instance which the render setting belongs to can be accessed by a call of getSourceControls().

The types of render settings which support change event propagation are descendants of AbstractListenableRenderSettings.

  • Constructor Details

    • RenderSettingsEvent

      public RenderSettingsEvent(RenderControls parent, RenderSettings renderSettings, String propertyName, Object oldValue, Object newValue, com.google.gwt.event.shared.HasHandlers source)
      Constructor
      Parameters:
      parent - the render controls the changed render settings object belongs to
      propertyName - the name of the changed property
      oldValue - the old value of the property
      newValue - the new value of the property
      source - the changed render settings object
    • RenderSettingsEvent

      public RenderSettingsEvent(RenderControls parent, RenderSettings renderSettings, String propertyName, Object oldValue, Object newValue, com.google.gwt.event.shared.HasHandlers source, Page page)
      Constructor with page parameter
      Parameters:
      parent - the render controls the changed render settings object belongs to
      propertyName - the name of the changed property
      oldValue - the old value of the property
      newValue - the new value of the property
      source - the changed render settings object
      page - the page associated with the event
    • RenderSettingsEvent

      public RenderSettingsEvent(RenderSettingsEvent evt)
      Copy constructor
      Parameters:
      evt - the event which should be copied
  • Method Details

    • getType

    • getRenderSettings

      public RenderSettings getRenderSettings()
      Returns the source which caused this event.
      Returns:
      the RenderSettings instance that caused this event
    • getSourceControls

      public RenderControls getSourceControls()
      Returns the RenderControls instance the source RenderSettings belongs to. May be null if unknown.
      Returns:
      the RenderControls instance the source belongs to
    • getPropertyName

      public String getPropertyName()
      Gets the name of the setting that was changed.
      Returns:
      The name of the setting that was changed.
    • getNewValue

      public Object getNewValue()
      Gets the new value of the changed setting, expressed as an Object.
      Returns:
      The new value, expressed as an Object.
    • getOldValue

      public Object getOldValue()
      Gets the old value of the changed setting, expressed as an Object.
      Returns:
      The old value, expressed as an Object.
    • getPage

      public Page getPage()
      Gets the page which is associated with the event.
      Returns:
      The page of the event
    • toString

      public String toString()
      Overrides:
      toString in class com.google.web.bindery.event.shared.Event<RenderSettingsEvent.Handler>
    • paramString

      public String paramString()
      Returns a parameter string identifying this event. This method is useful for event-logging and for debugging.
      Returns:
      a string identifying the event and its attributes
    • getAssociatedType

      public final JadiceEvent.Type<RenderSettingsEvent.Handler> getAssociatedType()
      Specified by:
      getAssociatedType in class com.google.gwt.event.shared.GwtEvent<RenderSettingsEvent.Handler>
    • dispatch

      protected void dispatch(RenderSettingsEvent.Handler handler)
      Specified by:
      dispatch in class com.google.gwt.event.shared.GwtEvent<RenderSettingsEvent.Handler>