Package com.linecorp.armeria.server
Interface Router<V>
-
public interface Router<V>
Finds a mapping that matches a givenRoutingContext
.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description void
dump(OutputStream output)
Dumps the content of thisRouter
.Routed<V>
find(RoutingContext routingCtx)
Finds the value of mapping that matches the specifiedRoutingContext
.default boolean
registerMetrics(MeterRegistry registry, MeterIdPrefix idPrefix)
Registers the stats of thisRouter
to the specifiedMeterRegistry
.
-
-
-
Method Detail
-
find
Routed<V> find(RoutingContext routingCtx)
Finds the value of mapping that matches the specifiedRoutingContext
.- Returns:
- a
Routed
that wraps the matching value if there's a match.Routed.empty()
if there's no match.
-
registerMetrics
default boolean registerMetrics(MeterRegistry registry, MeterIdPrefix idPrefix)
Registers the stats of thisRouter
to the specifiedMeterRegistry
.- Returns:
- whether the stats of this
Router
has been registered
-
dump
void dump(OutputStream output)
Dumps the content of thisRouter
.
-
-