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

java.lang.Object
  extended by org.apache.wicket.request.target.component.PageIdRequestTarget
All Implemented Interfaces:
IRequestTarget

public class PageIdRequestTarget
extends java.lang.Object
implements IRequestTarget

Target that navigates to a page pointed to by its id. The great benefit of this target over the PageRequestTarget is that no reference to the actual page is needed, which greatly facilitates navigational usecases where a list or a stack of page references is needed (ie breadcrumbs).

Author:
igor.vaynberg
See Also:
PageId

Constructor Summary
PageIdRequestTarget(Page page)
          Constructor Even though a page is passed in, only a reference to its PageId is kept
PageIdRequestTarget(PageId pageId)
          Constructor
 
Method Summary
 void detach(RequestCycle requestCycle)
          This method is called at the end of a request cycle to indicate that processing is done and that cleaning up of the subject(s) of this target may be done.
 PageId getPageId()
           
 void respond(RequestCycle requestCycle)
          Generates a response.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PageIdRequestTarget

public PageIdRequestTarget(Page page)
Constructor Even though a page is passed in, only a reference to its PageId is kept

Parameters:
page -

PageIdRequestTarget

public PageIdRequestTarget(PageId pageId)
Constructor

Parameters:
pageId -
Method Detail

getPageId

public final PageId getPageId()
Returns:
id page id

respond

public void respond(RequestCycle requestCycle)
Generates a response.

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

detach

public void detach(RequestCycle requestCycle)
This method is called at the end of a request cycle to indicate that processing is done and that cleaning up of the subject(s) of this target may be done.

Specified by:
detach in interface IRequestTarget
Parameters:
requestCycle - the current request cycle


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