harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From telli...@apache.org
Subject svn commit: r391955 [4/5] - in /incubator/harmony/enhanced/classlib/trunk: make/patternsets/ modules/ modules/archive/META-INF/ modules/archive/src/main/java/java/util/jar/ modules/archive/src/main/java/java/util/zip/ modules/jndi/src/main/java/com/ mo...
Date Thu, 06 Apr 2006 10:42:32 GMT
Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/ServerSocket.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/ServerSocket.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/ServerSocket.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/ServerSocket.java Thu Apr  6 03:42:13 2006
@@ -15,12 +15,12 @@
 
 package java.net;
 
+
 import java.io.IOException;
 
 import org.apache.harmony.luni.net.SocketImplProvider;
 
-
-import com.ibm.oti.util.Msg;
+import org.apache.harmony.luni.util.Msg;
 
 /**
  * ServerSocket create connections between 'host' and 'client' machines. The
@@ -32,115 +32,115 @@
  */
 public class ServerSocket {
 
-    SocketImpl impl;
+	SocketImpl impl;
 
-    static SocketImplFactory factory;
+	static SocketImplFactory factory;
 
-    private volatile boolean isCreated = false;
+	private volatile boolean isCreated = false;
 
-    private boolean isBound = false;
+	private boolean isBound = false;
 
-    private boolean isClosed = false;
+	private boolean isClosed = false;
 
-    /**
-     * Construct a ServerSocket, which is not bound to any port. The default
-     * number of pending connections may be backlogged.
-     * 
-     * @see Socket
-     */
-    public ServerSocket() throws IOException {
-        impl = factory != null ? factory.createSocketImpl()
+	/**
+	 * Construct a ServerSocket, which is not bound to any port. The default
+	 * number of pending connections may be backlogged.
+	 * 
+	 * @see Socket
+	 */
+	public ServerSocket() throws IOException {
+		impl = factory != null ? factory.createSocketImpl()
                 :SocketImplProvider.getServerSocketImpl();
-    }
-    
+	}
+
     protected ServerSocket(SocketImpl impl){
         this.impl = impl;
     }
 
-    /**
-     * Construct a ServerSocket, bound to the nominated port on the default
-     * localhost. The default number of pending connections may be backlogged.
-     * 
-     * @param aport
-     *            the port number to listen for connection requests on
-     * @see Socket
-     */
-    public ServerSocket(int aport) throws IOException {
-        this(aport, defaultBacklog(), InetAddress.ANY);
-    }
-
-    /**
-     * Construct a ServerSocket, bound to the nominated port on the default
-     * localhost. The number of pending connections that may be backlogged is a
-     * specified.
-     * 
-     * @param aport
-     *            the port number to listen for connection requests on
-     * @param backlog
-     *            the number of pending connection requests, before requests are
-     *            rejected
-     * @see Socket
-     */
-    public ServerSocket(int aport, int backlog) throws IOException {
-        this(aport, backlog, InetAddress.ANY);
-    }
-
-    /**
-     * Construct a ServerSocket, bound to the nominated local host/port. The
-     * number of pending connections that may be backlogged is a specified.
-     * 
-     * @param aport
-     *            the port number to listen for connection requests on
-     * @param localAddr
-     *            the local machine address to bind on
-     * @param backlog
-     *            the number of pending connection requests, before requests are
-     *            rejected
-     * @see Socket
-     */
-    public ServerSocket(int aport, int backlog, InetAddress localAddr)
-            throws IOException {
-        super();
-        checkListen(aport);
-        impl = factory != null ? factory.createSocketImpl()
+	/**
+	 * Construct a ServerSocket, bound to the nominated port on the default
+	 * localhost. The default number of pending connections may be backlogged.
+	 * 
+	 * @param aport
+	 *            the port number to listen for connection requests on
+	 * @see Socket
+	 */
+	public ServerSocket(int aport) throws IOException {
+		this(aport, defaultBacklog(), InetAddress.ANY);
+	}
+
+	/**
+	 * Construct a ServerSocket, bound to the nominated port on the default
+	 * localhost. The number of pending connections that may be backlogged is a
+	 * specified.
+	 * 
+	 * @param aport
+	 *            the port number to listen for connection requests on
+	 * @param backlog
+	 *            the number of pending connection requests, before requests are
+	 *            rejected
+	 * @see Socket
+	 */
+	public ServerSocket(int aport, int backlog) throws IOException {
+		this(aport, backlog, InetAddress.ANY);
+	}
+
+	/**
+	 * Construct a ServerSocket, bound to the nominated local host/port. The
+	 * number of pending connections that may be backlogged is a specified.
+	 * 
+	 * @param aport
+	 *            the port number to listen for connection requests on
+	 * @param localAddr
+	 *            the local machine address to bind on
+	 * @param backlog
+	 *            the number of pending connection requests, before requests are
+	 *            rejected
+	 * @see Socket
+	 */
+	public ServerSocket(int aport, int backlog, InetAddress localAddr)
+			throws IOException {
+		super();
+		checkListen(aport);
+		impl = factory != null ? factory.createSocketImpl()
                 : SocketImplProvider.getServerSocketImpl();
-        InetAddress addr = localAddr == null ? InetAddress.ANY : localAddr;
+		InetAddress addr = localAddr == null ? InetAddress.ANY : localAddr;
 
-        synchronized (this) {
-            impl.create(true);
-            isCreated = true;
-            try {
-                impl.bind(addr, aport);
-                isBound = true;
-                impl.listen(backlog > 0 ? backlog : defaultBacklog());
-            } catch (IOException e) {
-                close();
-                throw e;
-            }
-        }
-    }
-
-    /**
-     * Retrieve the first connection request and answer the 'host' socket that
-     * will conduct further communications with the requesting 'client' socket.
-     * 
-     * @return Socket the 'host' socket
-     * @exception IOException
-     *                if an error occurs while instantiating the 'host' socket
-     */
-    public Socket accept() throws IOException {
-        checkClosedAndCreate(false);
-        if (!isBound())
-            throw new SocketException(Msg.getString("K031f"));
-
-        // If a SOCKS proxy is being used, accept does strange things.
-        // Instead of returning a new Socket and allowing this ServerSocket
-        // to be used for another accept, it actually uses the current
-        // ServerSocket
-        // as the accepted Socket. So, closing the returned socket will close
-        // the
-        // ServerSocket as well. The ServerSocket cannot be used for a second
-        // accept.
+		synchronized (this) {
+			impl.create(true);
+			isCreated = true;
+			try {
+				impl.bind(addr, aport);
+				isBound = true;
+				impl.listen(backlog > 0 ? backlog : defaultBacklog());
+			} catch (IOException e) {
+				close();
+				throw e;
+			}
+		}
+	}
+
+	/**
+	 * Retrieve the first connection request and answer the 'host' socket that
+	 * will conduct further communications with the requesting 'client' socket.
+	 * 
+	 * @return Socket the 'host' socket
+	 * @exception IOException
+	 *                if an error occurs while instantiating the 'host' socket
+	 */
+	public Socket accept() throws IOException {
+		checkClosedAndCreate(false);
+		if (!isBound())
+			throw new SocketException(Msg.getString("K031f"));
+
+		// If a SOCKS proxy is being used, accept does strange things.
+		// Instead of returning a new Socket and allowing this ServerSocket
+		// to be used for another accept, it actually uses the current
+		// ServerSocket
+		// as the accepted Socket. So, closing the returned socket will close
+		// the
+		// ServerSocket as well. The ServerSocket cannot be used for a second
+		// accept.
         //FIXME: paulex comment this for compile
 //        if (IOUtil.usingSocks()) {
 //            if (impl instanceof PlainSocketImpl) {
@@ -162,93 +162,93 @@
 //            throw new IOException(Msg.getString("K0041")); //$NON-NLS-1$
 //        }
 
-        Socket aSocket = new Socket();
-        try {
-            synchronized (this) {
-                implAccept(aSocket);
-            }
-            SecurityManager security = System.getSecurityManager();
-            if (security != null) {
+		Socket aSocket = new Socket();
+		try {
+			synchronized (this) {
+				implAccept(aSocket);
+			}
+			SecurityManager security = System.getSecurityManager();
+			if (security != null) {
                 security.checkAccept(aSocket.getInetAddress().getHostAddress(),
-                        aSocket.getPort());
-            }
-        } catch (SecurityException e) {
-            aSocket.close();
-            throw e;
-        } catch (IOException e) {
-            aSocket.close();
-            throw e;
-        }
-        return aSocket;
-    }
-
-    /**
-     * Check whether the server may listen for connection requests on
-     * <code>aport</code>. Throw an exception if the port is outside the
-     * valid range or does not satisfy the security policy.
-     * 
-     * @param aPort
-     *            the candidate port to listen on
-     */
-    void checkListen(int aPort) {
-        if (aPort < 0 || aPort > 65535)
-            throw new IllegalArgumentException(Msg.getString("K0325", aPort)); //$NON-NLS-1$
-        SecurityManager security = System.getSecurityManager();
-        if (security != null)
-            security.checkListen(aPort);
-    }
-
-    /**
-     * Close this server socket. Any attempt to connect to this socket
-     * thereafter will fail.
-     */
-    public void close() throws IOException {
-        isClosed = true;
-        impl.close();
-    }
-
-    /**
-     * Answer the default number of pending connections on a server socket.
-     * 
-     * @return int the default number of pending connection requests
-     */
-    static int defaultBacklog() {
-        return 50;
-    }
-
-    /**
-     * Answer the local IP address for this server socket. Return null if the
-     * socket is not bound. This is useful on multihomed hosts.
-     * 
-     * @return InetAddress the local address
-     */
-    public InetAddress getInetAddress() {
-        if (!isBound())
-            return null;
-        return impl.getInetAddress();
-    }
-
-    /**
-     * Answer the local port for this server socket. Return -1 if the socket is
-     * not bound.
-     * 
-     * @return int the local port the server is listening on
-     */
-    public int getLocalPort() {
-        if (!isBound())
-            return -1;
-        return impl.getLocalPort();
-    }
-
-    /**
-     * Answer the time-out period of this server socket. This is the time the
-     * server will wait listening for connections, before exiting.
-     * 
-     * @return int the listening timeout
-     * @exception SocketException
-     *                thrown if option cannot be retrieved
-     */
-    public synchronized int getSoTimeout() throws IOException {
+						aSocket.getPort());
+			}
+		} catch (SecurityException e) {
+			aSocket.close();
+			throw e;
+		} catch (IOException e) {
+			aSocket.close();
+			throw e;
+		}
+		return aSocket;
+	}
+
+	/**
+	 * Check whether the server may listen for connection requests on
+	 * <code>aport</code>. Throw an exception if the port is outside the
+	 * valid range or does not satisfy the security policy.
+	 * 
+	 * @param aPort
+	 *            the candidate port to listen on
+	 */
+	void checkListen(int aPort) {
+		if (aPort < 0 || aPort > 65535)
+			throw new IllegalArgumentException(Msg.getString("K0325", aPort)); //$NON-NLS-1$
+		SecurityManager security = System.getSecurityManager();
+		if (security != null)
+			security.checkListen(aPort);
+	}
+
+	/**
+	 * Close this server socket. Any attempt to connect to this socket
+	 * thereafter will fail.
+	 */
+	public void close() throws IOException {
+		isClosed = true;
+		impl.close();
+	}
+
+	/**
+	 * Answer the default number of pending connections on a server socket.
+	 * 
+	 * @return int the default number of pending connection requests
+	 */
+	static int defaultBacklog() {
+		return 50;
+	}
+
+	/**
+	 * Answer the local IP address for this server socket. Return null if the
+	 * socket is not bound. This is useful on multihomed hosts.
+	 * 
+	 * @return InetAddress the local address
+	 */
+	public InetAddress getInetAddress() {
+		if (!isBound())
+			return null;
+		return impl.getInetAddress();
+	}
+
+	/**
+	 * Answer the local port for this server socket. Return -1 if the socket is
+	 * not bound.
+	 * 
+	 * @return int the local port the server is listening on
+	 */
+	public int getLocalPort() {
+		if (!isBound())
+			return -1;
+		return impl.getLocalPort();
+	}
+
+	/**
+	 * Answer the time-out period of this server socket. This is the time the
+	 * server will wait listening for connections, before exiting.
+	 * 
+	 * @return int the listening timeout
+	 * @exception SocketException
+	 *                thrown if option cannot be retrieved
+	 */
+	public synchronized int getSoTimeout() throws IOException {
         // TODO Bug-Reporter:check changed! checkClosedAndCreate(true);
         if (!isCreated) {
             synchronized (this) {
@@ -265,239 +265,239 @@
                 }
             }
         }
-        return ((Integer) impl.getOption(SocketOptions.SO_TIMEOUT)).intValue();
-    }
-
-    /**
-     * Invoke the server socket implementation to accept a connection on the
-     * newly created <code>aSocket</code>.
-     * 
-     * @param aSocket
-     *            the concrete socketImpl to accept the connection request on
-     * @exception IOException
-     *                thrown if connection cannot be accepted
-     */
-    protected final void implAccept(Socket aSocket) throws IOException {
-        impl.accept(aSocket.impl);
-        aSocket.accepted();
-    }
-
-    /**
-     * Set the server socket implementation factory. This method may only be
-     * invoked with sufficient security and only once during the application
-     * lifetime.
-     * 
-     * @param aFactory
-     *            the streaming socket factory to be used for further socket
-     *            instantiations
-     * @exception IOException
-     *                thrown if the factory is already set
-     */
-    public static synchronized void setSocketFactory(SocketImplFactory aFactory)
-            throws IOException {
-        SecurityManager security = System.getSecurityManager();
-        if (security != null)
-            security.checkSetFactory();
-        if (factory == null)
-            factory = aFactory;
-        else
-            throw new SocketException(Msg.getString("K0042")); //$NON-NLS-1$
-    }
-
-    /**
-     * Set the listen time-out period for this server socket.
-     * 
-     * @param timeout
-     *            the time to wait for a connection request
-     * @exception SocketException
-     *                thrown if an error occurs during setting the option
-     */
-    public synchronized void setSoTimeout(int timeout) throws SocketException {
-        checkClosedAndCreate(true);
-        if (timeout >= 0) {
-            impl.setOption(SocketOptions.SO_TIMEOUT, new Integer(timeout));
-        } else {
-            throw new IllegalArgumentException(Msg.getString("K0036")); //$NON-NLS-1$
-        }
-    }
-
-    /**
-     * Answers a string containing a concise, human-readable description of the
-     * server socket. The <code>port</code> field is reported a zero, as there
-     * is no connection formed to the server.
-     * 
-     * @return String the description
-     */
-    public String toString() {
-        StringBuffer result = new StringBuffer(64);
-        result.append("ServerSocket["); //$NON-NLS-1$
-        if (!isBound())
-            return result.append("unbound]").toString(); //$NON-NLS-1$
-        return result.append("addr="). //$NON-NLS-1$
-                append(getInetAddress()).append(",port=0,localport="). //$NON-NLS-1$
-                append(getLocalPort()).append("]"). //$NON-NLS-1$
-                toString();
-    }
-
-    /**
-     * Bind the ServerSocket to the nominated local host/port. The default
-     * number of pending connections may be backlogged.
-     * 
-     * @param localAddr
-     *            the local machine address and port to bind on
-     * 
-     * @exception IllegalArgumentException
-     *                if the SocketAddress is not supported
-     * @exception IOException
-     *                if the socket is already bound, or a problem occurs during
-     *                the bind
-     */
-    public void bind(SocketAddress localAddr) throws IOException {
-        bind(localAddr, defaultBacklog());
-    }
-
-    /**
-     * Bind the ServerSocket to the nominated local host/port. The number of
-     * pending connections that may be backlogged is a specified.
-     * 
-     * @param localAddr
-     *            the local machine address and port to bind on
-     * @param backlog
-     *            the number of pending connection requests, before requests are
-     *            rejected
-     * 
-     * @exception IllegalArgumentException
-     *                if the SocketAddress is not supported
-     * @exception IOException
-     *                if the socket is already bound, or a problem occurs during
-     *                the bind
-     */
-    public void bind(SocketAddress localAddr, int backlog) throws IOException {
-        checkClosedAndCreate(true);
-        if (isBound())
-            throw new BindException(Msg.getString("K0315")); //$NON-NLS-1$
-        int port = 0;
-        InetAddress addr = InetAddress.ANY;
-        if (localAddr != null) {
-            if (!(localAddr instanceof InetSocketAddress))
-                throw new IllegalArgumentException(Msg.getString(
-                        "K0316", localAddr.getClass())); //$NON-NLS-1$
-            InetSocketAddress inetAddr = (InetSocketAddress) localAddr;
-            if ((addr = inetAddr.getAddress()) == null)
-                throw new SocketException(Msg.getString(
-                        "K0317", inetAddr.getHostName())); //$NON-NLS-1$
-            port = inetAddr.getPort();
-        }
-        SecurityManager security = System.getSecurityManager();
-        if (security != null)
-            security.checkListen(port);
-
-        synchronized (this) {
-            try {
-                impl.bind(addr, port);
-                isBound = true;
-                impl.listen(backlog > 0 ? backlog : defaultBacklog());
-            } catch (IOException e) {
-                close();
-                throw e;
-            }
-        }
-    }
-
-    /**
-     * Answer the local SocketAddress for this server socket, or null if the
-     * socket is not bound. This is useful on multihomed hosts.
-     */
-    public SocketAddress getLocalSocketAddress() {
-        if (!isBound())
-            return null;
-        return new InetSocketAddress(getInetAddress(), getLocalPort());
-    }
+		return ((Integer) impl.getOption(SocketOptions.SO_TIMEOUT)).intValue();
+	}
 
-    /**
-     * Return if the server socket is bound to a local address and port.
-     */
-    public boolean isBound() {
-        return isBound;
-    }
-
-    /**
-     * Return if the server socket is closed.
-     */
-    public boolean isClosed() {
-        return isClosed;
-    }
-
-    /**
-     * Check if the socket is closed, and throw an exception.
-     */
-    private void checkClosedAndCreate(boolean create) throws SocketException {
-        if (isClosed())
-            throw new SocketException(Msg.getString("K003d"));
-
-        if (!create || isCreated)
-            return;
-
-        synchronized (this) {
-            if (isCreated)
-                return;
-            try {
-                impl.create(true);
-            } catch (SocketException e) {
-                throw e;
-            } catch (IOException e) {
-                throw new SocketException(e.toString());
-            }
-            isCreated = true;
-        }
-    }
-
-    /**
-     * Set the SO_REUSEADDR socket option.
-     * 
-     * @param reuse
-     *            the socket SO_REUSEADDR option setting
-     */
-    public void setReuseAddress(boolean reuse) throws SocketException {
-        checkClosedAndCreate(true);
-        impl.setOption(SocketOptions.SO_REUSEADDR, reuse ? Boolean.TRUE
-                : Boolean.FALSE);
-    }
-
-    /**
-     * Get the state of the SO_REUSEADDR socket option.
-     */
-    public boolean getReuseAddress() throws SocketException {
-        checkClosedAndCreate(true);
-        return ((Boolean) impl.getOption(SocketOptions.SO_REUSEADDR))
-                .booleanValue();
-    }
-
-    /**
-     * Set the socket receive buffer size.
-     * 
-     * @param size
-     *            the buffer size, in bytes
-     * 
-     * @exception java.net.SocketException
-     *                If an error occurs while setting the size or the size is
-     *                invalid.
-     */
-    public void setReceiveBufferSize(int size) throws SocketException {
-        checkClosedAndCreate(true);
-        if (size >= 1)
-            impl.setOption(SocketOptions.SO_RCVBUF, new Integer(size));
-        else
-            throw new IllegalArgumentException(Msg.getString("K0035")); //$NON-NLS-1$
-    }
-
-    /**
-     * Answer the socket receive buffer size (SO_RCVBUF).
-     * 
-     * @return int socket receive buffer size
-     */
-    public int getReceiveBufferSize() throws SocketException {
-        checkClosedAndCreate(true);
-        return ((Integer) impl.getOption(SocketOptions.SO_RCVBUF)).intValue();
-    }
+	/**
+	 * Invoke the server socket implementation to accept a connection on the
+	 * newly created <code>aSocket</code>.
+	 * 
+	 * @param aSocket
+	 *            the concrete socketImpl to accept the connection request on
+	 * @exception IOException
+	 *                thrown if connection cannot be accepted
+	 */
+	protected final void implAccept(Socket aSocket) throws IOException {
+		impl.accept(aSocket.impl);
+		aSocket.accepted();
+	}
+
+	/**
+	 * Set the server socket implementation factory. This method may only be
+	 * invoked with sufficient security and only once during the application
+	 * lifetime.
+	 * 
+	 * @param aFactory
+	 *            the streaming socket factory to be used for further socket
+	 *            instantiations
+	 * @exception IOException
+	 *                thrown if the factory is already set
+	 */
+	public static synchronized void setSocketFactory(SocketImplFactory aFactory)
+			throws IOException {
+		SecurityManager security = System.getSecurityManager();
+		if (security != null)
+			security.checkSetFactory();
+		if (factory == null)
+			factory = aFactory;
+		else
+			throw new SocketException(Msg.getString("K0042")); //$NON-NLS-1$
+	}
+
+	/**
+	 * Set the listen time-out period for this server socket.
+	 * 
+	 * @param timeout
+	 *            the time to wait for a connection request
+	 * @exception SocketException
+	 *                thrown if an error occurs during setting the option
+	 */
+	public synchronized void setSoTimeout(int timeout) throws SocketException {
+		checkClosedAndCreate(true);
+		if (timeout >= 0) {
+			impl.setOption(SocketOptions.SO_TIMEOUT, new Integer(timeout));
+		} else {
+			throw new IllegalArgumentException(Msg.getString("K0036")); //$NON-NLS-1$
+		}
+	}
+
+	/**
+	 * Answers a string containing a concise, human-readable description of the
+	 * server socket. The <code>port</code> field is reported a zero, as there
+	 * is no connection formed to the server.
+	 * 
+	 * @return String the description
+	 */
+	public String toString() {
+		StringBuffer result = new StringBuffer(64);
+		result.append("ServerSocket["); //$NON-NLS-1$
+		if (!isBound())
+			return result.append("unbound]").toString(); //$NON-NLS-1$
+		return result.append("addr="). //$NON-NLS-1$
+				append(getInetAddress()).append(",port=0,localport="). //$NON-NLS-1$
+				append(getLocalPort()).append("]"). //$NON-NLS-1$
+				toString();
+	}
+
+	/**
+	 * Bind the ServerSocket to the nominated local host/port. The default
+	 * number of pending connections may be backlogged.
+	 * 
+	 * @param localAddr
+	 *            the local machine address and port to bind on
+	 * 
+	 * @exception IllegalArgumentException
+	 *                if the SocketAddress is not supported
+	 * @exception IOException
+	 *                if the socket is already bound, or a problem occurs during
+	 *                the bind
+	 */
+	public void bind(SocketAddress localAddr) throws IOException {
+		bind(localAddr, defaultBacklog());
+	}
+
+	/**
+	 * Bind the ServerSocket to the nominated local host/port. The number of
+	 * pending connections that may be backlogged is a specified.
+	 * 
+	 * @param localAddr
+	 *            the local machine address and port to bind on
+	 * @param backlog
+	 *            the number of pending connection requests, before requests are
+	 *            rejected
+	 * 
+	 * @exception IllegalArgumentException
+	 *                if the SocketAddress is not supported
+	 * @exception IOException
+	 *                if the socket is already bound, or a problem occurs during
+	 *                the bind
+	 */
+	public void bind(SocketAddress localAddr, int backlog) throws IOException {
+		checkClosedAndCreate(true);
+		if (isBound())
+			throw new BindException(Msg.getString("K0315")); //$NON-NLS-1$
+		int port = 0;
+		InetAddress addr = InetAddress.ANY;
+		if (localAddr != null) {
+			if (!(localAddr instanceof InetSocketAddress))
+				throw new IllegalArgumentException(Msg.getString(
+						"K0316", localAddr.getClass())); //$NON-NLS-1$
+			InetSocketAddress inetAddr = (InetSocketAddress) localAddr;
+			if ((addr = inetAddr.getAddress()) == null)
+				throw new SocketException(Msg.getString(
+						"K0317", inetAddr.getHostName())); //$NON-NLS-1$
+			port = inetAddr.getPort();
+		}
+		SecurityManager security = System.getSecurityManager();
+		if (security != null)
+			security.checkListen(port);
+
+		synchronized (this) {
+			try {
+				impl.bind(addr, port);
+				isBound = true;
+				impl.listen(backlog > 0 ? backlog : defaultBacklog());
+			} catch (IOException e) {
+				close();
+				throw e;
+			}
+		}
+	}
+
+	/**
+	 * Answer the local SocketAddress for this server socket, or null if the
+	 * socket is not bound. This is useful on multihomed hosts.
+	 */
+	public SocketAddress getLocalSocketAddress() {
+		if (!isBound())
+			return null;
+		return new InetSocketAddress(getInetAddress(), getLocalPort());
+	}
+
+	/**
+	 * Return if the server socket is bound to a local address and port.
+	 */
+	public boolean isBound() {
+		return isBound;
+	}
+
+	/**
+	 * Return if the server socket is closed.
+	 */
+	public boolean isClosed() {
+		return isClosed;
+	}
+
+	/**
+	 * Check if the socket is closed, and throw an exception.
+	 */
+	private void checkClosedAndCreate(boolean create) throws SocketException {
+		if (isClosed())
+			throw new SocketException(Msg.getString("K003d"));
+
+		if (!create || isCreated)
+			return;
+
+		synchronized (this) {
+			if (isCreated)
+				return;
+			try {
+				impl.create(true);
+			} catch (SocketException e) {
+				throw e;
+			} catch (IOException e) {
+				throw new SocketException(e.toString());
+			}
+			isCreated = true;
+		}
+	}
+
+	/**
+	 * Set the SO_REUSEADDR socket option.
+	 * 
+	 * @param reuse
+	 *            the socket SO_REUSEADDR option setting
+	 */
+	public void setReuseAddress(boolean reuse) throws SocketException {
+		checkClosedAndCreate(true);
+		impl.setOption(SocketOptions.SO_REUSEADDR, reuse ? Boolean.TRUE
+				: Boolean.FALSE);
+	}
+
+	/**
+	 * Get the state of the SO_REUSEADDR socket option.
+	 */
+	public boolean getReuseAddress() throws SocketException {
+		checkClosedAndCreate(true);
+		return ((Boolean) impl.getOption(SocketOptions.SO_REUSEADDR))
+				.booleanValue();
+	}
+
+	/**
+	 * Set the socket receive buffer size.
+	 * 
+	 * @param size
+	 *            the buffer size, in bytes
+	 * 
+	 * @exception java.net.SocketException
+	 *                If an error occurs while setting the size or the size is
+	 *                invalid.
+	 */
+	public void setReceiveBufferSize(int size) throws SocketException {
+		checkClosedAndCreate(true);
+		if (size >= 1)
+			impl.setOption(SocketOptions.SO_RCVBUF, new Integer(size));
+		else
+			throw new IllegalArgumentException(Msg.getString("K0035")); //$NON-NLS-1$
+	}
+
+	/**
+	 * Answer the socket receive buffer size (SO_RCVBUF).
+	 * 
+	 * @return int socket receive buffer size
+	 */
+	public int getReceiveBufferSize() throws SocketException {
+		checkClosedAndCreate(true);
+		return ((Integer) impl.getOption(SocketOptions.SO_RCVBUF)).intValue();
+	}
 }

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/Socket.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/Socket.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/Socket.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/Socket.java Thu Apr  6 03:42:13 2006
@@ -25,8 +25,8 @@
 import org.apache.harmony.luni.net.SocketImplProvider;
 import org.apache.harmony.luni.platform.Platform;
 
-import com.ibm.oti.util.Msg;
-import com.ibm.oti.util.PriviAction;
+import org.apache.harmony.luni.util.Msg;
+import org.apache.harmony.luni.util.PriviAction;
 
 /**
  * This class represents sockets to be used in connection-oriented (streaming)

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/SocketPermission.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/SocketPermission.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/SocketPermission.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/SocketPermission.java Thu Apr  6 03:42:13 2006
@@ -23,8 +23,8 @@
 import java.security.Permission;
 import java.security.PermissionCollection;
 
-import com.ibm.oti.util.Inet6Util;
-import com.ibm.oti.util.Msg;
+import org.apache.harmony.luni.util.Inet6Util;
+import org.apache.harmony.luni.util.Msg;
 
 /**
  * SocketPermissions represent permission to access resources via sockets. The

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URI.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URI.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URI.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URI.java Thu Apr  6 03:42:13 2006
@@ -23,7 +23,7 @@
 import java.io.UnsupportedEncodingException;
 import java.util.StringTokenizer;
 
-import com.ibm.oti.util.Msg;
+import org.apache.harmony.luni.util.Msg;
 
 /**
  * This class represents an instance of a URI as defined by RFC 2396.

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URIEncoderDecoder.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URIEncoderDecoder.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URIEncoderDecoder.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URIEncoderDecoder.java Thu Apr  6 03:42:13 2006
@@ -19,7 +19,7 @@
 import java.io.ByteArrayOutputStream;
 import java.io.UnsupportedEncodingException;
 
-import com.ibm.oti.util.Msg;
+import org.apache.harmony.luni.util.Msg;
 
 /**
  * This class is used to encode a string using the format required by

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URISyntaxException.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URISyntaxException.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URISyntaxException.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URISyntaxException.java Thu Apr  6 03:42:13 2006
@@ -15,7 +15,7 @@
 
 package java.net;
 
-import com.ibm.oti.util.Msg;
+import org.apache.harmony.luni.util.Msg;
 
 
 /**

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URL.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URL.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URL.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URL.java Thu Apr  6 03:42:13 2006
@@ -22,7 +22,7 @@
 import java.util.Hashtable;
 import java.util.StringTokenizer;
 
-import com.ibm.oti.util.PriviAction;
+import org.apache.harmony.luni.util.PriviAction;
 
 /**
  * An instance of class URL specifies the location of a resource on the world
@@ -130,7 +130,7 @@
 	public static synchronized void setURLStreamHandlerFactory(
 			URLStreamHandlerFactory streamFactory) {
 		if (streamHandlerFactory != null)
-			throw new Error(com.ibm.oti.util.Msg.getString("K004b"));
+			throw new Error(org.apache.harmony.luni.util.Msg.getString("K004b"));
 		SecurityManager sm = System.getSecurityManager();
 		if (sm != null)
 			sm.checkSetFactory();
@@ -281,7 +281,7 @@
 			// values in the context, but still allow them to be over-ridden
 			// by the values in the ("relative") spec.
 			if (context == null)
-				throw new MalformedURLException(com.ibm.oti.util.Msg.getString(
+				throw new MalformedURLException(org.apache.harmony.luni.util.Msg.getString(
 						"K00d8", spec));
 			set(context.getProtocol(), context.getHost(), context.getPort(),
 					context.getAuthority(), context.getUserInfo(), context
@@ -295,7 +295,7 @@
 		if (strmHandler == null) {
 			setupStreamHandler();
 			if (strmHandler == null)
-				throw new MalformedURLException(com.ibm.oti.util.Msg.getString(
+				throw new MalformedURLException(org.apache.harmony.luni.util.Msg.getString(
 						"K00b3", protocol));
 		}
 
@@ -314,7 +314,7 @@
 		}
 
 		if (port < -1)
-			throw new MalformedURLException(com.ibm.oti.util.Msg.getString(
+			throw new MalformedURLException(org.apache.harmony.luni.util.Msg.getString(
 					"K0325", port)); //$NON-NLS-1$
 	}
 
@@ -379,7 +379,7 @@
 	public URL(String protocol, String host, int port, String file,
 			URLStreamHandler handler) throws MalformedURLException {
 		if (port < -1)
-			throw new MalformedURLException(com.ibm.oti.util.Msg.getString(
+			throw new MalformedURLException(org.apache.harmony.luni.util.Msg.getString(
 					"K0325", port)); //$NON-NLS-1$
 
 		if (host != null && host.indexOf(":") != -1 && host.charAt(0) != '[') {
@@ -408,7 +408,7 @@
 		if (handler == null) {
 			setupStreamHandler();
 			if (strmHandler == null)
-				throw new MalformedURLException(com.ibm.oti.util.Msg.getString(
+				throw new MalformedURLException(org.apache.harmony.luni.util.Msg.getString(
 						"K00b3", protocol));
 		} else {
 			SecurityManager sm = System.getSecurityManager();
@@ -566,7 +566,7 @@
 
 		// No one else has provided a handler, so try our internal one.
 		try {
-			String className = "com.ibm.oti.net.www.protocol." + protocol
+			String className = "org.apache.harmony.luni.internal.net.www.protocol." + protocol
 					+ ".Handler";
 			strmHandler = (URLStreamHandler) Class.forName(className)
 					.newInstance();
@@ -681,7 +681,7 @@
 			}
 			setupStreamHandler();
 			if (strmHandler == null)
-				throw new IOException(com.ibm.oti.util.Msg.getString("K00b3",
+				throw new IOException(org.apache.harmony.luni.util.Msg.getString("K00b3",
 						protocol));
 		} catch (ClassNotFoundException e) {
 			throw new java.io.IOException(e.toString());

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URLClassLoader.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URLClassLoader.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URLClassLoader.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URLClassLoader.java Thu Apr  6 03:42:13 2006
@@ -44,7 +44,7 @@
 import java.util.jar.Manifest;
 import java.util.zip.ZipEntry;
 
-import com.ibm.oti.util.InvalidJarIndexException;
+import org.apache.harmony.luni.util.InvalidJarIndexException;
 
 /**
  * This class loader is responsible for loading classes and resources from a
@@ -1079,7 +1079,7 @@
 									exception = packageObj.isSealed();
 								if (exception)
 									throw new SecurityException(
-											com.ibm.oti.util.Msg
+											org.apache.harmony.luni.util.Msg
 													.getString("K004c"));
 							}
 						}

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URLConnection.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URLConnection.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URLConnection.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URLConnection.java Thu Apr  6 03:42:13 2006
@@ -28,9 +28,9 @@
 
 import org.apache.harmony.luni.internal.net.www.MimeTable;
 
-import com.ibm.oti.util.Msg;
-import com.ibm.oti.util.PriviAction;
-import com.ibm.oti.util.Util;
+import org.apache.harmony.luni.util.Msg;
+import org.apache.harmony.luni.util.PriviAction;
+import org.apache.harmony.luni.util.Util;
 
 /**
  * The URLConnection class is responsible for establishing a connection to an
@@ -229,7 +229,7 @@
 			cHandler = AccessController.doPrivileged(new PrivilegedAction() {
 				public Object run() {
 					try {
-						String className = "com.ibm.oti.www.content."
+						String className = "org.apache.harmony.luni.internal.net.www.content."
 								+ typeString;
 						return Class.forName(className).newInstance();
 					} catch (ClassNotFoundException e) {

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URLDecoder.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URLDecoder.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URLDecoder.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/net/URLDecoder.java Thu Apr  6 03:42:13 2006
@@ -19,8 +19,8 @@
 import java.io.ByteArrayOutputStream;
 import java.io.UnsupportedEncodingException;
 
-import com.ibm.oti.util.Msg;
-import com.ibm.oti.util.Util;
+import org.apache.harmony.luni.util.Msg;
+import org.apache.harmony.luni.util.Util;
 
 /**
  * This class is used to decode a string which is encoded in the

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/BitSet.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/BitSet.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/BitSet.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/BitSet.java Thu Apr  6 03:42:13 2006
@@ -18,7 +18,7 @@
 
 import java.io.Serializable;
 
-import com.ibm.oti.util.Msg;
+import org.apache.harmony.luni.util.Msg;
 
 /**
  * The BitSet class implements a bit field. Each element in a BitSet can be
@@ -280,7 +280,7 @@
 				growBits(pos);
 			bits[pos / ELM_SIZE] |= 1L << (pos % ELM_SIZE);
 		} else
-			throw new IndexOutOfBoundsException(com.ibm.oti.util.Msg
+			throw new IndexOutOfBoundsException(org.apache.harmony.luni.util.Msg
 					.getString("K0006")); //$NON-NLS-1$
 	}
 
@@ -450,7 +450,7 @@
 				growBits(pos);
 			bits[pos / ELM_SIZE] ^= 1L << (pos % ELM_SIZE);
 		} else
-			throw new IndexOutOfBoundsException(com.ibm.oti.util.Msg
+			throw new IndexOutOfBoundsException(org.apache.harmony.luni.util.Msg
 					.getString("K0006")); //$NON-NLS-1$
 	}
 
@@ -688,7 +688,7 @@
 
 			return -1;
 		} else
-			throw new IndexOutOfBoundsException(com.ibm.oti.util.Msg
+			throw new IndexOutOfBoundsException(org.apache.harmony.luni.util.Msg
 					.getString("K0006")); //$NON-NLS-1$
 	}
 
@@ -728,7 +728,7 @@
 
 			return bssize;
 		} else
-			throw new IndexOutOfBoundsException(com.ibm.oti.util.Msg
+			throw new IndexOutOfBoundsException(org.apache.harmony.luni.util.Msg
 					.getString("K0006")); //$NON-NLS-1$
 	}
 

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/Currency.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/Currency.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/Currency.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/Currency.java Thu Apr  6 03:42:13 2006
@@ -65,7 +65,7 @@
 			try {
 				defaultFractionDigits = bundle.getString(currencyCode);
 			} catch (MissingResourceException e) {
-				throw new IllegalArgumentException(com.ibm.oti.util.Msg
+				throw new IllegalArgumentException(org.apache.harmony.luni.util.Msg
 						.getString("K0322", currencyCode)); //$NON-NLS-1$
 			}
 			currency.defaultFractionDigits = Integer
@@ -98,7 +98,7 @@
 		try {
 			currencyCode = bundle.getString(country);
 		} catch (MissingResourceException e) {
-			throw new IllegalArgumentException(com.ibm.oti.util.Msg.getString(
+			throw new IllegalArgumentException(org.apache.harmony.luni.util.Msg.getString(
 					"K0323", locale.toString())); //$NON-NLS-1$
 		}
 

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/Locale.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/Locale.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/Locale.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/Locale.java Thu Apr  6 03:42:13 2006
@@ -31,7 +31,7 @@
 import org.apache.harmony.luni.internal.locale.Country;
 import org.apache.harmony.luni.internal.locale.Language;
 
-import com.ibm.oti.util.PriviAction;
+import org.apache.harmony.luni.util.PriviAction;
 
 /**
  * Locale represents a language/country/variant combination. It is an identifier

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/Properties.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/Properties.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/Properties.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/Properties.java Thu Apr  6 03:42:13 2006
@@ -24,7 +24,7 @@
 import java.io.PrintWriter;
 import java.security.AccessController;
 
-import com.ibm.oti.util.PriviAction;
+import org.apache.harmony.luni.util.PriviAction;
 
 /**
  * Properties is a Hashtable where the keys and values must be Strings. Each

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/ResourceBundle.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/ResourceBundle.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/ResourceBundle.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/ResourceBundle.java Thu Apr  6 03:42:13 2006
@@ -21,7 +21,7 @@
 import java.security.AccessController;
 import java.security.PrivilegedAction;
 
-import com.ibm.oti.vm.VM;
+import org.apache.harmony.kernel.vm.VM;
 
 /**
  * ResourceBundle is an abstract class which is the superclass of classes which

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/SimpleTimeZone.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/SimpleTimeZone.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/SimpleTimeZone.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/SimpleTimeZone.java Thu Apr  6 03:42:13 2006
@@ -158,7 +158,7 @@
 			int endDay, int endDayOfWeek, int endTime, int daylightSavings) {
 		this(offset, name);
 		if (daylightSavings <= 0)
-			throw new IllegalArgumentException(com.ibm.oti.util.Msg.getString(
+			throw new IllegalArgumentException(org.apache.harmony.luni.util.Msg.getString(
 					"K00e9", daylightSavings)); //$NON-NLS-1$
 		dstSavings = daylightSavings;
 
@@ -213,13 +213,13 @@
 				endMonth, endDay, endDayOfWeek, endTime, daylightSavings);
 
 		if (startTimeMode > 4 || startTimeMode < 1) {
-			throw new IllegalArgumentException(com.ibm.oti.util.Msg.getString(
+			throw new IllegalArgumentException(org.apache.harmony.luni.util.Msg.getString(
 					"K00e9", startTimeMode)); //$NON-NLS-1$
 		}
 		startMode = startTimeMode;
 
 		if (endTimeMode > 4 || endTimeMode < 1) {
-			throw new IllegalArgumentException(com.ibm.oti.util.Msg.getString(
+			throw new IllegalArgumentException(org.apache.harmony.luni.util.Msg.getString(
 					"K00e9", endTimeMode)); //$NON-NLS-1$
 		}
 		endMode = endTimeMode;
@@ -305,7 +305,7 @@
 	public int getOffset(int era, int year, int month, int day, int dayOfWeek,
 			int time) {
 		if (era != GregorianCalendar.BC && era != GregorianCalendar.AD)
-			throw new IllegalArgumentException(com.ibm.oti.util.Msg.getString(
+			throw new IllegalArgumentException(org.apache.harmony.luni.util.Msg.getString(
 					"K00ea", era)); //$NON-NLS-1$
 		checkRange(month, dayOfWeek, time);
 		if (month != Calendar.FEBRUARY || day != 29 || !isLeapYear(year))
@@ -532,19 +532,19 @@
 
 	private void checkRange(int month, int dayOfWeek, int time) {
 		if (month < Calendar.JANUARY || month > Calendar.DECEMBER)
-			throw new IllegalArgumentException(com.ibm.oti.util.Msg.getString(
+			throw new IllegalArgumentException(org.apache.harmony.luni.util.Msg.getString(
 					"K00e5", month)); //$NON-NLS-1$
 		if (dayOfWeek < Calendar.SUNDAY || dayOfWeek > Calendar.SATURDAY)
-			throw new IllegalArgumentException(com.ibm.oti.util.Msg.getString(
+			throw new IllegalArgumentException(org.apache.harmony.luni.util.Msg.getString(
 					"K00e7", dayOfWeek)); //$NON-NLS-1$
 		if (time < 0 || time >= 24 * 3600000)
-			throw new IllegalArgumentException(com.ibm.oti.util.Msg.getString(
+			throw new IllegalArgumentException(org.apache.harmony.luni.util.Msg.getString(
 					"K00e8", time)); //$NON-NLS-1$
 	}
 
 	private void checkDay(int month, int day) {
 		if (day <= 0 || day > GregorianCalendar.DaysInMonth[month])
-			throw new IllegalArgumentException(com.ibm.oti.util.Msg.getString(
+			throw new IllegalArgumentException(org.apache.harmony.luni.util.Msg.getString(
 					"K00e6", day)); //$NON-NLS-1$
 	}
 
@@ -568,7 +568,7 @@
 				checkDay(endMonth, endDay);
 			else {
 				if (endDay < -5 || endDay > 5)
-					throw new IllegalArgumentException(com.ibm.oti.util.Msg
+					throw new IllegalArgumentException(org.apache.harmony.luni.util.Msg
 							.getString("K00f8", endDay)); //$NON-NLS-1$
 			}
 		}
@@ -674,7 +674,7 @@
 				checkDay(startMonth, startDay);
 			else {
 				if (startDay < -5 || startDay > 5)
-					throw new IllegalArgumentException(com.ibm.oti.util.Msg
+					throw new IllegalArgumentException(org.apache.harmony.luni.util.Msg
 							.getString("K00f8", startDay)); //$NON-NLS-1$
 			}
 		}

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/TimeZone.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/TimeZone.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/TimeZone.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/TimeZone.java Thu Apr  6 03:42:13 2006
@@ -20,7 +20,7 @@
 import java.security.AccessController;
 import java.text.DateFormatSymbols;
 
-import com.ibm.oti.util.PriviAction;
+import org.apache.harmony.luni.util.PriviAction;
 
 /**
  * TimeZone is an abstract class which represents a local time zone and its

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/Timer.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/Timer.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/Timer.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/util/Timer.java Thu Apr  6 03:42:13 2006
@@ -16,7 +16,7 @@
 package java.util;
 
 
-import com.ibm.oti.util.Msg;
+import org.apache.harmony.luni.util.Msg;
 
 /**
  * Timers are used to schedule jobs for execution in a background process. A

Copied: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/file/FileURLConnection.java (from r389444, incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/file/FileURLConnection.java)
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/file/FileURLConnection.java?p2=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/file/FileURLConnection.java&p1=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/file/FileURLConnection.java&r1=389444&r2=391955&rev=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/file/FileURLConnection.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/file/FileURLConnection.java Thu Apr  6 03:42:13 2006
@@ -13,7 +13,7 @@
  * limitations under the License.
  */
 
-package com.ibm.oti.net.www.protocol.file;
+package org.apache.harmony.luni.internal.net.www.protocol.file;
 
 
 import java.io.BufferedInputStream;
@@ -62,7 +62,7 @@
 		String host = url.getHost();
 		if (host != null && host.length() > 0)
 			fileName = "//" + host + fileName;
-		fileName = com.ibm.oti.util.Util.decode(fileName, false);
+		fileName = org.apache.harmony.luni.util.Util.decode(fileName, false);
 	}
 
 	/**

Copied: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/file/Handler.java (from r389444, incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/file/Handler.java)
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/file/Handler.java?p2=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/file/Handler.java&p1=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/file/Handler.java&r1=389444&r2=391955&rev=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/file/Handler.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/file/Handler.java Thu Apr  6 03:42:13 2006
@@ -13,7 +13,7 @@
  * limitations under the License.
  */
 
-package com.ibm.oti.net.www.protocol.file;
+package org.apache.harmony.luni.internal.net.www.protocol.file;
 
 
 import java.net.URL;

Copied: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/ftp/FtpURLConnection.java (from r389444, incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/ftp/FtpURLConnection.java)
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/ftp/FtpURLConnection.java?p2=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/ftp/FtpURLConnection.java&p1=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/ftp/FtpURLConnection.java&r1=389444&r2=391955&rev=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/ftp/FtpURLConnection.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/ftp/FtpURLConnection.java Thu Apr  6 03:42:13 2006
@@ -13,7 +13,7 @@
  * limitations under the License.
  */
 
-package com.ibm.oti.net.www.protocol.ftp;
+package org.apache.harmony.luni.internal.net.www.protocol.ftp;
 
 
 import java.io.BufferedInputStream;
@@ -31,7 +31,7 @@
 
 import org.apache.harmony.luni.internal.net.www.MimeTable;
 
-import com.ibm.oti.util.Msg;
+import org.apache.harmony.luni.util.Msg;
 
 public class FtpURLConnection extends URLConnection {
 

Copied: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/ftp/FtpURLInputStream.java (from r389444, incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/ftp/FtpURLInputStream.java)
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/ftp/FtpURLInputStream.java?p2=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/ftp/FtpURLInputStream.java&p1=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/ftp/FtpURLInputStream.java&r1=389444&r2=391955&rev=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/ftp/FtpURLInputStream.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/ftp/FtpURLInputStream.java Thu Apr  6 03:42:13 2006
@@ -13,7 +13,7 @@
  * limitations under the License.
  */
 
-package com.ibm.oti.net.www.protocol.ftp;
+package org.apache.harmony.luni.internal.net.www.protocol.ftp;
 
 
 import java.io.IOException;

Copied: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/ftp/Handler.java (from r389444, incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/ftp/Handler.java)
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/ftp/Handler.java?p2=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/ftp/Handler.java&p1=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/ftp/Handler.java&r1=389444&r2=391955&rev=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/ftp/Handler.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/ftp/Handler.java Thu Apr  6 03:42:13 2006
@@ -13,7 +13,7 @@
  * limitations under the License.
  */
 
-package com.ibm.oti.net.www.protocol.ftp;
+package org.apache.harmony.luni.internal.net.www.protocol.ftp;
 
 import java.io.IOException;
 import java.net.URL;

Copied: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/Handler.java (from r389444, incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/http/Handler.java)
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/Handler.java?p2=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/Handler.java&p1=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/http/Handler.java&r1=389444&r2=391955&rev=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/http/Handler.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/Handler.java Thu Apr  6 03:42:13 2006
@@ -13,7 +13,7 @@
  * limitations under the License.
  */
 
-package com.ibm.oti.net.www.protocol.http;
+package org.apache.harmony.luni.internal.net.www.protocol.http;
 
 
 import java.net.URL;

Copied: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/Header.java (from r389444, incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/http/Header.java)
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/Header.java?p2=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/Header.java&p1=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/http/Header.java&r1=389444&r2=391955&rev=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/http/Header.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/Header.java Thu Apr  6 03:42:13 2006
@@ -13,7 +13,7 @@
  * limitations under the License.
  */
 
-package com.ibm.oti.net.www.protocol.http;
+package org.apache.harmony.luni.internal.net.www.protocol.http;
 
 
 import java.util.*;
@@ -185,7 +185,7 @@
 	this.statusLine = statusLine;
 	//we add the status line to the list of headers so that it is accessible
 	//from java.net.HttpURLConnection.getResponseCode()
-	//which calls com.ibm.oti.net.www.protocol.http.HttpURLConnection.getHeaderField(0) to get it
+	//which calls org.apache.harmony.luni.internal.net.www.protocol.http.HttpURLConnection.getHeaderField(0) to get it
 	props.add(0, null);
 	props.add(1, statusLine);
 }

Copied: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/HttpURLConnection.java (from r389444, incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/http/HttpURLConnection.java)
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/HttpURLConnection.java?p2=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/HttpURLConnection.java&p1=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/http/HttpURLConnection.java&r1=389444&r2=391955&rev=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/http/HttpURLConnection.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/http/HttpURLConnection.java Thu Apr  6 03:42:13 2006
@@ -13,7 +13,7 @@
  * limitations under the License.
  */
 
-package com.ibm.oti.net.www.protocol.http;
+package org.apache.harmony.luni.internal.net.www.protocol.http;
 
 
 import java.io.IOException;
@@ -23,7 +23,7 @@
 import java.net.*;
 import java.util.*;
 import java.security.AccessController;
-import com.ibm.oti.util.PriviAction;
+import org.apache.harmony.luni.util.PriviAction;
 import java.util.Locale;
 import java.util.TimeZone;
 import java.text.SimpleDateFormat;
@@ -186,7 +186,7 @@
 		}
 	}
 	public synchronized void flush() throws IOException {
-		if (closed) throw new IOException(com.ibm.oti.util.Msg.getString("K0059"));
+		if (closed) throw new IOException(org.apache.harmony.luni.util.Msg.getString("K0059"));
 		if (writeToSocket) {
 			sendCache(false);
 			socketOut.flush();
@@ -196,14 +196,14 @@
 		if (closed) return;
 		closed = true;
 		if (writeToSocket) {
-			if (limit > 0) throw new IOException(com.ibm.oti.util.Msg.getString("K00a4"));
+			if (limit > 0) throw new IOException(org.apache.harmony.luni.util.Msg.getString("K00a4"));
 			sendCache(closed);
 		}
 	}
 	public synchronized void write(int data) throws IOException {
-		if (closed) throw new IOException(com.ibm.oti.util.Msg.getString("K0059"));
+		if (closed) throw new IOException(org.apache.harmony.luni.util.Msg.getString("K0059"));
 		if (limit >= 0) {
-			if (limit == 0) throw new IOException(com.ibm.oti.util.Msg.getString("K00b2"));
+			if (limit == 0) throw new IOException(org.apache.harmony.luni.util.Msg.getString("K00b2"));
 			limit--;
 		}
 		cache.write(data);
@@ -211,14 +211,14 @@
 			sendCache(false);
 	}
 	public synchronized void write(byte[] buffer, int offset, int count) throws IOException {
-		if (closed) throw new IOException(com.ibm.oti.util.Msg.getString("K0059"));
+		if (closed) throw new IOException(org.apache.harmony.luni.util.Msg.getString("K0059"));
 		if (buffer==null) throw new NullPointerException();
 		// avoid int overflow
 		if (offset < 0 || count < 0 || offset > buffer.length || buffer.length - offset < count)
-			throw new ArrayIndexOutOfBoundsException(com.ibm.oti.util.Msg.getString("K002f"));
+			throw new ArrayIndexOutOfBoundsException(org.apache.harmony.luni.util.Msg.getString("K002f"));
 
 		if (limit >= 0) {
-			if (count > limit) throw new IOException(com.ibm.oti.util.Msg.getString("K00b2"));
+			if (count > limit) throw new IOException(org.apache.harmony.luni.util.Msg.getString("K00b2"));
 			limit -= count;
 		}
 		if (!writeToSocket || cache.size() + count < MAX) {
@@ -297,7 +297,7 @@
  */
 public void setReadTimeout(int value) {
 	if (value < 0)
-		throw new IllegalArgumentException(com.ibm.oti.util.Msg.getString("K0036"));
+		throw new IllegalArgumentException(org.apache.harmony.luni.util.Msg.getString("K0036"));
 	readTimeout = value;
 }
 
@@ -445,7 +445,7 @@
  */
 public InputStream getInputStream() throws IOException {
 	if (!doInput)
-		throw new ProtocolException(com.ibm.oti.util.Msg.getString("K008d"));
+		throw new ProtocolException(org.apache.harmony.luni.util.Msg.getString("K008d"));
 
 	doRequest();
 
@@ -490,11 +490,11 @@
  */
 public OutputStream getOutputStream() throws IOException {
 	if (!doOutput)
-		throw new ProtocolException(com.ibm.oti.util.Msg.getString("K008e"));
+		throw new ProtocolException(org.apache.harmony.luni.util.Msg.getString("K008e"));
 
 	// you can't write after you read
 	if (sentRequest)
-		throw new ProtocolException(com.ibm.oti.util.Msg.getString("K0090"));
+		throw new ProtocolException(org.apache.harmony.luni.util.Msg.getString("K0090"));
 
 	if (os != null) return os;
 
@@ -503,7 +503,7 @@
 		setRequestMethod("POST");
 	// If the request method is neither PUT or POST, then you're not writing
 	if (method != "PUT" && method != "POST")
-		throw new ProtocolException(com.ibm.oti.util.Msg.getString("K008f", method));
+		throw new ProtocolException(org.apache.harmony.luni.util.Msg.getString("K008f", method));
 
 	int limit = -1;
 	String contentLength = reqHeader.get("Content-Length");
@@ -548,7 +548,7 @@
  * @see 		#setRequestProperty
  */
 public String getRequestProperty(String field) {
-	if (connected) throw new IllegalAccessError(com.ibm.oti.util.Msg.getString("K0091"));
+	if (connected) throw new IllegalAccessError(org.apache.harmony.luni.util.Msg.getString("K0091"));
 	return reqHeader.get(field);
 }
 /**
@@ -792,7 +792,7 @@
  */
 public void setRequestProperty(String field, String newValue) {
 	if (connected) {
-		throw new IllegalAccessError(com.ibm.oti.util.Msg.getString("K0092"));
+		throw new IllegalAccessError(org.apache.harmony.luni.util.Msg.getString("K0092"));
 	}
 	if(field == null) {
 		throw new NullPointerException();
@@ -811,7 +811,7 @@
  */
 public void addRequestProperty(String field, String value) {
 	if (connected) {
-			throw new IllegalAccessError(com.ibm.oti.util.Msg.getString("K0092"));
+			throw new IllegalAccessError(org.apache.harmony.luni.util.Msg.getString("K0092"));
 	}
 	if(field == null) {
 		throw new NullPointerException();
@@ -954,7 +954,7 @@
 				responseCode == HTTP_USE_PROXY) && os == null) {
 
 				if (++redirect > 4)
-					throw new ProtocolException(com.ibm.oti.util.Msg.getString("K0093"));
+					throw new ProtocolException(org.apache.harmony.luni.util.Msg.getString("K0093"));
 				String location = getHeaderField("Location");
 			 	if (location != null) {
 					// start over
@@ -997,10 +997,10 @@
 		try {
 			hostPort = Integer.parseInt(port);
 		} catch (NumberFormatException e) {
-			throw new IllegalArgumentException(com.ibm.oti.util.Msg.getString("K00af", port));
+			throw new IllegalArgumentException(org.apache.harmony.luni.util.Msg.getString("K00af", port));
 		}
 		if (hostPort < 0 || hostPort > 65535)
-			throw new IllegalArgumentException(com.ibm.oti.util.Msg.getString("K00b0"));
+			throw new IllegalArgumentException(org.apache.harmony.luni.util.Msg.getString("K00b0"));
 	}
 }
 }

Copied: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/Handler.java (from r389444, incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/jar/Handler.java)
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/Handler.java?p2=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/Handler.java&p1=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/jar/Handler.java&r1=389444&r2=391955&rev=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/jar/Handler.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/Handler.java Thu Apr  6 03:42:13 2006
@@ -13,7 +13,7 @@
  * limitations under the License.
  */
 
-package com.ibm.oti.net.www.protocol.jar;
+package org.apache.harmony.luni.internal.net.www.protocol.jar;
 
 
 import java.io.IOException;
@@ -22,7 +22,7 @@
 import java.net.URLConnection;
 import java.net.URLStreamHandler;
 
-import com.ibm.oti.util.Msg;
+import org.apache.harmony.luni.util.Msg;
 
 public class Handler extends URLStreamHandler {
 	/**

Copied: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/JarURLConnection.java (from r389444, incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/jar/JarURLConnection.java)
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/JarURLConnection.java?p2=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/JarURLConnection.java&p1=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/jar/JarURLConnection.java&r1=389444&r2=391955&rev=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/net/www/protocol/jar/JarURLConnection.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/jar/JarURLConnection.java Thu Apr  6 03:42:13 2006
@@ -13,7 +13,7 @@
  * limitations under the License.
  */
 
-package com.ibm.oti.net.www.protocol.jar;
+package org.apache.harmony.luni.internal.net.www.protocol.jar;
 
 
 import java.io.File;
@@ -34,8 +34,8 @@
 import java.util.jar.JarFile;
 import java.util.zip.ZipFile;
 
-import com.ibm.oti.util.Msg;
-import com.ibm.oti.vm.VM;
+import org.apache.harmony.luni.util.Msg;
+import org.apache.harmony.kernel.vm.VM;
 
 /**
  * This subclass extends <code>URLConnection</code>.

Copied: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/process/ProcessInputStream.java (from r389444, incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/lang/ProcessInputStream.java)
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/process/ProcessInputStream.java?p2=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/process/ProcessInputStream.java&p1=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/lang/ProcessInputStream.java&r1=389444&r2=391955&rev=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/lang/ProcessInputStream.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/process/ProcessInputStream.java Thu Apr  6 03:42:13 2006
@@ -13,7 +13,7 @@
  * limitations under the License.
  */
 
-package com.ibm.oti.lang;
+package org.apache.harmony.luni.internal.process;
 
 
 class ProcessInputStream extends java.io.InputStream {

Copied: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/process/ProcessOutputStream.java (from r389444, incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/lang/ProcessOutputStream.java)
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/process/ProcessOutputStream.java?p2=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/process/ProcessOutputStream.java&p1=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/lang/ProcessOutputStream.java&r1=389444&r2=391955&rev=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/lang/ProcessOutputStream.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/process/ProcessOutputStream.java Thu Apr  6 03:42:13 2006
@@ -13,7 +13,7 @@
  * limitations under the License.
  */
 
-package com.ibm.oti.lang;
+package org.apache.harmony.luni.internal.process;
 
 
 class ProcessOutputStream extends java.io.OutputStream {

Copied: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/process/SystemProcess.java (from r389444, incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/lang/SystemProcess.java)
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/process/SystemProcess.java?p2=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/process/SystemProcess.java&p1=incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/lang/SystemProcess.java&r1=389444&r2=391955&rev=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/com/ibm/oti/lang/SystemProcess.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/process/SystemProcess.java Thu Apr  6 03:42:13 2006
@@ -13,7 +13,7 @@
  * limitations under the License.
  */
 
-package com.ibm.oti.lang;
+package org.apache.harmony.luni.internal.process;
 
 
 import java.io.File;
@@ -90,10 +90,10 @@
 		final byte[][] progBytes, envBytes;
 		progBytes = new byte[progArray.length][];
 		for (int i = 0; i < progArray.length; i++)
-			progBytes[i] = com.ibm.oti.util.Util.getBytes(progArray[i]);
+			progBytes[i] = org.apache.harmony.luni.util.Util.getBytes(progArray[i]);
 		envBytes = new byte[envp.length][];
 		for (int i = 0; i < envp.length; i++)
-			envBytes[i] = com.ibm.oti.util.Util.getBytes(envp[i]);
+			envBytes[i] = org.apache.harmony.luni.util.Util.getBytes(envp[i]);
 
 		final SystemProcess p = new SystemProcess();
 
@@ -104,7 +104,7 @@
 				long[] procVals = null;
 				try {
 					procVals = createImpl(p, progBytes, envBytes,
-							directory == null ? null : com.ibm.oti.util.Util
+							directory == null ? null : org.apache.harmony.luni.util.Util
 									.getBytes(directory.getPath()));
 				} catch (Throwable e) {
 					/* Creation errors need to be passed to the user thread. */

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/reflect/ProxyMethod.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/reflect/ProxyMethod.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/reflect/ProxyMethod.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/internal/reflect/ProxyMethod.java Thu Apr  6 03:42:13 2006
@@ -71,7 +71,7 @@
 				return false;
 
 		if (method.getReturnType() != otherMethod.getReturnType())
-			throw new IllegalArgumentException(com.ibm.oti.util.Msg.getString(
+			throw new IllegalArgumentException(org.apache.harmony.luni.util.Msg.getString(
 					"K00f2", method.getName()));
 		if (commonExceptions.length != 0) {
 			Class[] otherExceptions = otherMethod.getExceptionTypes();

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/NetUtil.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/NetUtil.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/NetUtil.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/NetUtil.java Thu Apr  6 03:42:13 2006
@@ -16,7 +16,7 @@
 
 import java.security.AccessController;
 
-import com.ibm.oti.util.PriviAction;
+import org.apache.harmony.luni.util.PriviAction;
 
 public class NetUtil {
     

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/PlainDatagramSocketImpl.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/PlainDatagramSocketImpl.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/PlainDatagramSocketImpl.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/PlainDatagramSocketImpl.java Thu Apr  6 03:42:13 2006
@@ -34,8 +34,8 @@
 import org.apache.harmony.luni.platform.INetworkSystem;
 import org.apache.harmony.luni.platform.Platform;
 
-import com.ibm.oti.util.Msg;
-import com.ibm.oti.util.PriviAction;
+import org.apache.harmony.luni.util.Msg;
+import org.apache.harmony.luni.util.PriviAction;
 
 /**
  * The default, concrete instance of datagram sockets. This class does not

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/PlainSocketImpl.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/PlainSocketImpl.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/PlainSocketImpl.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/PlainSocketImpl.java Thu Apr  6 03:42:13 2006
@@ -39,8 +39,8 @@
 import org.apache.harmony.luni.platform.INetworkSystem;
 import org.apache.harmony.luni.platform.Platform;
 
-import com.ibm.oti.util.Msg;
-import com.ibm.oti.util.PriviAction;
+import org.apache.harmony.luni.util.Msg;
+import org.apache.harmony.luni.util.PriviAction;
 
 /**
  * A concrete connected-socket implementation.

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/SocketInputStream.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/SocketInputStream.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/SocketInputStream.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/SocketInputStream.java Thu Apr  6 03:42:13 2006
@@ -21,7 +21,7 @@
 import java.net.SocketImpl;
 
 
-import com.ibm.oti.util.Msg;
+import org.apache.harmony.luni.util.Msg;
 
 /**
  * The SocketInputStream supports the streamed reading of bytes from a socket.

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/SocketOutputStream.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/SocketOutputStream.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/SocketOutputStream.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/SocketOutputStream.java Thu Apr  6 03:42:13 2006
@@ -88,11 +88,11 @@
 					&& count <= buffer.length - offset) {
 				socket.write(buffer, offset, count);
 			} else {
-				throw new ArrayIndexOutOfBoundsException(com.ibm.oti.util.Msg
+				throw new ArrayIndexOutOfBoundsException(org.apache.harmony.luni.util.Msg
 						.getString(ERRCODE_OFFSET_OUTOFBOUND));
 			}
 		} else {
-			throw new NullPointerException(com.ibm.oti.util.Msg
+			throw new NullPointerException(org.apache.harmony.luni.util.Msg
 					.getString(ERRCODE_BUFFER_NULL));
 		}
 	}

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/Socks4Message.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/Socks4Message.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/Socks4Message.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/net/Socks4Message.java Thu Apr  6 03:42:13 2006
@@ -159,13 +159,13 @@
 	public String getErrorString(int error) {
 		switch (error) {
 		case RETURN_FAILURE:
-			return com.ibm.oti.util.Msg.getString("K00cd");
+			return org.apache.harmony.luni.util.Msg.getString("K00cd");
 		case RETURN_CANNOT_CONNECT_TO_IDENTD:
-			return com.ibm.oti.util.Msg.getString("K00ce");
+			return org.apache.harmony.luni.util.Msg.getString("K00ce");
 		case RETURN_DIFFERENT_USER_IDS:
-			return com.ibm.oti.util.Msg.getString("K00cf");
+			return org.apache.harmony.luni.util.Msg.getString("K00cf");
 		default:
-			return com.ibm.oti.util.Msg.getString("K00d0");
+			return org.apache.harmony.luni.util.Msg.getString("K00d0");
 		}
 	}
 

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/platform/OSComponent.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/platform/OSComponent.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/platform/OSComponent.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/platform/OSComponent.java Thu Apr  6 03:42:13 2006
@@ -16,7 +16,7 @@
 package org.apache.harmony.luni.platform;
 
 
-import com.ibm.oti.vm.VM;
+import org.apache.harmony.kernel.vm.VM;
 
 /**
  * OSComponent
@@ -37,7 +37,7 @@
 	/*
 	 * (non-Javadoc)
 	 * 
-	 * @see com.ibm.core.IAdaptable#getAdapter(java.lang.Class)
+	 * @see org.apache.harmony.luni.platform.IAdaptable#getAdapter(java.lang.Class)
 	 */
 	public Object getAdapter(Class adapter) {
 		return Platform.getAdapterManager().getAdapter(this, adapter);

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/platform/Platform.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/platform/Platform.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/platform/Platform.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/platform/Platform.java Thu Apr  6 03:42:13 2006
@@ -16,7 +16,7 @@
 package org.apache.harmony.luni.platform;
 
 
-import com.ibm.oti.vm.VM;
+import org.apache.harmony.kernel.vm.VM;
 
 /**
  * Platform

Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/util/ASN1Decoder.java
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/util/ASN1Decoder.java?rev=391955&r1=391954&r2=391955&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/util/ASN1Decoder.java (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/org/apache/harmony/luni/util/ASN1Decoder.java Thu Apr  6 03:42:13 2006
@@ -28,9 +28,9 @@
 import java.util.TimeZone;
 import java.util.Vector;
 
-import com.ibm.oti.util.Msg;
-import com.ibm.oti.util.PositionedInputStream;
-import com.ibm.oti.util.PriviAction;
+import org.apache.harmony.luni.util.Msg;
+import org.apache.harmony.luni.util.PositionedInputStream;
+import org.apache.harmony.luni.util.PriviAction;
 
 /**
  * This class implements ASN.1 decoding, but just the smallest subset possible,



Mime
View raw message