01: /*
02: * Copyright 1999-2004 The Apache Software Foundation
03: *
04: * Licensed under the Apache License, Version 2.0 (the "License");
05: * you may not use this file except in compliance with the License.
06: * You may obtain a copy of the License at
07: *
08: * http://www.apache.org/licenses/LICENSE-2.0
09: *
10: * Unless required by applicable law or agreed to in writing, software
11: * distributed under the License is distributed on an "AS IS" BASIS,
12: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13: * See the License for the specific language governing permissions and
14: * limitations under the License.
15: */
16:
17: package org.apache.coyote;
18:
19: /**
20: * Adapter.
21: *
22: * @author Remy Maucherat
23: */
24: public interface Adapter {
25:
26: /**
27: * Call the service method, and notify all listeners
28: *
29: * @exception Exception if an error happens during handling of
30: * the request. Common errors are:
31: * <ul><li>IOException if an input/output error occurs and we are
32: * processing an included servlet (otherwise it is swallowed and
33: * handled by the top level error handler mechanism)
34: * <li>ServletException if a servlet throws an exception and
35: * we are processing an included servlet (otherwise it is swallowed
36: * and handled by the top level error handler mechanism)
37: * </ul>
38: * Tomcat should be able to handle and log any other exception ( including
39: * runtime exceptions )
40: */
41: public void service(Request req, Response res) throws Exception;
42:
43: }
|