Package play.routing

Class JavaScriptReverseRouter


  • public class JavaScriptReverseRouter
    extends Object
    Helpers for creating JavaScript reverse routers
    • Constructor Detail

      • JavaScriptReverseRouter

        public JavaScriptReverseRouter()
    • Method Detail

      • create

        public static play.twirl.api.JavaScript create​(String name,
                                                       String ajaxMethod,
                                                       String host,
                                                       play.api.routing.JavaScriptReverseRoute... routes)
        Generates a JavaScript reverse router.
        Parameters:
        name - the router's name
        ajaxMethod - which asynchronous call method the user's browser will use (e.g. "jQuery.ajax")
        host - the host to use for the reverse route
        routes - the reverse routes for this router
        Returns:
        the router