/*
 *  Copyright (c) 2017, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
 *
 *  WSO2 Inc. 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 org.wso2.carbon.transport.http.netty.contract.websocket;

import org.wso2.carbon.messaging.exceptions.ClientConnectorException;

import java.util.Map;
import javax.websocket.Session;

/**
 * Client Connector for WebSocket.
 */
public interface WebSocketClientConnector {

    Session connect(WebSocketConnectorListener listener) throws ClientConnectorException;

    Session connect(WebSocketConnectorListener listener, Map<String, String> customHeaders)
            throws ClientConnectorException;

    Session connect(WebSocketConnectorListener listener, WebSocketMessageContext channelContext)
            throws ClientConnectorException;


    Session connect(WebSocketConnectorListener listener, WebSocketMessageContext channelContext,
                    Map<String, String> customHeaders) throws ClientConnectorException;
}

@@ -968,376 +968,1868 @@
     
-Session connect(WebSocketConnectorListener listener) throws ClientConnectorException;%0A%0A    Session connect(WebSocketConnectorListener listener, Map%3CString, String%3E customHeaders)%0A            throws ClientConnectorException;%0A%0A    Session connect(WebSocketConnectorListener listener, WebSocketMessageContext channelContext)%0A            throws ClientConnectorException;%0A%0A
+/**%0A     * Connect to the remote server.%0A     *%0A     * @param listener %7B@link WebSocketConnectorListener%7D to listen incoming messages.%0A     * @return Session for the newly created connection.%0A     * @throws ClientConnectorException if any error occurred during the handshake.%0A     */%0A    Session connect(WebSocketConnectorListener listener) throws ClientConnectorException;%0A%0A    /**%0A     * Connect to the remote server.%0A     *%0A     * @param listener %7B@link WebSocketConnectorListener%7D to listen incoming messages.%0A     * @param customHeaders Custom headers for WebSocket.%0A     * @return Session for the newly created connection.%0A     * @throws ClientConnectorException if any error occurred during the handshake.%0A     */%0A    Session connect(WebSocketConnectorListener listener, Map%3CString, String%3E customHeaders)%0A            throws ClientConnectorException;%0A%0A    /**%0A     * Connect to the remote server.%0A     *%0A     * @param listener %7B@link WebSocketConnectorListener%7D to listen incoming messages.%0A     * @param channelContext %7B@link WebSocketMessageContext%7D basically WebSocket message can be passed to this.%0A     * @return Session for the newly created connection.%0A     * @throws ClientConnectorException if any error occurred during the handshake.%0A     */%0A    Session connect(WebSocketConnectorListener listener, WebSocketMessageContext channelContext)%0A            throws ClientConnectorException;%0A%0A%0A    /**%0A     * Connect to the remote server.%0A     *%0A     * @param listener %7B@link WebSocketConnectorListener%7D to listen incoming messages.%0A     * @param channelContext %7B@link WebSocketMessageContext%7D basically WebSocket message can be passed to this.%0A     * @param customHeaders Custom headers for WebSocket.%0A     * @return Session for the newly created connection.%0A     * @throws ClientConnectorException if any error occurred during the handshake.%0A     */
 %0A   

Add doc comments to WebSocketClientConnector