svn-gvsig-desktop / branches / v2_0_0_prep / libraries / libIverUtiles / src / org / gvsig / tools / backup / exceptions / BackupException.java @ 22755
History | View | Annotate | Download (2.07 KB)
1 |
package org.gvsig.tools.backup.exceptions; |
---|---|
2 |
|
3 |
/* gvSIG. Geographic Information System of the Valencian Government
|
4 |
*
|
5 |
* Copyright (C) 2007-2008 Infrastructures and Transports Department
|
6 |
* of the Valencian Government (CIT)
|
7 |
*
|
8 |
* This program is free software; you can redistribute it and/or
|
9 |
* modify it under the terms of the GNU General Public License
|
10 |
* as published by the Free Software Foundation; either version 2
|
11 |
* of the License, or (at your option) any later version.
|
12 |
*
|
13 |
* This program is distributed in the hope that it will be useful,
|
14 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
15 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
16 |
* GNU General Public License for more details.
|
17 |
*
|
18 |
* You should have received a copy of the GNU General Public License
|
19 |
* along with this program; if not, write to the Free Software
|
20 |
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
21 |
* MA 02110-1301, USA.
|
22 |
*
|
23 |
*/
|
24 |
|
25 |
import java.io.File; |
26 |
|
27 |
/**
|
28 |
* <p>Exception to report that a backup process has failed.</p>
|
29 |
*
|
30 |
* @author Pablo Piqueras Bartolom? (pablo.piqueras@iver.es)
|
31 |
*/
|
32 |
public class BackupException extends Exception { |
33 |
private static final long serialVersionUID = -2846421984617208883L; |
34 |
|
35 |
/**
|
36 |
* <p>The source file to be backup.</p>
|
37 |
*/
|
38 |
protected File source; |
39 |
|
40 |
/**
|
41 |
* <p>Constructs a new backup exception with the specified detail message and cause.</p>
|
42 |
*
|
43 |
* @param message the detail message (which is saved for later retrieval by the <code>getMessage()</code> method).
|
44 |
* @param cause the cause (which is saved for later retrieval by the <code>getCause()</code> method). (A <code>null</code>
|
45 |
* value is permitted, and indicates that the cause is nonexistent or unknown.)
|
46 |
* @param source the file from that was going to be done a backup
|
47 |
*
|
48 |
* @see Exception#Exception(String, Throwable)
|
49 |
*/
|
50 |
public BackupException(String message, Throwable cause, File source) { |
51 |
super(message, cause);
|
52 |
this.source = source;
|
53 |
} |
54 |
|
55 |
/**
|
56 |
* <p>Gets the source file to be backup.</p>
|
57 |
*
|
58 |
* @return the source file
|
59 |
*/
|
60 |
public File getSource() { |
61 |
return source;
|
62 |
} |
63 |
} |