All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.litongjava.tio.http.server.router.HttpRequestFunctionRouter Maven / Gradle / Ivy

There is a newer version: 3.7.3.v20241201-RELEASE
Show newest version

package com.litongjava.tio.http.server.router;

import com.litongjava.model.type.TioTypeReference;
import com.litongjava.tio.http.server.handler.IHttpRequestFunction;
import com.litongjava.tio.http.server.handler.RouteEntry;

public interface HttpRequestFunctionRouter {

  /**
   * 添加路由函数
   *
   * @param path          路由路径
   * @param function      IHttpRequestFunction 接口实现
   * @param typeReference 用于捕获函数的泛型类型
   */
  public  void add(String path, IHttpRequestFunction function, TioTypeReference typeReference);

  /**
   * 查找路由函数
   *
   * @param path 路径
   * @return RouteEntry 包含了 IHttpRequestFunction 和 TioTypeReference
   */
  public  RouteEntry find(String path);
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy