Class Route


  • final class Route
    extends java.lang.Object
    Request routing information. Contains a routing pattern and a list of next-level stages to be processed in case the routing pattern successfully matches the un-matched right-hand part of the request.
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private Route​(PathPattern routingPattern, java.util.List<Router> routers)  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.List<Router> next()
      Get next-level routers to be processed in case the routing pattern matches the unmatched right-hand part of the request path.
      (package private) static Route of​(PathPattern routingPattern, java.util.List<Router> routers)
      Create a new request route.
      PathPattern routingPattern()
      Get the request path routing pattern.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • routingPattern

        private final PathPattern routingPattern
      • routers

        private final java.util.List<Router> routers
    • Constructor Detail

      • Route

        private Route​(PathPattern routingPattern,
                      java.util.List<Router> routers)
    • Method Detail

      • of

        static Route of​(PathPattern routingPattern,
                        java.util.List<Router> routers)
        Create a new request route.
        Parameters:
        routingPattern - request path routing pattern.
        routers - next-level routers to be processed in case the routing pattern matches the unmatched right-hand part of the request path.
        Returns:
        new request route.
      • routingPattern

        public PathPattern routingPattern()
        Get the request path routing pattern.
        Returns:
        request path routing pattern.
      • next

        public java.util.List<Router> next()
        Get next-level routers to be processed in case the routing pattern matches the unmatched right-hand part of the request path.
        Returns:
        routed next-level next.