1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.apache.myfaces.webapp.webxml;
17
18 /***
19 * @author Manfred Geiler (latest modification by $Author: matze $)
20 * @version $Revision: 167257 $ $Date: 2004-10-13 11:51:02 +0000 (Wed, 13 Oct 2004) $
21 */
22 public class ServletMapping
23 {
24 private String _servletName;
25 private Class _servletClass;
26 private String _urlPattern;
27 private boolean _isExtensionMapping = false;
28
29 public ServletMapping(String servletName,
30 Class servletClass,
31 String urlPattern)
32 {
33 _servletName = servletName;
34 _servletClass = servletClass;
35 _urlPattern = urlPattern;
36 if (_urlPattern != null)
37 {
38 if (_urlPattern.startsWith("*."))
39 {
40 _isExtensionMapping = true;
41 }
42 }
43 }
44
45 public boolean isExtensionMapping()
46 {
47 return _isExtensionMapping;
48 }
49
50 public String getServletName()
51 {
52 return _servletName;
53 }
54
55 public Class getServletClass()
56 {
57 return _servletClass;
58 }
59
60 public String getUrlPattern()
61 {
62 return _urlPattern;
63 }
64 }