1 |
/* EOFException.java -- Unexpected end of file exception |
/* EOFException.java -- unexpected end of file exception |
2 |
Copyright (C) 1998, 1999, 2001 Free Software Foundation, Inc. |
Copyright (C) 1998, 1999, 2001, 2002 Free Software Foundation, Inc. |
3 |
|
|
4 |
This file is part of GNU Classpath. |
This file is part of GNU Classpath. |
5 |
|
|
7 |
it under the terms of the GNU General Public License as published by |
it under the terms of the GNU General Public License as published by |
8 |
the Free Software Foundation; either version 2, or (at your option) |
the Free Software Foundation; either version 2, or (at your option) |
9 |
any later version. |
any later version. |
10 |
|
|
11 |
GNU Classpath is distributed in the hope that it will be useful, but |
GNU Classpath is distributed in the hope that it will be useful, but |
12 |
WITHOUT ANY WARRANTY; without even the implied warranty of |
WITHOUT ANY WARRANTY; without even the implied warranty of |
13 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
38 |
|
|
39 |
package java.io; |
package java.io; |
40 |
|
|
|
/* Written using "Java Class Libraries", 2nd edition, ISBN 0-201-31002-3 |
|
|
* "The Java Language Specification", ISBN 0-201-63451-1 |
|
|
* Status: Complete to 1.1. |
|
|
*/ |
|
|
|
|
41 |
/** |
/** |
42 |
* This exception is thrown when the end of the file or stream was |
* This exception is thrown when the end of the file or stream was |
43 |
* encountered unexpectedly. This is not the normal way that a normal |
* encountered unexpectedly. This is not the normal way that an EOF |
44 |
* EOF condition is reported. Normally a special value such as -1 is |
* condition is reported; such as a special value like -1 being returned. |
45 |
* returned. However, certain types of streams expecting certain data |
* However, certain types of streams expecting certain data in a certain |
46 |
* in a certain format might reach EOF before reading their expected |
* format might reach EOF before reading their expected data pattern and |
47 |
* data pattern and thus throw this exception. |
* thus throw this exception. |
48 |
* |
* |
49 |
* @version 0.0 |
* @author Aaron M. Renn (arenn@urbanophile.com) |
50 |
* |
* @author Tom Tromey <tromey@cygnus.com> |
51 |
* @author Aaron M. Renn (arenn@urbanophile.com) |
* @status updated to 1.4 |
|
* @author Tom Tromey <tromey@cygnus.com> |
|
|
* @date September 24, 1998 |
|
|
*/ |
|
|
public class EOFException extends IOException |
|
|
{ |
|
|
|
|
|
/* |
|
|
* Constructors |
|
52 |
*/ |
*/ |
53 |
|
public class EOFException extends IOException |
|
/** |
|
|
* Create a new EOFException without a descriptive error message |
|
|
*/ |
|
|
public |
|
|
EOFException() |
|
|
{ |
|
|
super(); |
|
|
} |
|
|
|
|
|
/*************************************************************************/ |
|
|
|
|
|
/** |
|
|
* Create a new EOFException with a descriptive error message String |
|
|
* |
|
|
* @param message The descriptive error message |
|
|
*/ |
|
|
public |
|
|
EOFException(String message) |
|
54 |
{ |
{ |
55 |
super(message); |
/** |
56 |
} |
* Compatible with JDK 1.0+. |
57 |
|
*/ |
58 |
|
private static final long serialVersionUID = 6433858223774886977L; |
59 |
|
|
60 |
|
/** |
61 |
|
* Create an exception without a descriptive error message. |
62 |
|
*/ |
63 |
|
public EOFException() |
64 |
|
{ |
65 |
|
} |
66 |
|
|
67 |
|
/** |
68 |
|
* Create an exception with a descriptive error message. |
69 |
|
* |
70 |
|
* @param message the descriptive error message |
71 |
|
*/ |
72 |
|
public EOFException(String message) |
73 |
|
{ |
74 |
|
super(message); |
75 |
|
} |
76 |
} // class EOFException |
} // class EOFException |
|
|
|