org.apache.tapestry5.internal.services

## Class LinkDecorationListener

- java.lang.Object
- - org.apache.tapestry5.internal.services.LinkDecorationListener

- All Implemented Interfaces:
    LinkCreationListener2

      public class LinkDecorationListener
      extends Object
      implements LinkCreationListener2

  A default `LinkCreationListener2` that triggers the `EventConstants.DECORATE_COMPONENT_EVENT_LINK` and `EventConstants.DECORATE_PAGE_RENDER_LINK` events as links are generated.
  Since:
    5.2.0

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `LinkDecorationListener(ComponentClassResolver resolver, ComponentSource componentSource, ComponentModelSource modelSource)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `createdComponentEventLink(Link link, ComponentEventRequestParameters parameters)` Invoked when an action link (a link that asks a component to perform an action) is created.
    `void` | `createdPageRenderLink(Link link, PageRenderRequestParameters parameters)` Invoked when a page link (a link that renders a page) is created.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### LinkDecorationListener

          public LinkDecorationListener(ComponentClassResolver resolver,
                                        ComponentSource componentSource,
                                        ComponentModelSource modelSource)

  - ### Method Detail

    - #### createdComponentEventLink

          public void createdComponentEventLink(Link link,
                                                ComponentEventRequestParameters parameters)

      Description copied from interface: `LinkCreationListener2`
      Invoked when an action link (a link that asks a component to perform an action) is created. The listener may decide to encode additional query parameters into the link (via `Link.addParameter(String, String)`).
      Specified by:
        `createdComponentEventLink` in interface `LinkCreationListener2`
      Parameters:
        `link` - the newly created link
        `parameters` - information encoded into the link

    - #### createdPageRenderLink

          public void createdPageRenderLink(Link link,
                                            PageRenderRequestParameters parameters)

      Description copied from interface: `LinkCreationListener2`
      Invoked when a page link (a link that renders a page) is created. The listener may decide to encode additional query parameters into the link (via `Link.addParameter(String, String)`).
      Specified by:
        `createdPageRenderLink` in interface `LinkCreationListener2`
      Parameters:
        `link` - the newly created link
        `parameters` - information encoded into the link

5.6.1 - Copyright © 2003-2020 The Apache Software Foundation.