View Javadoc

1   package geo.google;
2   
3   import geo.google.datamodel.GeoStatusCode;
4   /***
5    * Indicates something unexpected occurs.
6    * It also includes a {@link GeoStatusCode} to signal problems about the status of the geocoding request.
7    * @author jliang
8    *
9    */
10  public class GeoException extends Exception{
11    private static final long serialVersionUID = 1L;
12  
13    private GeoStatusCode _status = GeoStatusCode.G_GEO_UNKOWN_STATUS;
14  
15    public GeoStatusCode getStatus() {
16      return _status;
17    }
18    public GeoException(String message, GeoStatusCode status){
19      super(message);
20      _status = status;
21    }
22    
23    public GeoException(String message, Throwable cause, GeoStatusCode status){
24      super(message, cause);
25      _status = status;
26    }
27    
28    public GeoException(String message) {
29      super(message);
30    }
31    
32    public GeoException(String message, Throwable cause) {
33      super(message, cause);
34    }
35    
36    public GeoException(Throwable cause) {
37      super(cause);
38    }
39  }