ttomcat-1778514358873.zip-extract/apache-tomcat-11.0.18-src/java/jakarta/websocket/server/ServerContainer.java

Path
ttomcat-1778514358873.zip-extract/apache-tomcat-11.0.18-src/java/jakarta/websocket/server/ServerContainer.java
Status
scanned
Type
file
Name
ServerContainer.java
Extension
.java
Programming language
Java
Mime type
text/plain
File type
ASCII text, with CRLF line terminators
Tag

      
    
Rootfs path

      
    
Size
3674 (3.6 KB)
MD5
5e4361c291405be3caf3a33ff60ba866
SHA1
8f9576d77b3569802d736b348fd156ac456b3d98
SHA256
b49474d25da1b434d389816fe9883d621bb8c3ae1ee55228e490c63981cd63fb
SHA512

      
    
SHA1_git
9f22ac1ca3e3a7b27329e84561e8dd9f806ec0b8
Is binary

      
    
Is text
True
Is archive

      
    
Is media

      
    
Is legal

      
    
Is manifest

      
    
Is readme

      
    
Is top level

      
    
Is key file

      
    
ServerContainer.java | 3.6 KB |

/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package jakarta.websocket.server; import java.io.IOException; import java.util.Map; import jakarta.websocket.DeploymentException; import jakarta.websocket.WebSocketContainer; /** * Provides the ability to deploy endpoints programmatically. */ public interface ServerContainer extends WebSocketContainer { void addEndpoint(Class<?> clazz) throws DeploymentException; void addEndpoint(ServerEndpointConfig sec) throws DeploymentException; /** * Upgrade the HTTP connection represented by the {@code HttpServletRequest} and {@code HttpServletResponse} to the * WebSocket protocol and establish a WebSocket connection as per the provided {@link ServerEndpointConfig}. * <p> * This method is primarily intended to be used by frameworks that implement the front-controller pattern. It does * not deploy the provided endpoint. * <p> * If the WebSocket implementation is not deployed as part of a Jakarta Servlet container, this method will throw an * {@link UnsupportedOperationException}. * * @param httpServletRequest The {@code HttpServletRequest} to be processed as a WebSocket handshake as per section * 4.0 of RFC 6455. * @param httpServletResponse The {@code HttpServletResponse} to be used when processing the * {@code httpServletRequest} as a WebSocket handshake as per section 4.0 of RFC * 6455. * @param sec The server endpoint configuration to use to configure the WebSocket endpoint * @param pathParameters Provides a mapping of path parameter names and values, if any, to be used for the * WebSocket connection established by the call to this method. If no such mapping is * defined, an empty Map must be passed. * * @throws IllegalStateException if the provided request does not meet the requirements of the WebSocket * handshake * @throws UnsupportedOperationException if the WebSocket implementation is not deployed as part of a Jakarta * Servlet container * @throws IOException if an I/O error occurs during the establishment of a WebSocket connection * @throws DeploymentException if a configuration error prevents the establishment of a WebSocket * connection * * @since WebSocket 2.0 */ void upgradeHttpToWebSocket(Object httpServletRequest, Object httpServletResponse, ServerEndpointConfig sec, Map<String,String> pathParameters) throws IOException, DeploymentException; }
Detected license expression
apache-2.0
Detected license expression (SPDX)
Apache-2.0
Percentage of license text
29.82
Copyrights

      
    
Holders

      
    
Authors

      
    
License detections License expression License expression SPDX
apache_2_0-4bde3f57-78aa-4201-96bf-531cba09e7de apache-2.0 Apache-2.0
URL Start line End line
http://www.apache.org/licenses/LICENSE-2.0 9 9