构造器和说明 |
---|
Route() |
Route(HttpMethod httpMethod,
String path,
Class<?> targetType,
Method action) |
Route(HttpMethod httpMethod,
String path,
Object target,
Class<?> targetType,
Method action) |
限定符和类型 | 方法和说明 |
---|---|
Method |
getAction()
Return route method
|
String |
getAllPath() |
HttpMethod |
getHttpMethod()
Return http method
|
String |
getPath()
Return route path
|
Map<String,String> |
getPathParams()
Get route path parameters
|
int |
getSort()
Get route execution sort, default is Integer.MAX_VALUE
|
Object |
getTarget()
Return route controller instance
|
Class<?> |
getTargetType()
Get route handler type
|
void |
setPath(String path)
Set route path
|
void |
setPathParams(Map<String,String> pathParams)
Set path params
|
void |
setSort(int sort)
Set route execution sort
|
void |
setTarget(Object target)
Set route handler instance
|
String |
toString()
Route to string
|
public Route()
public Route(HttpMethod httpMethod, String path, Class<?> targetType, Method action)
public Route(HttpMethod httpMethod, String path, Object target, Class<?> targetType, Method action)
public HttpMethod getHttpMethod()
public String getPath()
public void setPath(String path)
path
- string pathpublic Object getTarget()
public void setTarget(Object target)
target
- target beanpublic Method getAction()
public Class<?> getTargetType()
public Map<String,String> getPathParams()
public void setPathParams(Map<String,String> pathParams)
pathParams
- path params mappublic int getSort()
public void setSort(int sort)
sort
- sort numberpublic String getAllPath()
Copyright © 2018. All rights reserved.