Author: fmoga
Date: Sun Nov  7 11:00:41 2010
New Revision: 1032255

URL: http://svn.apache.org/viewvc?rev=1032255&view=rev
Log:
Added stubs for client components.

Added:
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketState.java
   (with props)
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/CloseCallback.java
   (with props)
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/MessageCallback.java
   (with props)
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/OpenCallback.java
   (with props)
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/WebSocketListener.java
   (with props)
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WebSocketConnection.java
   (with props)
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WebSocketConnectionFactory.java
   (with props)
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WsConnection.java
   (with props)
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WssConnection.java
   (with props)
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/CloseStrategy.java
   (with props)
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/FramingStrategy.java
   (with props)
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/HandshakeStrategy.java
   (with props)
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/WebSocketStreamHandler.java
   (with props)
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/CloseStrategyDraft03.java
   (with props)
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/FramingStrategyDraft03.java
   (with props)
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/HandshakeStrategyDraft03.java
   (with props)
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/url/
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/url/WebSocketURL.java
      - copied, changed from r1030739, 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/URLParser.java
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/url/WebSocketURLException.java
      - copied, changed from r1029793, 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketURLException.java
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/util/
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/util/WebSocketConstants.java
      - copied, changed from r1029793, 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketConstants.java
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/util/WebSocketUtils.java
      - copied, changed from r1030739, 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketUtils.java
    
labs/monsoon/trunk/modules/monsoon-client/src/test/java/org/apache/monsoon/client/WebSocketURLTest.java
      - copied, changed from r1030739, 
labs/monsoon/trunk/modules/monsoon-client/src/test/java/org/apache/monsoon/client/WebSocketTest.java
Removed:
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/URLParser.java
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketConstants.java
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketURLException.java
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketUtils.java
    
labs/monsoon/trunk/modules/monsoon-client/src/test/java/org/apache/monsoon/client/WebSocketTest.java
Modified:
    
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocket.java

Modified: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocket.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocket.java?rev=1032255&r1=1032254&r2=1032255&view=diff
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocket.java
 (original)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocket.java
 Sun Nov  7 11:00:41 2010
@@ -18,23 +18,13 @@
  */
 package org.apache.monsoon.client;
 
+import org.apache.monsoon.client.url.WebSocketURL;
+import org.apache.monsoon.client.url.WebSocketURLException;
+
 public class WebSocket {
 
-    private static final short CONNECTING = 0;
-    private static final short OPEN = 1;
-    private static final short CLOSING = 2;
-    private static final short CLOSED = 3;
-
-    // W3C spec
-    private String url;
-    private String protocol;
-    private short readyState;
-    private long bufferedAmount;
-
-    private boolean secure;
-    private String host;
-    private int port;
-    private String resourceName;
+    private WebSocketState state;
+    private WebSocketURL url;
 
     public WebSocket(String url) throws WebSocketURLException {
         this(url, new String[] {});
@@ -46,11 +36,7 @@ public class WebSocket {
 
     public WebSocket(String url, String[] protocols)
             throws WebSocketURLException {
-        URLParser urlParser = new URLParser(url);
-        this.secure = urlParser.isSecure();
-        this.host = urlParser.getHost();
-        this.port = urlParser.getPort();
-        this.resourceName = urlParser.getResourceName();
+        this.url = new WebSocketURL(url);
     }
 
     public void send(String data) {
@@ -61,35 +47,4 @@ public class WebSocket {
         // TODO
     }
 
-    public void onOpen() {
-        // TODO
-    }
-
-    public void onMessage(String message) {
-        // TODO
-    }
-
-    public void onError() {
-        // TODO
-    }
-
-    public void onClose() {
-        // TODO
-    }
-
-    public boolean isSecure() {
-        return secure;
-    }
-
-    public String getHost() {
-        return host;
-    }
-
-    public int getPort() {
-        return port;
-    }
-
-    public String getResourceName() {
-        return resourceName;
-    }
 }

Added: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketState.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketState.java?rev=1032255&view=auto
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketState.java
 (added)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketState.java
 Sun Nov  7 11:00:41 2010
@@ -0,0 +1,25 @@
+/*
+ * 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 org.apache.monsoon.client;
+
+public enum WebSocketState {
+
+    CONNECTING, OPEN, CLOSING, CLOSED
+
+}

Propchange: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketState.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/CloseCallback.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/CloseCallback.java?rev=1032255&view=auto
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/CloseCallback.java
 (added)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/CloseCallback.java
 Sun Nov  7 11:00:41 2010
@@ -0,0 +1,28 @@
+/*
+ * 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 org.apache.monsoon.client.callback;
+
+/**
+ * 
+ */
+public interface CloseCallback {
+
+    void onClose();
+
+}

Propchange: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/CloseCallback.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/MessageCallback.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/MessageCallback.java?rev=1032255&view=auto
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/MessageCallback.java
 (added)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/MessageCallback.java
 Sun Nov  7 11:00:41 2010
@@ -0,0 +1,28 @@
+/*
+ * 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 org.apache.monsoon.client.callback;
+
+/**
+ * 
+ */
+public interface MessageCallback {
+
+    void onMessage(String message);
+
+}

Propchange: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/MessageCallback.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/OpenCallback.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/OpenCallback.java?rev=1032255&view=auto
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/OpenCallback.java
 (added)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/OpenCallback.java
 Sun Nov  7 11:00:41 2010
@@ -0,0 +1,28 @@
+/*
+ * 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 org.apache.monsoon.client.callback;
+
+/**
+ * 
+ */
+public interface OpenCallback {
+
+    void onOpen();
+
+}

Propchange: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/OpenCallback.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/WebSocketListener.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/WebSocketListener.java?rev=1032255&view=auto
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/WebSocketListener.java
 (added)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/WebSocketListener.java
 Sun Nov  7 11:00:41 2010
@@ -0,0 +1,24 @@
+/*
+ * 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 org.apache.monsoon.client.callback;
+
+public interface WebSocketListener extends OpenCallback, MessageCallback,
+        CloseCallback {
+
+}

Propchange: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/callback/WebSocketListener.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WebSocketConnection.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WebSocketConnection.java?rev=1032255&view=auto
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WebSocketConnection.java
 (added)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WebSocketConnection.java
 Sun Nov  7 11:00:41 2010
@@ -0,0 +1,47 @@
+/*
+ * 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 org.apache.monsoon.client.connection;
+
+import java.io.IOException;
+import java.net.URL;
+import java.net.URLConnection;
+
+/**
+ * 
+ */
+public class WebSocketConnection extends URLConnection {
+
+    /**
+     * @param url
+     */
+    protected WebSocketConnection(URL url) {
+        super(url);
+        // TODO Auto-generated constructor stub
+    }
+
+    /**
+     * {...@inheritdoc}
+     */
+    @Override
+    public void connect() throws IOException {
+        // TODO Auto-generated method stub
+
+    }
+
+}

Propchange: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WebSocketConnection.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WebSocketConnectionFactory.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WebSocketConnectionFactory.java?rev=1032255&view=auto
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WebSocketConnectionFactory.java
 (added)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WebSocketConnectionFactory.java
 Sun Nov  7 11:00:41 2010
@@ -0,0 +1,26 @@
+/*
+ * 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 org.apache.monsoon.client.connection;
+
+/**
+ * 
+ */
+public class WebSocketConnectionFactory {
+
+}

Propchange: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WebSocketConnectionFactory.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WsConnection.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WsConnection.java?rev=1032255&view=auto
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WsConnection.java
 (added)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WsConnection.java
 Sun Nov  7 11:00:41 2010
@@ -0,0 +1,36 @@
+/*
+ * 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 org.apache.monsoon.client.connection;
+
+import java.net.URL;
+
+/**
+ * 
+ */
+public class WsConnection extends WebSocketConnection {
+
+    /**
+     * @param url
+     */
+    protected WsConnection(URL url) {
+        super(url);
+        // TODO Auto-generated constructor stub
+    }
+
+}

Propchange: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WsConnection.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WssConnection.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WssConnection.java?rev=1032255&view=auto
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WssConnection.java
 (added)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WssConnection.java
 Sun Nov  7 11:00:41 2010
@@ -0,0 +1,36 @@
+/*
+ * 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 org.apache.monsoon.client.connection;
+
+import java.net.URL;
+
+/**
+ * 
+ */
+public class WssConnection extends WebSocketConnection {
+
+    /**
+     * @param url
+     */
+    protected WssConnection(URL url) {
+        super(url);
+        // TODO Auto-generated constructor stub
+    }
+
+}

Propchange: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/connection/WssConnection.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/CloseStrategy.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/CloseStrategy.java?rev=1032255&view=auto
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/CloseStrategy.java
 (added)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/CloseStrategy.java
 Sun Nov  7 11:00:41 2010
@@ -0,0 +1,28 @@
+/*
+ * 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 org.apache.monsoon.client.stream;
+
+/**
+ * 
+ */
+public interface CloseStrategy {
+
+    void close();
+    
+}

Propchange: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/CloseStrategy.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/FramingStrategy.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/FramingStrategy.java?rev=1032255&view=auto
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/FramingStrategy.java
 (added)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/FramingStrategy.java
 Sun Nov  7 11:00:41 2010
@@ -0,0 +1,28 @@
+/*
+ * 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 org.apache.monsoon.client.stream;
+
+/**
+ * 
+ */
+public interface FramingStrategy {
+
+    void onFrame();
+
+}

Propchange: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/FramingStrategy.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/HandshakeStrategy.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/HandshakeStrategy.java?rev=1032255&view=auto
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/HandshakeStrategy.java
 (added)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/HandshakeStrategy.java
 Sun Nov  7 11:00:41 2010
@@ -0,0 +1,30 @@
+/*
+ * 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 org.apache.monsoon.client.stream;
+
+/**
+ * 
+ */
+public interface HandshakeStrategy {
+
+    void initiateHandshake();
+
+    void checkHandshakeResponse();
+
+}

Propchange: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/HandshakeStrategy.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/WebSocketStreamHandler.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/WebSocketStreamHandler.java?rev=1032255&view=auto
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/WebSocketStreamHandler.java
 (added)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/WebSocketStreamHandler.java
 Sun Nov  7 11:00:41 2010
@@ -0,0 +1,26 @@
+/*
+ * 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 org.apache.monsoon.client.stream;
+
+/**
+ * 
+ */
+public class WebSocketStreamHandler {
+
+}

Propchange: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/WebSocketStreamHandler.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/CloseStrategyDraft03.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/CloseStrategyDraft03.java?rev=1032255&view=auto
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/CloseStrategyDraft03.java
 (added)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/CloseStrategyDraft03.java
 Sun Nov  7 11:00:41 2010
@@ -0,0 +1,36 @@
+/*
+ * 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 org.apache.monsoon.client.stream.impl;
+
+import org.apache.monsoon.client.stream.CloseStrategy;
+
+/**
+ * 
+ */
+public class CloseStrategyDraft03 implements CloseStrategy {
+
+    /**
+     * {...@inheritdoc}
+     */
+    public void close() {
+        // TODO Auto-generated method stub
+
+    }
+
+}

Propchange: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/CloseStrategyDraft03.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/FramingStrategyDraft03.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/FramingStrategyDraft03.java?rev=1032255&view=auto
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/FramingStrategyDraft03.java
 (added)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/FramingStrategyDraft03.java
 Sun Nov  7 11:00:41 2010
@@ -0,0 +1,35 @@
+/*
+ * 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 org.apache.monsoon.client.stream.impl;
+
+/**
+ * 
+ */
+public class FramingStrategyDraft03 implements
+        org.apache.monsoon.client.stream.FramingStrategy {
+
+    /**
+     * {...@inheritdoc}
+     */
+    public void onFrame() {
+        // TODO Auto-generated method stub
+
+    }
+
+}

Propchange: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/FramingStrategyDraft03.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/HandshakeStrategyDraft03.java
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/HandshakeStrategyDraft03.java?rev=1032255&view=auto
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/HandshakeStrategyDraft03.java
 (added)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/HandshakeStrategyDraft03.java
 Sun Nov  7 11:00:41 2010
@@ -0,0 +1,44 @@
+/*
+ * 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 org.apache.monsoon.client.stream.impl;
+
+import org.apache.monsoon.client.stream.HandshakeStrategy;
+
+/**
+ * 
+ */
+public class HandshakeStrategyDraft03 implements HandshakeStrategy {
+
+    /**
+     * {...@inheritdoc}
+     */
+    public void initiateHandshake() {
+        // TODO Auto-generated method stub
+
+    }
+
+    /**
+     * {...@inheritdoc}
+     */
+    public void checkHandshakeResponse() {
+        // TODO Auto-generated method stub
+
+    }
+
+}

Propchange: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/stream/impl/HandshakeStrategyDraft03.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Copied: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/url/WebSocketURL.java
 (from r1030739, 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/URLParser.java)
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/url/WebSocketURL.java?p2=labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/url/WebSocketURL.java&p1=labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/URLParser.java&r1=1030739&r2=1032255&rev=1032255&view=diff
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/URLParser.java
 (original)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/url/WebSocketURL.java
 Sun Nov  7 11:00:41 2010
@@ -16,12 +16,15 @@
  * specific language governing permissions and limitations
  * under the License.    
  */
-package org.apache.monsoon.client;
+package org.apache.monsoon.client.url;
 
 import java.net.MalformedURLException;
 import java.net.URL;
 
-public class URLParser {
+import org.apache.monsoon.client.util.WebSocketConstants;
+import org.apache.monsoon.client.util.WebSocketUtils;
+
+public class WebSocketURL {
 
     private static final String WS = "ws";
     private static final String WSS = "wss";
@@ -30,7 +33,7 @@ public class URLParser {
 
     private URL url;
 
-    public URLParser(String websocketUrl) throws WebSocketURLException {
+    public WebSocketURL(String websocketUrl) throws WebSocketURLException {
         WebSocketUtils.checkNull(websocketUrl, WebSocketConstants.URL_NULL);
         url = parseUrl(websocketUrl);
         if (!checkScheme() || hasFragment() || !isAsciiHost()

Copied: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/url/WebSocketURLException.java
 (from r1029793, 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketURLException.java)
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/url/WebSocketURLException.java?p2=labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/url/WebSocketURLException.java&p1=labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketURLException.java&r1=1029793&r2=1032255&rev=1032255&view=diff
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketURLException.java
 (original)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/url/WebSocketURLException.java
 Sun Nov  7 11:00:41 2010
@@ -16,7 +16,7 @@
  * specific language governing permissions and limitations
  * under the License.    
  */
-package org.apache.monsoon.client;
+package org.apache.monsoon.client.url;
 
 public class WebSocketURLException extends Exception {
 

Copied: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/util/WebSocketConstants.java
 (from r1029793, 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketConstants.java)
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/util/WebSocketConstants.java?p2=labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/util/WebSocketConstants.java&p1=labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketConstants.java&r1=1029793&r2=1032255&rev=1032255&view=diff
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketConstants.java
 (original)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/util/WebSocketConstants.java
 Sun Nov  7 11:00:41 2010
@@ -16,7 +16,7 @@
  * specific language governing permissions and limitations
  * under the License.    
  */
-package org.apache.monsoon.client;
+package org.apache.monsoon.client.util;
 
 public class WebSocketConstants {
 

Copied: 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/util/WebSocketUtils.java
 (from r1030739, 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketUtils.java)
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/util/WebSocketUtils.java?p2=labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/util/WebSocketUtils.java&p1=labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketUtils.java&r1=1030739&r2=1032255&rev=1032255&view=diff
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/WebSocketUtils.java
 (original)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/main/java/org/apache/monsoon/client/util/WebSocketUtils.java
 Sun Nov  7 11:00:41 2010
@@ -16,7 +16,7 @@
  * specific language governing permissions and limitations
  * under the License.    
  */
-package org.apache.monsoon.client;
+package org.apache.monsoon.client.util;
 
 public class WebSocketUtils {
 

Copied: 
labs/monsoon/trunk/modules/monsoon-client/src/test/java/org/apache/monsoon/client/WebSocketURLTest.java
 (from r1030739, 
labs/monsoon/trunk/modules/monsoon-client/src/test/java/org/apache/monsoon/client/WebSocketTest.java)
URL: 
http://svn.apache.org/viewvc/labs/monsoon/trunk/modules/monsoon-client/src/test/java/org/apache/monsoon/client/WebSocketURLTest.java?p2=labs/monsoon/trunk/modules/monsoon-client/src/test/java/org/apache/monsoon/client/WebSocketURLTest.java&p1=labs/monsoon/trunk/modules/monsoon-client/src/test/java/org/apache/monsoon/client/WebSocketTest.java&r1=1030739&r2=1032255&rev=1032255&view=diff
==============================================================================
--- 
labs/monsoon/trunk/modules/monsoon-client/src/test/java/org/apache/monsoon/client/WebSocketTest.java
 (original)
+++ 
labs/monsoon/trunk/modules/monsoon-client/src/test/java/org/apache/monsoon/client/WebSocketURLTest.java
 Sun Nov  7 11:00:41 2010
@@ -18,23 +18,26 @@
  */
 package org.apache.monsoon.client;
 
+import org.apache.monsoon.client.url.WebSocketURL;
+import org.apache.monsoon.client.url.WebSocketURLException;
+
 import junit.framework.Test;
 import junit.framework.TestCase;
 import junit.framework.TestSuite;
 
-public class WebSocketTest extends TestCase {
+public class WebSocketURLTest extends TestCase {
 
-    public WebSocketTest(String testName) {
+    public WebSocketURLTest(String testName) {
         super(testName);
     }
 
     public static Test suite() {
-        return new TestSuite(WebSocketTest.class);
+        return new TestSuite(WebSocketURLTest.class);
     }
 
     public void testNonAbsoluteURL() {
         try {
-            new WebSocket("/monsoon");
+            new WebSocketURL("/monsoon");
             fail();
         } catch (WebSocketURLException e) {
         }
@@ -42,7 +45,7 @@ public class WebSocketTest extends TestC
 
     public void testEmptyScheme() {
         try {
-            new WebSocket("monsoon.apache.org");
+            new WebSocketURL("monsoon.apache.org");
             fail();
         } catch (WebSocketURLException e) {
         }
@@ -50,7 +53,7 @@ public class WebSocketTest extends TestC
 
     public void testEmptySchemeWithSeparator() {
         try {
-            new WebSocket("://monsoon.apache.org");
+            new WebSocketURL("://monsoon.apache.org");
             fail();
         } catch (WebSocketURLException e) {
         }
@@ -58,7 +61,7 @@ public class WebSocketTest extends TestC
 
     public void testInvalidScheme() {
         try {
-            new WebSocket("scheme://monsoon.apache.org");
+            new WebSocketURL("scheme://monsoon.apache.org");
             fail();
         } catch (WebSocketURLException e) {
         }
@@ -66,7 +69,7 @@ public class WebSocketTest extends TestC
 
     public void testInvalidScheme2() {
         try {
-            new WebSocket("http://monsoon.apache.org";);
+            new WebSocketURL("http://monsoon.apache.org";);
             fail();
         } catch (WebSocketURLException e) {
         }
@@ -74,7 +77,7 @@ public class WebSocketTest extends TestC
 
     public void testValidScheme() {
         try {
-            new WebSocket("ws://monsoon.apache.org");
+            new WebSocketURL("ws://monsoon.apache.org");
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -82,7 +85,7 @@ public class WebSocketTest extends TestC
 
     public void testValidSchemeUppercase() {
         try {
-            new WebSocket("WS://monsoon.apache.org");
+            new WebSocketURL("WS://monsoon.apache.org");
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -90,7 +93,7 @@ public class WebSocketTest extends TestC
 
     public void testValidSecureScheme() {
         try {
-            new WebSocket("wss://monsoon.apache.org");
+            new WebSocketURL("wss://monsoon.apache.org");
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -98,7 +101,7 @@ public class WebSocketTest extends TestC
 
     public void testFragment() {
         try {
-            new WebSocket("ws://monsoon.apache.org#fragment");
+            new WebSocketURL("ws://monsoon.apache.org#fragment");
             fail();
         } catch (WebSocketURLException e) {
         }
@@ -106,7 +109,7 @@ public class WebSocketTest extends TestC
 
     public void testFragment2() {
         try {
-            new WebSocket("#fragment");
+            new WebSocketURL("#fragment");
             fail();
         } catch (WebSocketURLException e) {
         }
@@ -114,7 +117,7 @@ public class WebSocketTest extends TestC
 
     public void testValidURL() {
         try {
-            new WebSocket("ws://labs.apache.org:80/monsoon");
+            new WebSocketURL("ws://labs.apache.org:80/monsoon");
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -122,9 +125,9 @@ public class WebSocketTest extends TestC
 
     public void testSecureWs() {
         try {
-            WebSocket websocket = new WebSocket(
+            WebSocketURL webSocketURL = new WebSocketURL(
                     "ws://labs.apache.org:80/monsoon");
-            assertFalse(websocket.isSecure());
+            assertFalse(webSocketURL.isSecure());
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -132,9 +135,9 @@ public class WebSocketTest extends TestC
 
     public void testSecureWss() {
         try {
-            WebSocket websocket = new WebSocket(
+            WebSocketURL webSocketURL = new WebSocketURL(
                     "wss://labs.apache.org:80/monsoon");
-            assertTrue(websocket.isSecure());
+            assertTrue(webSocketURL.isSecure());
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -142,9 +145,9 @@ public class WebSocketTest extends TestC
 
     public void testHost() {
         try {
-            WebSocket websocket = new WebSocket(
+            WebSocketURL webSocketURL = new WebSocketURL(
                     "wss://labs.apache.org:1234/monsoon");
-            assertEquals("labs.apache.org", websocket.getHost());
+            assertEquals("labs.apache.org", webSocketURL.getHost());
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -152,8 +155,8 @@ public class WebSocketTest extends TestC
 
     public void testHost2() {
         try {
-            WebSocket websocket = new WebSocket("wss://monsoon");
-            assertEquals("monsoon", websocket.getHost());
+            WebSocketURL webSocketURL = new WebSocketURL("wss://monsoon");
+            assertEquals("monsoon", webSocketURL.getHost());
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -161,8 +164,9 @@ public class WebSocketTest extends TestC
 
     public void testWsPredefinedPort() {
         try {
-            WebSocket websocket = new WebSocket("ws://monsoon.apache.org");
-            assertEquals(80, websocket.getPort());
+            WebSocketURL webSocketURL = new WebSocketURL(
+                    "ws://monsoon.apache.org");
+            assertEquals(80, webSocketURL.getPort());
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -170,8 +174,9 @@ public class WebSocketTest extends TestC
 
     public void testWssPredefinedPort() {
         try {
-            WebSocket websocket = new WebSocket("wss://monsoon.apache.org");
-            assertEquals(443, websocket.getPort());
+            WebSocketURL webSocketURL = new WebSocketURL(
+                    "wss://monsoon.apache.org");
+            assertEquals(443, webSocketURL.getPort());
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -179,8 +184,9 @@ public class WebSocketTest extends TestC
 
     public void testWsPort() {
         try {
-            WebSocket websocket = new WebSocket("ws://monsoon.apache.org:443");
-            assertEquals(443, websocket.getPort());
+            WebSocketURL webSocketURL = new WebSocketURL(
+                    "ws://monsoon.apache.org:443");
+            assertEquals(443, webSocketURL.getPort());
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -188,8 +194,9 @@ public class WebSocketTest extends TestC
 
     public void testWssPort() {
         try {
-            WebSocket websocket = new WebSocket("wss://monsoon.apache.org:80");
-            assertEquals(80, websocket.getPort());
+            WebSocketURL webSocketURL = new WebSocketURL(
+                    "wss://monsoon.apache.org:80");
+            assertEquals(80, webSocketURL.getPort());
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -197,8 +204,9 @@ public class WebSocketTest extends TestC
 
     public void testResourceWithoutQuery() {
         try {
-            WebSocket websocket = new 
WebSocket("ws://labs.apache.org/monsoon");
-            assertEquals("/monsoon", websocket.getResourceName());
+            WebSocketURL webSocketURL = new WebSocketURL(
+                    "ws://labs.apache.org/monsoon");
+            assertEquals("/monsoon", webSocketURL.getResourceName());
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -206,9 +214,9 @@ public class WebSocketTest extends TestC
 
     public void testResourceWithQuery() {
         try {
-            WebSocket websocket = new WebSocket(
+            WebSocketURL webSocketURL = new WebSocketURL(
                     "ws://labs.apache.org/monsoon?lab=monsoon");
-            assertEquals("/monsoon?lab=monsoon", websocket.getResourceName());
+            assertEquals("/monsoon?lab=monsoon", 
webSocketURL.getResourceName());
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -216,8 +224,8 @@ public class WebSocketTest extends TestC
 
     public void testEmptyResource() {
         try {
-            WebSocket websocket = new WebSocket("ws://labs.apache.org");
-            assertEquals("/", websocket.getResourceName());
+            WebSocketURL webSocketURL = new 
WebSocketURL("ws://labs.apache.org");
+            assertEquals("/", webSocketURL.getResourceName());
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -225,8 +233,9 @@ public class WebSocketTest extends TestC
 
     public void testEmptyResourceWithPort() {
         try {
-            WebSocket websocket = new WebSocket("ws://labs.apache.org:8080");
-            assertEquals("/", websocket.getResourceName());
+            WebSocketURL webSocketURL = new WebSocketURL(
+                    "ws://labs.apache.org:8080");
+            assertEquals("/", webSocketURL.getResourceName());
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -234,9 +243,9 @@ public class WebSocketTest extends TestC
 
     public void testEmptyResourceWithQuery() {
         try {
-            WebSocket websocket = new WebSocket(
+            WebSocketURL webSocketURL = new WebSocketURL(
                     "ws://labs.apache.org:8080/?lab=monsoon");
-            assertEquals("/?lab=monsoon", websocket.getResourceName());
+            assertEquals("/?lab=monsoon", webSocketURL.getResourceName());
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -244,9 +253,9 @@ public class WebSocketTest extends TestC
 
     public void testInvalidQuery() {
         try {
-            WebSocket websocket = new WebSocket(
+            WebSocketURL webSocketURL = new WebSocketURL(
                     "ws://labs.apache.org:8080?lab=monsoon");
-            assertEquals("/?lab=monsoon", websocket.getResourceName());
+            assertEquals("/?lab=monsoon", webSocketURL.getResourceName());
         } catch (WebSocketURLException e) {
             fail(e.getMessage());
         }
@@ -254,7 +263,7 @@ public class WebSocketTest extends TestC
 
     public void testNonASCIIHost() {
         try {
-            new WebSocket("ws://labs£.apache.org:8080?lab=monsoon");
+            new WebSocketURL("ws://labs£.apache.org:8080?lab=monsoon");
             fail();
         } catch (WebSocketURLException e) {
         }
@@ -262,7 +271,7 @@ public class WebSocketTest extends TestC
 
     public void testNonASCIIResource() {
         try {
-            new WebSocket("ws://labs.apache£.org:8080?lab=monsoon");
+            new WebSocketURL("ws://labs.apache£.org:8080?lab=monsoon");
             fail();
         } catch (WebSocketURLException e) {
         }
@@ -270,7 +279,7 @@ public class WebSocketTest extends TestC
 
     public void testNonASCIIResource2() {
         try {
-            new WebSocket("ws://labs.apache.org:8080?lab=mons oon");
+            new WebSocketURL("ws://labs.apache.org:8080?lab=mons oon");
             fail();
         } catch (WebSocketURLException e) {
         }



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to