Source Code Cross Referenced for Context.java in  » Web-Server » Rimfaxe-Web-Server » org » apache » catalina » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Web Server » Rimfaxe Web Server » org.apache.catalina 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         * $Header: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/Context.java,v 1.21 2002/05/12 01:22:18 glenn Exp $
003:         * $Revision: 1.21 $
004:         * $Date: 2002/05/12 01:22:18 $
005:         *
006:         * ====================================================================
007:         *
008:         * The Apache Software License, Version 1.1
009:         *
010:         * Copyright (c) 1999 The Apache Software Foundation.  All rights
011:         * reserved.
012:         *
013:         * Redistribution and use in source and binary forms, with or without
014:         * modification, are permitted provided that the following conditions
015:         * are met:
016:         *
017:         * 1. Redistributions of source code must retain the above copyright
018:         *    notice, this list of conditions and the following disclaimer.
019:         *
020:         * 2. Redistributions in binary form must reproduce the above copyright
021:         *    notice, this list of conditions and the following disclaimer in
022:         *    the documentation and/or other materials provided with the
023:         *    distribution.
024:         *
025:         * 3. The end-user documentation included with the redistribution, if
026:         *    any, must include the following acknowlegement:
027:         *       "This product includes software developed by the
028:         *        Apache Software Foundation (http://www.apache.org/)."
029:         *    Alternately, this acknowlegement may appear in the software itself,
030:         *    if and wherever such third-party acknowlegements normally appear.
031:         *
032:         * 4. The names "The Jakarta Project", "Tomcat", and "Apache Software
033:         *    Foundation" must not be used to endorse or promote products derived
034:         *    from this software without prior written permission. For written
035:         *    permission, please contact apache@apache.org.
036:         *
037:         * 5. Products derived from this software may not be called "Apache"
038:         *    nor may "Apache" appear in their names without prior written
039:         *    permission of the Apache Group.
040:         *
041:         * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
042:         * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
043:         * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
044:         * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
045:         * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
046:         * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
047:         * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
048:         * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
049:         * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
050:         * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
051:         * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
052:         * SUCH DAMAGE.
053:         * ====================================================================
054:         *
055:         * This software consists of voluntary contributions made by many
056:         * individuals on behalf of the Apache Software Foundation.  For more
057:         * information on the Apache Software Foundation, please see
058:         * <http://www.apache.org/>.
059:         *
060:         * [Additional notices, if required by prior licensing conditions]
061:         *
062:         */
063:
064:        package org.apache.catalina;
065:
066:        import javax.servlet.ServletContext;
067:        import org.apache.catalina.deploy.ApplicationParameter;
068:        import org.apache.catalina.deploy.ContextEjb;
069:        import org.apache.catalina.deploy.ContextEnvironment;
070:        import org.apache.catalina.deploy.ContextLocalEjb;
071:        import org.apache.catalina.deploy.ContextResource;
072:        import org.apache.catalina.deploy.ContextResourceLink;
073:        import org.apache.catalina.deploy.ErrorPage;
074:        import org.apache.catalina.deploy.FilterDef;
075:        import org.apache.catalina.deploy.FilterMap;
076:        import org.apache.catalina.deploy.LoginConfig;
077:        import org.apache.catalina.deploy.NamingResources;
078:        import org.apache.catalina.deploy.SecurityConstraint;
079:        import org.apache.catalina.util.CharsetMapper;
080:
081:        /**
082:         * A <b>Context</b> is a Container that represents a servlet context, and
083:         * therefore an individual web application, in the Catalina servlet engine.
084:         * It is therefore useful in almost every deployment of Catalina (even if a
085:         * Connector attached to a web server (such as Apache) uses the web server's
086:         * facilities to identify the appropriate Wrapper to handle this request.
087:         * It also provides a convenient mechanism to use Interceptors that see
088:         * every request processed by this particular web application.
089:         * <p>
090:         * The parent Container attached to a Context is generally a Host, but may
091:         * be some other implementation, or may be omitted if it is not necessary.
092:         * <p>
093:         * The child containers attached to a Context are generally implementations
094:         * of Wrapper (representing individual servlet definitions).
095:         * <p>
096:         *
097:         * @author Craig R. McClanahan
098:         * @version $Revision: 1.21 $ $Date: 2002/05/12 01:22:18 $
099:         */
100:
101:        public interface Context extends Container {
102:
103:            // ----------------------------------------------------- Manifest Constants
104:
105:            /**
106:             * The LifecycleEvent type sent when a context is reloaded.
107:             */
108:            public static final String RELOAD_EVENT = "reload";
109:
110:            // ------------------------------------------------------------- Properties
111:
112:            /**
113:             * Return the set of initialized application listener objects,
114:             * in the order they were specified in the web application deployment
115:             * descriptor, for this application.
116:             *
117:             * @exception IllegalStateException if this method is called before
118:             *  this application has started, or after it has been stopped
119:             */
120:            public Object[] getApplicationListeners();
121:
122:            /**
123:             * Store the set of initialized application listener objects,
124:             * in the order they were specified in the web application deployment
125:             * descriptor, for this application.
126:             *
127:             * @param listeners The set of instantiated listener objects.
128:             */
129:            public void setApplicationListeners(Object listeners[]);
130:
131:            /**
132:             * Return the application available flag for this Context.
133:             */
134:            public boolean getAvailable();
135:
136:            /**
137:             * Set the application available flag for this Context.
138:             *
139:             * @param available The new application available flag
140:             */
141:            public void setAvailable(boolean available);
142:
143:            /**
144:             * Return the Locale to character set mapper for this Context.
145:             */
146:            public CharsetMapper getCharsetMapper();
147:
148:            /**
149:             * Set the Locale to character set mapper for this Context.
150:             *
151:             * @param mapper The new mapper
152:             */
153:            public void setCharsetMapper(CharsetMapper mapper);
154:
155:            /**
156:             * Return the "correctly configured" flag for this Context.
157:             */
158:            public boolean getConfigured();
159:
160:            /**
161:             * Set the "correctly configured" flag for this Context.  This can be
162:             * set to false by startup listeners that detect a fatal configuration
163:             * error to avoid the application from being made available.
164:             *
165:             * @param configured The new correctly configured flag
166:             */
167:            public void setConfigured(boolean configured);
168:
169:            /**
170:             * Return the "use cookies for session ids" flag.
171:             */
172:            public boolean getCookies();
173:
174:            /**
175:             * Set the "use cookies for session ids" flag.
176:             *
177:             * @param cookies The new flag
178:             */
179:            public void setCookies(boolean cookies);
180:
181:            /**
182:             * Return the "allow crossing servlet contexts" flag.
183:             */
184:            public boolean getCrossContext();
185:
186:            /**
187:             * Set the "allow crossing servlet contexts" flag.
188:             *
189:             * @param crossContext The new cross contexts flag
190:             */
191:            public void setCrossContext(boolean crossContext);
192:
193:            /**
194:             * Return the display name of this web application.
195:             */
196:            public String getDisplayName();
197:
198:            /**
199:             * Set the display name of this web application.
200:             *
201:             * @param displayName The new display name
202:             */
203:            public void setDisplayName(String displayName);
204:
205:            /**
206:             * Return the distributable flag for this web application.
207:             */
208:            public boolean getDistributable();
209:
210:            /**
211:             * Set the distributable flag for this web application.
212:             *
213:             * @param distributable The new distributable flag
214:             */
215:            public void setDistributable(boolean distributable);
216:
217:            /**
218:             * Return the document root for this Context.  This can be an absolute
219:             * pathname, a relative pathname, or a URL.
220:             */
221:            public String getDocBase();
222:
223:            /**
224:             * Set the document root for this Context.  This can be an absolute
225:             * pathname, a relative pathname, or a URL.
226:             *
227:             * @param docBase The new document root
228:             */
229:            public void setDocBase(String docBase);
230:
231:            /**
232:             * Return the login configuration descriptor for this web application.
233:             */
234:            public LoginConfig getLoginConfig();
235:
236:            /**
237:             * Set the login configuration descriptor for this web application.
238:             *
239:             * @param config The new login configuration
240:             */
241:            public void setLoginConfig(LoginConfig config);
242:
243:            /**
244:             * Return the naming resources associated with this web application.
245:             */
246:            public NamingResources getNamingResources();
247:
248:            /**
249:             * Set the naming resources for this web application.
250:             * 
251:             * @param namingResources The new naming resources
252:             */
253:            public void setNamingResources(NamingResources namingResources);
254:
255:            /**
256:             * Return the context path for this web application.
257:             */
258:            public String getPath();
259:
260:            /**
261:             * Set the context path for this web application.
262:             *
263:             * @param path The new context path
264:             */
265:            public void setPath(String path);
266:
267:            /**
268:             * Return the public identifier of the deployment descriptor DTD that is
269:             * currently being parsed.
270:             */
271:            public String getPublicId();
272:
273:            /**
274:             * Set the public identifier of the deployment descriptor DTD that is
275:             * currently being parsed.
276:             *
277:             * @param publicId The public identifier
278:             */
279:            public void setPublicId(String publicId);
280:
281:            /**
282:             * Return the reloadable flag for this web application.
283:             */
284:            public boolean getReloadable();
285:
286:            /**
287:             * Set the reloadable flag for this web application.
288:             *
289:             * @param reloadable The new reloadable flag
290:             */
291:            public void setReloadable(boolean reloadable);
292:
293:            /**
294:             * Return the override flag for this web application.
295:             */
296:            public boolean getOverride();
297:
298:            /**
299:             * Set the override flag for this web application.
300:             *
301:             * @param override The new override flag
302:             */
303:            public void setOverride(boolean override);
304:
305:            /**
306:             * Return the privileged flag for this web application.
307:             */
308:            public boolean getPrivileged();
309:
310:            /**
311:             * Set the privileged flag for this web application.
312:             * 
313:             * @param privileged The new privileged flag
314:             */
315:            public void setPrivileged(boolean privileged);
316:
317:            /**
318:             * Return the servlet context for which this Context is a facade.
319:             */
320:            public ServletContext getServletContext();
321:
322:            /**
323:             * Return the default session timeout (in minutes) for this
324:             * web application.
325:             */
326:            public int getSessionTimeout();
327:
328:            /**
329:             * Set the default session timeout (in minutes) for this
330:             * web application.
331:             *
332:             * @param timeout The new default session timeout
333:             */
334:            public void setSessionTimeout(int timeout);
335:
336:            /**
337:             * Return the Java class name of the Wrapper implementation used
338:             * for servlets registered in this Context.
339:             */
340:            public String getWrapperClass();
341:
342:            /**
343:             * Set the Java class name of the Wrapper implementation used
344:             * for servlets registered in this Context.
345:             *
346:             * @param wrapperClass The new wrapper class
347:             */
348:            public void setWrapperClass(String wrapperClass);
349:
350:            // --------------------------------------------------------- Public Methods
351:
352:            /**
353:             * Add a new Listener class name to the set of Listeners
354:             * configured for this application.
355:             *
356:             * @param listener Java class name of a listener class
357:             */
358:            public void addApplicationListener(String listener);
359:
360:            /**
361:             * Add a new application parameter for this application.
362:             *
363:             * @param parameter The new application parameter
364:             */
365:            public void addApplicationParameter(ApplicationParameter parameter);
366:
367:            /**
368:             * Add a security constraint to the set for this web application.
369:             */
370:            public void addConstraint(SecurityConstraint constraint);
371:
372:            /**
373:             * Add an EJB resource reference for this web application.
374:             *
375:             * @param ejb New EJB resource reference
376:             */
377:            public void addEjb(ContextEjb ejb);
378:
379:            /**
380:             * Add an environment entry for this web application.
381:             *
382:             * @param environment New environment entry
383:             */
384:            public void addEnvironment(ContextEnvironment environment);
385:
386:            /**
387:             * Add an error page for the specified error or Java exception.
388:             *
389:             * @param errorPage The error page definition to be added
390:             */
391:            public void addErrorPage(ErrorPage errorPage);
392:
393:            /**
394:             * Add a filter definition to this Context.
395:             *
396:             * @param filterDef The filter definition to be added
397:             */
398:            public void addFilterDef(FilterDef filterDef);
399:
400:            /**
401:             * Add a filter mapping to this Context.
402:             *
403:             * @param filterMap The filter mapping to be added
404:             */
405:            public void addFilterMap(FilterMap filterMap);
406:
407:            /**
408:             * Add the classname of an InstanceListener to be added to each
409:             * Wrapper appended to this Context.
410:             *
411:             * @param listener Java class name of an InstanceListener class
412:             */
413:            public void addInstanceListener(String listener);
414:
415:            /**
416:             * Add a local EJB resource reference for this web application.
417:             *
418:             * @param ejb New local EJB resource reference
419:             */
420:            public void addLocalEjb(ContextLocalEjb ejb);
421:
422:            /**
423:             * Add a new MIME mapping, replacing any existing mapping for
424:             * the specified extension.
425:             *
426:             * @param extension Filename extension being mapped
427:             * @param mimeType Corresponding MIME type
428:             */
429:            public void addMimeMapping(String extension, String mimeType);
430:
431:            /**
432:             * Add a new context initialization parameter, replacing any existing
433:             * value for the specified name.
434:             *
435:             * @param name Name of the new parameter
436:             * @param value Value of the new  parameter
437:             */
438:            public void addParameter(String name, String value);
439:
440:            /**
441:             * Add a resource reference for this web application.
442:             *
443:             * @param resource New resource reference
444:             */
445:            public void addResource(ContextResource resource);
446:
447:            /**
448:             * Add a resource environment reference for this web application.
449:             *
450:             * @param name The resource environment reference name
451:             * @param type The resource environment reference type
452:             */
453:            public void addResourceEnvRef(String name, String type);
454:
455:            /**
456:             * Add a resource link for this web application.
457:             *
458:             * @param resource New resource link
459:             */
460:            public void addResourceLink(ContextResourceLink resourceLink);
461:
462:            /**
463:             * Add a security role reference for this web application.
464:             *
465:             * @param role Security role used in the application
466:             * @param link Actual security role to check for
467:             */
468:            public void addRoleMapping(String role, String link);
469:
470:            /**
471:             * Add a new security role for this web application.
472:             *
473:             * @param role New security role
474:             */
475:            public void addSecurityRole(String role);
476:
477:            /**
478:             * Add a new servlet mapping, replacing any existing mapping for
479:             * the specified pattern.
480:             *
481:             * @param pattern URL pattern to be mapped
482:             * @param name Name of the corresponding servlet to execute
483:             */
484:            public void addServletMapping(String pattern, String name);
485:
486:            /**
487:             * Add a JSP tag library for the specified URI.
488:             *
489:             * @param uri URI, relative to the web.xml file, of this tag library
490:             * @param location Location of the tag library descriptor
491:             */
492:            public void addTaglib(String uri, String location);
493:
494:            /**
495:             * Add a new welcome file to the set recognized by this Context.
496:             *
497:             * @param name New welcome file name
498:             */
499:            public void addWelcomeFile(String name);
500:
501:            /**
502:             * Add the classname of a LifecycleListener to be added to each
503:             * Wrapper appended to this Context.
504:             *
505:             * @param listener Java class name of a LifecycleListener class
506:             */
507:            public void addWrapperLifecycle(String listener);
508:
509:            /**
510:             * Add the classname of a ContainerListener to be added to each
511:             * Wrapper appended to this Context.
512:             *
513:             * @param listener Java class name of a ContainerListener class
514:             */
515:            public void addWrapperListener(String listener);
516:
517:            /**
518:             * Factory method to create and return a new Wrapper instance, of
519:             * the Java implementation class appropriate for this Context
520:             * implementation.  The constructor of the instantiated Wrapper
521:             * will have been called, but no properties will have been set.
522:             */
523:            public Wrapper createWrapper();
524:
525:            /**
526:             * Return the set of application listener class names configured
527:             * for this application.
528:             */
529:            public String[] findApplicationListeners();
530:
531:            /**
532:             * Return the set of application parameters for this application.
533:             */
534:            public ApplicationParameter[] findApplicationParameters();
535:
536:            /**
537:             * Return the set of security constraints for this web application.
538:             * If there are none, a zero-length array is returned.
539:             */
540:            public SecurityConstraint[] findConstraints();
541:
542:            /**
543:             * Return the EJB resource reference with the specified name, if any;
544:             * otherwise, return <code>null</code>.
545:             *
546:             * @param name Name of the desired EJB resource reference
547:             */
548:            public ContextEjb findEjb(String name);
549:
550:            /**
551:             * Return the defined EJB resource references for this application.
552:             * If there are none, a zero-length array is returned.
553:             */
554:            public ContextEjb[] findEjbs();
555:
556:            /**
557:             * Return the environment entry with the specified name, if any;
558:             * otherwise, return <code>null</code>.
559:             *
560:             * @param name Name of the desired environment entry
561:             */
562:            public ContextEnvironment findEnvironment(String name);
563:
564:            /**
565:             * Return the set of defined environment entries for this web
566:             * application.  If none have been defined, a zero-length array
567:             * is returned.
568:             */
569:            public ContextEnvironment[] findEnvironments();
570:
571:            /**
572:             * Return the error page entry for the specified HTTP error code,
573:             * if any; otherwise return <code>null</code>.
574:             *
575:             * @param errorCode Error code to look up
576:             */
577:            public ErrorPage findErrorPage(int errorCode);
578:
579:            /**
580:             * Return the error page entry for the specified Java exception type,
581:             * if any; otherwise return <code>null</code>.
582:             *
583:             * @param exceptionType Exception type to look up
584:             */
585:            public ErrorPage findErrorPage(String exceptionType);
586:
587:            /**
588:             * Return the set of defined error pages for all specified error codes
589:             * and exception types.
590:             */
591:            public ErrorPage[] findErrorPages();
592:
593:            /**
594:             * Return the filter definition for the specified filter name, if any;
595:             * otherwise return <code>null</code>.
596:             *
597:             * @param filterName Filter name to look up
598:             */
599:            public FilterDef findFilterDef(String filterName);
600:
601:            /**
602:             * Return the set of defined filters for this Context.
603:             */
604:            public FilterDef[] findFilterDefs();
605:
606:            /**
607:             * Return the set of filter mappings for this Context.
608:             */
609:            public FilterMap[] findFilterMaps();
610:
611:            /**
612:             * Return the set of InstanceListener classes that will be added to
613:             * newly created Wrappers automatically.
614:             */
615:            public String[] findInstanceListeners();
616:
617:            /**
618:             * Return the local EJB resource reference with the specified name, if any;
619:             * otherwise, return <code>null</code>.
620:             *
621:             * @param name Name of the desired EJB resource reference
622:             */
623:            public ContextLocalEjb findLocalEjb(String name);
624:
625:            /**
626:             * Return the defined local EJB resource references for this application.
627:             * If there are none, a zero-length array is returned.
628:             */
629:            public ContextLocalEjb[] findLocalEjbs();
630:
631:            /**
632:             * Return the MIME type to which the specified extension is mapped,
633:             * if any; otherwise return <code>null</code>.
634:             *
635:             * @param extension Extension to map to a MIME type
636:             */
637:            public String findMimeMapping(String extension);
638:
639:            /**
640:             * Return the extensions for which MIME mappings are defined.  If there
641:             * are none, a zero-length array is returned.
642:             */
643:            public String[] findMimeMappings();
644:
645:            /**
646:             * Return the value for the specified context initialization
647:             * parameter name, if any; otherwise return <code>null</code>.
648:             *
649:             * @param name Name of the parameter to return
650:             */
651:            public String findParameter(String name);
652:
653:            /**
654:             * Return the names of all defined context initialization parameters
655:             * for this Context.  If no parameters are defined, a zero-length
656:             * array is returned.
657:             */
658:            public String[] findParameters();
659:
660:            /**
661:             * Return the resource reference with the specified name, if any;
662:             * otherwise return <code>null</code>.
663:             *
664:             * @param name Name of the desired resource reference
665:             */
666:            public ContextResource findResource(String name);
667:
668:            /**
669:             * Return the resource environment reference type for the specified
670:             * name, if any; otherwise return <code>null</code>.
671:             *
672:             * @param name Name of the desired resource environment reference
673:             */
674:            public String findResourceEnvRef(String name);
675:
676:            /**
677:             * Return the set of resource environment reference names for this
678:             * web application.  If none have been specified, a zero-length
679:             * array is returned.
680:             */
681:            public String[] findResourceEnvRefs();
682:
683:            /**
684:             * Return the resource link with the specified name, if any;
685:             * otherwise return <code>null</code>.
686:             *
687:             * @param name Name of the desired resource link
688:             */
689:            public ContextResourceLink findResourceLink(String name);
690:
691:            /**
692:             * Return the defined resource links for this application.  If
693:             * none have been defined, a zero-length array is returned.
694:             */
695:            public ContextResourceLink[] findResourceLinks();
696:
697:            /**
698:             * Return the defined resource references for this application.  If
699:             * none have been defined, a zero-length array is returned.
700:             */
701:            public ContextResource[] findResources();
702:
703:            /**
704:             * For the given security role (as used by an application), return the
705:             * corresponding role name (as defined by the underlying Realm) if there
706:             * is one.  Otherwise, return the specified role unchanged.
707:             *
708:             * @param role Security role to map
709:             */
710:            public String findRoleMapping(String role);
711:
712:            /**
713:             * Return <code>true</code> if the specified security role is defined
714:             * for this application; otherwise return <code>false</code>.
715:             *
716:             * @param role Security role to verify
717:             */
718:            public boolean findSecurityRole(String role);
719:
720:            /**
721:             * Return the security roles defined for this application.  If none
722:             * have been defined, a zero-length array is returned.
723:             */
724:            public String[] findSecurityRoles();
725:
726:            /**
727:             * Return the servlet name mapped by the specified pattern (if any);
728:             * otherwise return <code>null</code>.
729:             *
730:             * @param pattern Pattern for which a mapping is requested
731:             */
732:            public String findServletMapping(String pattern);
733:
734:            /**
735:             * Return the patterns of all defined servlet mappings for this
736:             * Context.  If no mappings are defined, a zero-length array is returned.
737:             */
738:            public String[] findServletMappings();
739:
740:            /**
741:             * Return the context-relative URI of the error page for the specified
742:             * HTTP status code, if any; otherwise return <code>null</code>.
743:             *
744:             * @param status HTTP status code to look up
745:             */
746:            public String findStatusPage(int status);
747:
748:            /**
749:             * Return the set of HTTP status codes for which error pages have
750:             * been specified.  If none are specified, a zero-length array
751:             * is returned.
752:             */
753:            public int[] findStatusPages();
754:
755:            /**
756:             * Return the tag library descriptor location for the specified taglib
757:             * URI, if any; otherwise, return <code>null</code>.
758:             *
759:             * @param uri URI, relative to the web.xml file
760:             */
761:            public String findTaglib(String uri);
762:
763:            /**
764:             * Return the URIs of all tag libraries for which a tag library
765:             * descriptor location has been specified.  If none are specified,
766:             * a zero-length array is returned.
767:             */
768:            public String[] findTaglibs();
769:
770:            /**
771:             * Return <code>true</code> if the specified welcome file is defined
772:             * for this Context; otherwise return <code>false</code>.
773:             *
774:             * @param name Welcome file to verify
775:             */
776:            public boolean findWelcomeFile(String name);
777:
778:            /**
779:             * Return the set of welcome files defined for this Context.  If none are
780:             * defined, a zero-length array is returned.
781:             */
782:            public String[] findWelcomeFiles();
783:
784:            /**
785:             * Return the set of LifecycleListener classes that will be added to
786:             * newly created Wrappers automatically.
787:             */
788:            public String[] findWrapperLifecycles();
789:
790:            /**
791:             * Return the set of ContainerListener classes that will be added to
792:             * newly created Wrappers automatically.
793:             */
794:            public String[] findWrapperListeners();
795:
796:            /**
797:             * Reload this web application, if reloading is supported.
798:             *
799:             * @exception IllegalStateException if the <code>reloadable</code>
800:             *  property is set to <code>false</code>.
801:             */
802:            public void reload();
803:
804:            /**
805:             * Remove the specified application listener class from the set of
806:             * listeners for this application.
807:             *
808:             * @param listener Java class name of the listener to be removed
809:             */
810:            public void removeApplicationListener(String listener);
811:
812:            /**
813:             * Remove the application parameter with the specified name from
814:             * the set for this application.
815:             *
816:             * @param name Name of the application parameter to remove
817:             */
818:            public void removeApplicationParameter(String name);
819:
820:            /**
821:             * Remove the specified security constraint from this web application.
822:             *
823:             * @param constraint Constraint to be removed
824:             */
825:            public void removeConstraint(SecurityConstraint constraint);
826:
827:            /**
828:             * Remove any EJB resource reference with the specified name.
829:             *
830:             * @param name Name of the EJB resource reference to remove
831:             */
832:            public void removeEjb(String name);
833:
834:            /**
835:             * Remove any environment entry with the specified name.
836:             *
837:             * @param name Name of the environment entry to remove
838:             */
839:            public void removeEnvironment(String name);
840:
841:            /**
842:             * Remove the error page for the specified error code or
843:             * Java language exception, if it exists; otherwise, no action is taken.
844:             *
845:             * @param errorPage The error page definition to be removed
846:             */
847:            public void removeErrorPage(ErrorPage errorPage);
848:
849:            /**
850:             * Remove the specified filter definition from this Context, if it exists;
851:             * otherwise, no action is taken.
852:             *
853:             * @param filterDef Filter definition to be removed
854:             */
855:            public void removeFilterDef(FilterDef filterDef);
856:
857:            /**
858:             * Remove a filter mapping from this Context.
859:             *
860:             * @param filterMap The filter mapping to be removed
861:             */
862:            public void removeFilterMap(FilterMap filterMap);
863:
864:            /**
865:             * Remove a class name from the set of InstanceListener classes that
866:             * will be added to newly created Wrappers.
867:             *
868:             * @param listener Class name of an InstanceListener class to be removed
869:             */
870:            public void removeInstanceListener(String listener);
871:
872:            /**
873:             * Remove any local EJB resource reference with the specified name.
874:             *
875:             * @param name Name of the EJB resource reference to remove
876:             */
877:            public void removeLocalEjb(String name);
878:
879:            /**
880:             * Remove the MIME mapping for the specified extension, if it exists;
881:             * otherwise, no action is taken.
882:             *
883:             * @param extension Extension to remove the mapping for
884:             */
885:            public void removeMimeMapping(String extension);
886:
887:            /**
888:             * Remove the context initialization parameter with the specified
889:             * name, if it exists; otherwise, no action is taken.
890:             *
891:             * @param name Name of the parameter to remove
892:             */
893:            public void removeParameter(String name);
894:
895:            /**
896:             * Remove any resource reference with the specified name.
897:             *
898:             * @param name Name of the resource reference to remove
899:             */
900:            public void removeResource(String name);
901:
902:            /**
903:             * Remove any resource environment reference with the specified name.
904:             *
905:             * @param name Name of the resource environment reference to remove
906:             */
907:            public void removeResourceEnvRef(String name);
908:
909:            /**
910:             * Remove any resource link with the specified name.
911:             *
912:             * @param name Name of the resource link to remove
913:             */
914:            public void removeResourceLink(String name);
915:
916:            /**
917:             * Remove any security role reference for the specified name
918:             *
919:             * @param role Security role (as used in the application) to remove
920:             */
921:            public void removeRoleMapping(String role);
922:
923:            /**
924:             * Remove any security role with the specified name.
925:             *
926:             * @param role Security role to remove
927:             */
928:            public void removeSecurityRole(String role);
929:
930:            /**
931:             * Remove any servlet mapping for the specified pattern, if it exists;
932:             * otherwise, no action is taken.
933:             *
934:             * @param pattern URL pattern of the mapping to remove
935:             */
936:            public void removeServletMapping(String pattern);
937:
938:            /**
939:             * Remove the tag library location forthe specified tag library URI.
940:             *
941:             * @param uri URI, relative to the web.xml file
942:             */
943:            public void removeTaglib(String uri);
944:
945:            /**
946:             * Remove the specified welcome file name from the list recognized
947:             * by this Context.
948:             *
949:             * @param name Name of the welcome file to be removed
950:             */
951:            public void removeWelcomeFile(String name);
952:
953:            /**
954:             * Remove a class name from the set of LifecycleListener classes that
955:             * will be added to newly created Wrappers.
956:             *
957:             * @param listener Class name of a LifecycleListener class to be removed
958:             */
959:            public void removeWrapperLifecycle(String listener);
960:
961:            /**
962:             * Remove a class name from the set of ContainerListener classes that
963:             * will be added to newly created Wrappers.
964:             *
965:             * @param listener Class name of a ContainerListener class to be removed
966:             */
967:            public void removeWrapperListener(String listener);
968:
969:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.