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

com.alibaba.jvm.sandbox.api.http.websocket.WebSocketAcceptor Maven / Gradle / Ivy

There is a newer version: 1.4.0
Show newest version
package com.alibaba.jvm.sandbox.api.http.websocket;

import javax.servlet.http.HttpServletRequest;

/**
 * WebSocketConnection监听器的构造工厂
 *
 * @author [email protected]
 */
public interface WebSocketAcceptor {

    /**
     * 接受WebSocket创建连接请求
     * 当从客户端发起一个WebSocket连接请求的时候会调用这个方法,从这个方法中返回一个连接处理的监听器来完成本次WebSocket请求
     *
     * @param req      http req
     * @param protocol websocket's protocol
     * @return WebSocketConnectionListener
     */
    WebSocketConnectionListener onAccept(HttpServletRequest req, String protocol);

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy