Package io.vertx.mutiny.ext.web.handler
Class TimeoutHandler
java.lang.Object
io.vertx.mutiny.ext.web.handler.TimeoutHandler
- All Implemented Interfaces:
MutinyDelegate,io.vertx.core.Handler<RoutingContext>,PlatformHandler,Consumer<RoutingContext>
public class TimeoutHandler
extends Object
implements io.vertx.core.Handler<RoutingContext>, PlatformHandler, Consumer<RoutingContext>, MutinyDelegate
Handler that will timeout requests if the response has not been written after a certain time.
Timeout requests will be ended with an HTTP status code `503`.
NOTE: This class has been automatically generated from the original non Mutiny-ified interface.
- Author:
- Tim Fox
- See Also:
-
TimeoutHandler
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.vertx.mutiny.ext.web.handler.PlatformHandler
PlatformHandler.PlatformHandlerImpl -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final TypeArg<TimeoutHandler>static final intThe default error codestatic final longThe default timeout, in ms -
Constructor Summary
ConstructorsConstructorDescriptionTimeoutHandler(io.vertx.ext.web.handler.TimeoutHandler delegate) Create a new instance ofTimeoutHandlerdelegating to the given (non-null) instance ofTimeoutHandler.TimeoutHandler(Object delegate) -
Method Summary
Modifier and TypeMethodDescriptionvoidaccept(RoutingContext item) Handle an item.static TimeoutHandlercreate()Create a handlerstatic TimeoutHandlercreate(long timeout) Create a handlerstatic TimeoutHandlercreate(long timeout, int errorCode) Create a handlerbooleanio.vertx.ext.web.handler.TimeoutHandlerGet the delegate instance.voidhandle(RoutingContext item) Handle an item.inthashCode()static TimeoutHandlernewInstance(io.vertx.ext.web.handler.TimeoutHandler delegate) Creates a new instance of theTimeoutHandler.toString()
-
Field Details
-
DEFAULT_TIMEOUT
public static final long DEFAULT_TIMEOUTThe default timeout, in ms- See Also:
-
DEFAULT_ERRORCODE
public static final int DEFAULT_ERRORCODEThe default error code- See Also:
-
__TYPE_ARG
-
-
Constructor Details
-
TimeoutHandler
public TimeoutHandler(io.vertx.ext.web.handler.TimeoutHandler delegate) Create a new instance ofTimeoutHandlerdelegating to the given (non-null) instance ofTimeoutHandler. -
TimeoutHandler
-
-
Method Details
-
accept
Handle an item. This method is generated from theoriginalmethod."- Specified by:
acceptin interfaceConsumer<RoutingContext>- Specified by:
acceptin interfacePlatformHandler
-
handle
Handle an item. This method is generated from theoriginalmethod."- Specified by:
handlein interfaceio.vertx.core.Handler<RoutingContext>- Specified by:
handlein interfacePlatformHandler
-
getDelegate
public io.vertx.ext.web.handler.TimeoutHandler getDelegate()Get the delegate instance.This method returns the instance on which this shim is delegating the calls. And so, give you access to the bare API.
- Specified by:
getDelegatein interfaceMutinyDelegate- Specified by:
getDelegatein interfacePlatformHandler- Returns:
- the delegate instance
-
create
Create a handler- Returns:
- the handler
-
create
Create a handler- Parameters:
timeout- the timeout, in ms- Returns:
- the handler
-
create
Create a handler- Parameters:
timeout- the timeout, in ms- Returns:
- the handler
-
newInstance
Creates a new instance of theTimeoutHandler. -
hashCode
public int hashCode() -
equals
-
toString
-