You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by iv...@apache.org on 2007/05/02 04:38:05 UTC

svn commit: r534295 - /incubator/wicket/trunk/jdk-1.4/wicket/src/main/java/org/apache/wicket/RequestCycle.java

Author: ivaynberg
Date: Tue May  1 19:38:04 2007
New Revision: 534295

URL: http://svn.apache.org/viewvc?view=rev&rev=534295
Log:
added urlfor variant for bookmarkable pages that does not require a pagemap. it is unclear that you can pass null into urlfor(pagemap,class,params), and even it it was i still dot like it. it is much cleaner to have a variant that doesnt require the pagemap param.

Modified:
    incubator/wicket/trunk/jdk-1.4/wicket/src/main/java/org/apache/wicket/RequestCycle.java

Modified: incubator/wicket/trunk/jdk-1.4/wicket/src/main/java/org/apache/wicket/RequestCycle.java
URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.4/wicket/src/main/java/org/apache/wicket/RequestCycle.java?view=diff&rev=534295&r1=534294&r2=534295
==============================================================================
--- incubator/wicket/trunk/jdk-1.4/wicket/src/main/java/org/apache/wicket/RequestCycle.java (original)
+++ incubator/wicket/trunk/jdk-1.4/wicket/src/main/java/org/apache/wicket/RequestCycle.java Tue May  1 19:38:04 2007
@@ -758,8 +758,26 @@
 	 * all information necessary to instantiate and render the page, it can be
 	 * stored in a user's browser as a stable bookmark.
 	 * 
+	 * @param pageClass
+	 *            Class of page
+	 * @param parameters
+	 *            Parameters to page
+	 * @return Bookmarkable URL to page
+	 */
+	public final CharSequence urlFor(final Class pageClass, final PageParameters parameters)
+	{
+		return urlFor(null, pageClass, parameters);
+	}
+
+	/**
+	 * Returns a bookmarkable URL that references a given page class using a
+	 * given set of page parameters. Since the URL which is returned contains
+	 * all information necessary to instantiate and render the page, it can be
+	 * stored in a user's browser as a stable bookmark.
+	 * 
 	 * @param pageMap
-	 *            Pagemap to use
+	 *            Pagemap to use. If null is passed the default page map will be
+	 *            used
 	 * @param pageClass
 	 *            Class of page
 	 * @param parameters