code: public static String getUrlAsString(final Class<? extends Page> pageClass)
  	{
  		final Url pageUrl = getPageUrl(pageClass);
  		final Url url = getBaseUrl(pageClass);
  		url.resolveRelative(pageUrl);
  		final String contextPath = getContextPath();
  		return String.format("%s/%s", contextPath, url);
  	}
docs: Gets the url as string from the given WebPage class object.
  
  @param pageClass
  the page class
  @return the url as string