Liferay 6.1.2-ce-ga3

com.liferay.portlet
Class RouterImpl

java.lang.Object
  extended by com.liferay.portlet.RouterImpl
All Implemented Interfaces:
Router

public class RouterImpl
extends Object
implements Router


Constructor Summary
RouterImpl()
           
 
Method Summary
 Route addRoute(String pattern)
          Generates a new route from its pattern string.
 String parametersToUrl(Map<String,String> parameters)
          Generates a URL from the parameter map using the available routes.
 boolean urlToParameters(String url, Map<String,String> parameters)
          Parses a URL into a parameter map using the available routes.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RouterImpl

public RouterImpl()
Method Detail

addRoute

public Route addRoute(String pattern)
Description copied from interface: Router
Generates a new route from its pattern string.

Specified by:
addRoute in interface Router
Parameters:
pattern - the route pattern string
Returns:
the generated route

parametersToUrl

public String parametersToUrl(Map<String,String> parameters)
Description copied from interface: Router
Generates a URL from the parameter map using the available routes.

Specified by:
parametersToUrl in interface Router
Parameters:
parameters - the parameter map
Returns:
the URL path, or null if an applicable route was not found

urlToParameters

public boolean urlToParameters(String url,
                               Map<String,String> parameters)
Description copied from interface: Router
Parses a URL into a parameter map using the available routes.

Specified by:
urlToParameters in interface Router
Parameters:
url - the URL to be parsed
parameters - the parameter map to be populated
Returns:
true if a match was found and parameters was populated; false otherwise

Liferay 6.1.2-ce-ga3