01: /**
02: * $RCSfile$
03: * $Revision: 128 $
04: * $Date: 2004-10-25 20:42:00 -0300 (Mon, 25 Oct 2004) $
05: *
06: * Copyright (C) 2004 Jive Software. All rights reserved.
07: *
08: * This software is published under the terms of the GNU Public License (GPL),
09: * a copy of which is included in this distribution.
10: */package org.jivesoftware.openfire.muc;
11:
12: import java.io.PrintStream;
13: import java.io.PrintWriter;
14:
15: /**
16: * Exception used for representing a conflict error in a MUCRoom. There are many reasons why a
17: * conflict error could occur such as: owner tries to remove all the owners of a room. A 409 error
18: * code is returned to the user that requested the invalid operation.
19: *
20: * @author Gaston Dombiak
21: */
22: public class ConflictException extends Exception {
23:
24: private static final long serialVersionUID = 1L;
25:
26: private Throwable nestedThrowable = null;
27:
28: public ConflictException() {
29: super ();
30: }
31:
32: public ConflictException(String msg) {
33: super (msg);
34: }
35:
36: public ConflictException(Throwable nestedThrowable) {
37: this .nestedThrowable = nestedThrowable;
38: }
39:
40: public ConflictException(String msg, Throwable nestedThrowable) {
41: super (msg);
42: this .nestedThrowable = nestedThrowable;
43: }
44:
45: public void printStackTrace() {
46: super .printStackTrace();
47: if (nestedThrowable != null) {
48: nestedThrowable.printStackTrace();
49: }
50: }
51:
52: public void printStackTrace(PrintStream ps) {
53: super .printStackTrace(ps);
54: if (nestedThrowable != null) {
55: nestedThrowable.printStackTrace(ps);
56: }
57: }
58:
59: public void printStackTrace(PrintWriter pw) {
60: super.printStackTrace(pw);
61: if (nestedThrowable != null) {
62: nestedThrowable.printStackTrace(pw);
63: }
64: }
65: }
|