01: /* uDig - User Friendly Desktop Internet GIS client
02: * http://udig.refractions.net
03: * (C) 2004, Refractions Research Inc.
04: *
05: * This library is free software; you can redistribute it and/or
06: * modify it under the terms of the GNU Lesser General Public
07: * License as published by the Free Software Foundation;
08: * version 2.1 of the License.
09: *
10: * This library is distributed in the hope that it will be useful,
11: * but WITHOUT ANY WARRANTY; without even the implied warranty of
12: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13: * Lesser General Public License for more details.
14: */
15: package net.refractions.udig.catalog;
16:
17: import java.io.Serializable;
18: import java.net.URL;
19: import java.util.Map;
20:
21: /**
22: * Extends the {@link ServiceExtension} interface to provide debug information about why it couldn't process
23: * a URL or parameters.
24: *
25: * @author Jesse
26: * @since 1.1.0
27: */
28: public interface ServiceExtension2 extends ServiceExtension {
29: /**
30: * Returns a human consumable string explaining why the params cannot be used for creating a Service
31: *
32: * @param params params for trying to create a service
33: * @return a human consumable string explaining why the params cannot be used for creating a Service or null if a Service should be
34: * able to be created using the params
35: */
36: String reasonForFailure(Map<String, Serializable> params);
37:
38: /**
39: * Returns a human consumable string explaining why the url cannot be used for creating a Service
40: *
41: * @param url URL for trying to create a service
42: * @return a human consumable string explaining why the url cannot be used for creating a Service or null if a Service should be
43: * able to be created using the URL
44: */
45: String reasonForFailure(URL url);
46: }
|