JettyServer.java 文件源码

java
阅读 30 收藏 0 点赞 0 评论 0

项目:guice-websocket 作者:
private ServerEndpointConfig createEndpointConfig(Class<?> endpointClass) throws DeploymentException {
    ServerEndpoint annotation = endpointClass.getAnnotation(ServerEndpoint.class);
    if (annotation == null) {
        throw new InvalidWebSocketException("Unsupported WebSocket object, missing @" + ServerEndpoint.class + " annotation");
    }

    return ServerEndpointConfig.Builder.create(endpointClass, annotation.value())
            .subprotocols(Arrays.asList(annotation.subprotocols()))
            .decoders(Arrays.asList(annotation.decoders()))
            .encoders(Arrays.asList(annotation.encoders()))
            .configurator(configurator)
            .build();
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号