harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tim Ellison <t.p.elli...@gmail.com>
Subject Internationalized messages (was: Re: svn commit: r395576 - /incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/RandomAccessFile.java)
Date Thu, 20 Apr 2006 13:33:55 GMT
Is there some reason why you are not using the message catalog for these
exception messages like we do for others?  These are intended to be read
by users so we want them to the NLS-enabled.

Take a look at Msg.java and ExternalMessages.properties in
org.apache.harmony.luni.util.

There are examples of their usage in the source file you modified.

Regards,
Tim

mloenko@apache.org wrote:
> Author: mloenko
> Date: Thu Apr 20 05:46:47 2006
> New Revision: 395576
> 
> URL: http://svn.apache.org/viewcvs?rev=395576&view=rev
> Log:
> fixes for HARMONY-374
> java.io.RandomAccessFile.seek(int pos) does not throw IOException if pos < 0
> 
> Modified:
>     incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/RandomAccessFile.java
> 
> Modified: incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/RandomAccessFile.java
> URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/RandomAccessFile.java?rev=395576&r1=395575&r2=395576&view=diff
> ==============================================================================
> --- incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/RandomAccessFile.java
(original)
> +++ incubator/harmony/enhanced/classlib/trunk/modules/luni/src/main/java/java/io/RandomAccessFile.java
Thu Apr 20 05:46:47 2006
> @@ -614,6 +614,9 @@
>  	 *             occurs.
>  	 */
>  	public void seek(long pos) throws IOException {
> +        if (pos < 0) {
> +            throw new IOException("seek position is negative");
> +        }
>          openCheck();
>          synchronized (repositionLock) {
>              fileSystem.seek(fd.descriptor, pos, IFileSystem.SEEK_SET);
> 
> 
> 

-- 

Tim Ellison (t.p.ellison@gmail.com)
IBM Java technology centre, UK.

---------------------------------------------------------------------
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: harmony-dev-unsubscribe@incubator.apache.org
For additional commands, e-mail: harmony-dev-help@incubator.apache.org


Mime
View raw message