Class Redirection
java.lang.Object
cool.scx.web.vo.Redirection
- All Implemented Interfaces:
cool.scx.function.Function1Void<cool.scx.http.routing.RoutingContext, Exception>, BaseVo
-
Method Summary
Modifier and TypeMethodDescriptionvoidapply(cool.scx.http.routing.RoutingContext routingContext) voidhandle(cool.scx.http.ScxHttpServerResponse response) static RedirectionofPermanent(String location) 永久重定向static RedirectionofTemporary(String location) 临时重定向
-
Method Details
-
ofPermanent
永久重定向- Parameters:
location- 重定向地址- Returns:
- r
-
ofTemporary
临时重定向- Parameters:
location- 重定向地址- Returns:
- r
-
handle
public void handle(cool.scx.http.ScxHttpServerResponse response) -
apply
public void apply(cool.scx.http.routing.RoutingContext routingContext) - Specified by:
applyin interfacecool.scx.function.Function1Void<cool.scx.http.routing.RoutingContext, Exception>
-