gvsig-raster / org.gvsig.raster.wmts / trunk / org.gvsig.raster.wmts / org.gvsig.raster.wmts.ogc / org.gvsig.raster.wmts.ogc.api / src / main / java / org / gvsig / raster / wmts / ogc / exception / WMTSException.java @ 2485
History | View | Annotate | Download (2.21 KB)
1 |
/* gvSIG. Geographic Information System of the Valencian Government
|
---|---|
2 |
*
|
3 |
* Copyright (C) 2007-2008 Infrastructures and Transports Department
|
4 |
* of the Valencian Government (CIT)
|
5 |
*
|
6 |
* This program is free software; you can redistribute it and/or
|
7 |
* modify it under the terms of the GNU General Public License
|
8 |
* as published by the Free Software Foundation; either version 2
|
9 |
* of the License, or (at your option) any later version.
|
10 |
*
|
11 |
* This program is distributed in the hope that it will be useful,
|
12 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14 |
* GNU General Public License for more details.
|
15 |
*
|
16 |
* You should have received a copy of the GNU General Public License
|
17 |
* along with this program; if not, write to the Free Software
|
18 |
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
19 |
* MA 02110-1301, USA.
|
20 |
*
|
21 |
*/
|
22 |
package org.gvsig.raster.wmts.ogc.exception; |
23 |
|
24 |
|
25 |
/**
|
26 |
* @author Nacho Brodin (nachobrodin@gmail.com)
|
27 |
*/
|
28 |
public class WMTSException extends Exception { |
29 |
private static final long serialVersionUID = 1476084093500156070L; |
30 |
private String wmtsCode = null; |
31 |
protected String formatString = null; |
32 |
protected String messageKey = null; |
33 |
protected long code = 0; |
34 |
|
35 |
public WMTSException() {
|
36 |
init(); |
37 |
} |
38 |
|
39 |
public WMTSException(Throwable cause) { |
40 |
super(cause);
|
41 |
init(); |
42 |
initCause(cause); |
43 |
} |
44 |
|
45 |
public WMTSException(String msg, Throwable cause) { |
46 |
super(msg, cause);
|
47 |
init(); |
48 |
this.formatString = msg;
|
49 |
} |
50 |
|
51 |
public WMTSException(String wfsCode,String message) { |
52 |
init(); |
53 |
formatString = message; |
54 |
this.wmtsCode = wfsCode;
|
55 |
} |
56 |
|
57 |
public WMTSException(String message) { |
58 |
init(); |
59 |
formatString = message; |
60 |
} |
61 |
|
62 |
public void init() { |
63 |
messageKey = "wmts_exception";
|
64 |
formatString = "WMTS Exception";
|
65 |
code = serialVersionUID; |
66 |
} |
67 |
|
68 |
/**
|
69 |
* @return Returns the wfsCode.
|
70 |
*/
|
71 |
public String getWfsCode() { |
72 |
return wmtsCode;
|
73 |
} |
74 |
|
75 |
public void setWMTSMessage(String message) { |
76 |
this.formatString = message;
|
77 |
} |
78 |
} |