org.baswell.routes
Interface RouteByConvention

All Known Implementing Classes:
RouteByCamelCaseConvention, RouteByHttpMethodNameConvention, RouteByLowercaseConvention

public interface RouteByConvention

Convention for mapping routes where annotations aren't explicitly provided.

See Also:
RoutesConfiguration.routeByConvention

Method Summary
 java.util.List<HttpMethod> respondsToMethods(java.lang.reflect.Method routeMethod)
          The HTTP methods this route method responds to when Route.respondsToMethods() is not specified.
 java.lang.String routePath(java.lang.reflect.Method routeMethod)
          The generated route path from a route method with no Route.value().
 java.lang.String routesPathPrefix(java.lang.Class routesClass)
          The generated root path of a routes class when Routes.value() is not specified.
 

Method Detail

routesPathPrefix

java.lang.String routesPathPrefix(java.lang.Class routesClass)
The generated root path of a routes class when Routes.value() is not specified. This root path will only be prepended to route method paths without Route.value().

Parameters:
routesClass - The routes class.
Returns:
The root route path.

routePath

java.lang.String routePath(java.lang.reflect.Method routeMethod)
The generated route path from a route method with no Route.value(). The path returned here will be appended to routesPathPrefix(Class).

Parameters:
routeMethod -
Returns:
The route path.

respondsToMethods

java.util.List<HttpMethod> respondsToMethods(java.lang.reflect.Method routeMethod)
The HTTP methods this route method responds to when Route.respondsToMethods() is not specified.

Parameters:
routeMethod -
Returns:
The HTTP methods this route method responds to.