org.apache.wicket.request.target.component
Class BookmarkableListenerInterfaceRequestTarget

java.lang.Object
  extended by org.apache.wicket.request.target.component.BookmarkablePageRequestTarget
      extended by org.apache.wicket.request.target.component.BookmarkableListenerInterfaceRequestTarget
All Implemented Interfaces:
IRequestTarget, IBookmarkablePageRequestTarget, IEventProcessor

public class BookmarkableListenerInterfaceRequestTarget
extends BookmarkablePageRequestTarget

Request target for bookmarkable page links that also contain component path and interface name. This is used for stateless forms and stateless links.

Author:
Matej Knopp

Constructor Summary
BookmarkableListenerInterfaceRequestTarget(String pageMapName, Class<? extends Page> pageClass, PageParameters pageParameters, Component component, RequestListenerInterface listenerInterface)
          This constructor is called for generating the urls (RequestCycle.urlFor()) So it will alter the PageParameters to include the 2 org.apache.wicket params WebRequestCodingStrategy.BOOKMARKABLE_PAGE_PARAMETER_NAME and WebRequestCodingStrategy.INTERFACE_PARAMETER_NAME
BookmarkableListenerInterfaceRequestTarget(String pageMapName, Class<? extends Page> pageClass, PageParameters pageParameters, String componentPath, String interfaceName, int versionNumber)
          This constructor is called when a stateless link is clicked on but the page wasn't found in the session.
 
Method Summary
 String getComponentPath()
           
 String getInterfaceName()
           
 void processEvents(RequestCycle requestCycle)
          After a page is restored, this method is responsible for calling any event handling code based on the request.
 void respond(RequestCycle requestCycle)
          Generates a response.
 
Methods inherited from class org.apache.wicket.request.target.component.BookmarkablePageRequestTarget
detach, equals, getPage, getPage, getPageClass, getPageMapName, getPageParameters, hashCode, newPage, setPage, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BookmarkableListenerInterfaceRequestTarget

public BookmarkableListenerInterfaceRequestTarget(String pageMapName,
                                                  Class<? extends Page> pageClass,
                                                  PageParameters pageParameters,
                                                  String componentPath,
                                                  String interfaceName,
                                                  int versionNumber)
This constructor is called when a stateless link is clicked on but the page wasn't found in the session. Then this class will recreate the page and call the interface method on the component that is targeted with the component path.

Parameters:
pageMapName -
pageClass -
pageParameters -
componentPath -
interfaceName -
versionNumber -

BookmarkableListenerInterfaceRequestTarget

public BookmarkableListenerInterfaceRequestTarget(String pageMapName,
                                                  Class<? extends Page> pageClass,
                                                  PageParameters pageParameters,
                                                  Component component,
                                                  RequestListenerInterface listenerInterface)
This constructor is called for generating the urls (RequestCycle.urlFor()) So it will alter the PageParameters to include the 2 org.apache.wicket params WebRequestCodingStrategy.BOOKMARKABLE_PAGE_PARAMETER_NAME and WebRequestCodingStrategy.INTERFACE_PARAMETER_NAME

Parameters:
pageMapName -
pageClass -
pageParameters -
component -
listenerInterface -
Method Detail

processEvents

public void processEvents(RequestCycle requestCycle)
Description copied from interface: IEventProcessor
After a page is restored, this method is responsible for calling any event handling code based on the request.

Specified by:
processEvents in interface IEventProcessor
Overrides:
processEvents in class BookmarkablePageRequestTarget
Parameters:
requestCycle - the current request cycle

respond

public void respond(RequestCycle requestCycle)
Description copied from interface: IRequestTarget
Generates a response.

Specified by:
respond in interface IRequestTarget
Overrides:
respond in class BookmarkablePageRequestTarget
Parameters:
requestCycle - the current request cycle

getComponentPath

public String getComponentPath()
Returns:
The component path.

getInterfaceName

public String getInterfaceName()
Returns:
The interface name


Copyright © 2004-2011 Apache Software Foundation. All Rights Reserved.