01: // HTTPException.java
02: // $Id: HTTPException.java,v 1.4 2000/08/16 21:37:40 ylafon Exp $
03: // (c) COPYRIGHT MIT and INRIA, 1996.
04: // Please first read the full copyright statement in file COPYRIGHT.html
05:
06: package org.w3c.jigsaw.http;
07:
08: import org.w3c.tools.resources.ProtocolException;
09: import org.w3c.tools.resources.ReplyInterface;
10:
11: /**
12: * All entities should throw an HTTPException when encoutering some problems.
13: * This kind of exception is the one that gets normally caught by clients,
14: * and result in sending back HTTP error messages to the client.
15: */
16:
17: public class HTTPException extends ProtocolException {
18:
19: public HTTPException(String msg) {
20: super (msg);
21: }
22:
23: public HTTPException(String msg, Reply error) {
24: super (msg, error);
25: }
26:
27: public HTTPException(Reply error) {
28: super (error);
29: }
30:
31: public HTTPException(ProtocolException ex) {
32: super(ex.getMessage(), ex.getReply());
33: }
34: }
|