dnet45/modules/dnet-datasource-manager-common/trunk/src/main/java/eu/dnetlib/enabling/datasources/common/DsmException.java @ 57903
1 |
package eu.dnetlib.enabling.datasources.common; |
---|---|
2 |
|
3 |
public class DsmException extends Exception { |
4 |
|
5 |
/**
|
6 |
*
|
7 |
*/
|
8 |
private static final long serialVersionUID = 8980196353591772127L; |
9 |
|
10 |
private int code; |
11 |
|
12 |
public DsmException(int code, String msg) { |
13 |
super(msg); |
14 |
this.code = code; |
15 |
}
|
16 |
|
17 |
public DsmException(int code, Throwable e) { |
18 |
super(e); |
19 |
this.code = code; |
20 |
}
|
21 |
|
22 |
public DsmException(int code, String msg, Throwable e) { |
23 |
super(msg, e); |
24 |
this.code = code; |
25 |
}
|
26 |
|
27 |
public DsmException(String msg) { |
28 |
this(500, msg); |
29 |
}
|
30 |
|
31 |
public int getCode() { |
32 |
return code; |
33 |
}
|
34 |
|
35 |
public void setCode(final int code) { |
36 |
this.code = code; |
37 |
}
|
38 |
}
|