KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jahia > exceptions > JahiaPersistenceException


1 /*
2  * ____.
3  * __/\ ______| |__/\. _______
4  * __ .____| | \ | +----+ \
5  * _______| /--| | | - \ _ | : - \_________
6  * \\______: :---| : : | : | \________>
7  * |__\---\_____________:______: :____|____:_____\
8  * /_____|
9  *
10  * . . . i n j a h i a w e t r u s t . . .
11  *
12  *
13  *
14  * ----- BEGIN LICENSE BLOCK -----
15  * Version: JCSL 1.0
16  *
17  * The contents of this file are subject to the Jahia Community Source License
18  * 1.0 or later (the "License"); you may not use this file except in
19  * compliance with the License. You may obtain a copy of the License at
20  * http://www.jahia.org/license
21  *
22  * Software distributed under the License is distributed on an "AS IS" basis,
23  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
24  * for the rights, obligations and limitations governing use of the contents
25  * of the file. The Original and Upgraded Code is the Jahia CMS and Portal
26  * Server. The developer of the Original and Upgraded Code is JAHIA Ltd. JAHIA
27  * Ltd. owns the copyrights in the portions it created. All Rights Reserved.
28  *
29  * The Shared Modifications are Jahia View Helper.
30  *
31  * The Developer of the Shared Modifications is Jahia Solution Sarl.
32  * Portions created by the Initial Developer are Copyright (C) 2002 by the
33  * Initial Developer. All Rights Reserved.
34  *
35  * Contributor(s):
36  * 15-SEP-2003, Jahia Solutions Sarl, Fulco Houkes : Initial version
37  *
38  * ----- END LICENSE BLOCK -----
39  */

40
41 package org.jahia.exceptions;
42
43
44 /**
45  *
46  * @author Fulco Houkes
47  * @version 1.0
48  * @since Jahia 4.0
49  */

50 public class JahiaPersistenceException extends JahiaException {
51
52     /** Instanciates a <code>JahiaPersistenceException</code> exception with
53      * the specified <code>message</code>. Uses by default the
54      * <code>JahiaException.CRITICAL_SEVERITY</code> level and the
55      * <code>JahiaException.PERSISTENCE_ERROR</code> error code.
56      *
57      * @param message the message associated to the exception
58      */

59     public JahiaPersistenceException (String JavaDoc message) {
60         super ("Persistence error", message, JahiaException.PERSISTENCE_ERROR,
61                 JahiaException.CRITICAL_SEVERITY, null);
62     }
63
64     /** Instanciates a <code>JahiaPersistenceException<code> exception with
65      * the specified detail <code>message</code> and the throwable <code>t</code>
66      * root cause. Uses by default the <code>JahiaException.CRITICAL_SEVERITY</code> level and
67      * the <code>JahiaException.PERSISTENCE_ERROR</code> error code.
68      *
69      * @param message the exception message
70      * @param t the root cause exception
71      */

72     public JahiaPersistenceException (String JavaDoc message, Throwable JavaDoc t) {
73         super ("Persistence error", message, JahiaException.PERSISTENCE_ERROR,
74                 JahiaException.CRITICAL_SEVERITY, t);
75     }
76
77     /** Instanciates a <code>JahiaPersistenceException<code> exception with
78      * the specified detail <code>message</code> and the throwable <code>t</code>
79      * root cause. Uses by default the <code>JahiaException.CRITICAL_SEVERITY</code> level.
80      *
81      * @param message the exception message
82      * @param errorCode the errore code
83      * @param t the root cause exception
84      */

85     public JahiaPersistenceException (String JavaDoc message, int errorCode, Throwable JavaDoc t) {
86         super ("Persistence error", message, errorCode, JahiaException.CRITICAL_SEVERITY, t);
87     }
88
89     /** Instanciates a <code>JahiaPersistenceException<code> exception with
90      * the specified detail <code>message</code> and the throwable <code>t</code>
91      * root cause. Uses by default the <code>JahiaException.CRITICAL_SEVERITY</code> level.
92      *
93      * @param message the exception message
94      * @param errorCode the errore code
95      */

96     public JahiaPersistenceException (String JavaDoc message, int errorCode) {
97         super ("Persistence error", message, errorCode, JahiaException.CRITICAL_SEVERITY, null);
98     }
99
100     /** Instanciates a <code>JahiaPersistenceException<code> exception with
101      * the specified detail <code>message</code> and the throwable <code>t</code>
102      * root cause.
103      *
104      * @param message the exception message
105      * @param errorCode the errore code
106      * @param severity the severity level
107      * @param t the root cause exception
108      */

109     public JahiaPersistenceException (String JavaDoc message, int errorCode,
110                                       int severity, Throwable JavaDoc t)
111     {
112         super ("Persistence error", message, errorCode, severity, t);
113     }
114
115     /** Instanciates a <code>JahiaPersistenceException<code> exception with
116      * the specified detail <code>message</code> and the throwable <code>t</code>
117      * root cause.
118      *
119      * @param message the exception message
120      * @param errorCode the errore code
121      * @param severity the severity level
122      */

123     public JahiaPersistenceException (String JavaDoc message, int errorCode, int severity)
124     {
125         super ("Persistence error", message, errorCode, severity, null);
126     }
127 }
Popular Tags