tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a..@hyperreal.org
Subject cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/deployment TagLibConfig.java TagLibConfigImpl.java Constants.java WebApplicationDescriptor.java WebApplicationDescriptorImpl.java WebApplicationReader.java WebDescriptorFactoryImpl.java
Date Tue, 09 Nov 1999 00:49:09 GMT
akv         99/11/08 16:49:07

  Modified:    src/share/org/apache/tomcat/deployment Tag:
                        TOMCAT_J2EE_10F_102199 Constants.java
                        WebApplicationDescriptor.java
                        WebApplicationDescriptorImpl.java
                        WebApplicationReader.java
                        WebDescriptorFactoryImpl.java
  Added:       src/share/org/apache/tomcat/deployment Tag:
                        TOMCAT_J2EE_10F_102199 TagLibConfig.java
                        TagLibConfigImpl.java
  Log:
  Added support for taglib
  
  <taglib>
     <taglib-uri>...</taglib-uri>
     <taglib-location>...</taglib-location>
  </taglib>
  
  in the object model derived from the web.xml file.
  
  Needs more testing.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.1.1.2.1 +7 -3      jakarta-tomcat/src/share/org/apache/tomcat/deployment/Constants.java
  
  Index: Constants.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/deployment/Constants.java,v
  retrieving revision 1.1.1.1
  retrieving revision 1.1.1.1.2.1
  diff -u -r1.1.1.1 -r1.1.1.1.2.1
  --- Constants.java	1999/10/09 00:20:41	1.1.1.1
  +++ Constants.java	1999/11/09 00:48:15	1.1.1.1.2.1
  @@ -1,7 +1,7 @@
   /*
  - * $Header: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/deployment/Constants.java,v
1.1.1.1 1999/10/09 00:20:41 duncan Exp $
  - * $Revision: 1.1.1.1 $
  - * $Date: 1999/10/09 00:20:41 $
  + * $Header: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/deployment/Constants.java,v
1.1.1.1.2.1 1999/11/09 00:48:15 akv Exp $
  + * $Revision: 1.1.1.1.2.1 $
  + * $Date: 1999/11/09 00:48:15 $
    *
    * ====================================================================
    * 
  @@ -149,6 +149,10 @@
       public static String FORM_LOGIN_CONFIG = "form-login-config";
       public static String FORM_LOGIN_PAGE = "form-login-page";
       public static String FORM_ERROR_PAGE = "form-error-page";
  +
  +    public static final String TAGLIB = "taglib";
  +    public static final String TAGLIB_URI = "taglib-uri";
  +    public static final String TAGLIB_LOCATION = "taglib-location";
   
   
       public static final String JakartaWebApplication =
  
  
  
  1.1.1.1.2.2 +8 -3      jakarta-tomcat/src/share/org/apache/tomcat/deployment/WebApplicationDescriptor.java
  
  Index: WebApplicationDescriptor.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/deployment/WebApplicationDescriptor.java,v
  retrieving revision 1.1.1.1.2.1
  retrieving revision 1.1.1.1.2.2
  diff -u -r1.1.1.1.2.1 -r1.1.1.1.2.2
  --- WebApplicationDescriptor.java	1999/10/30 05:36:25	1.1.1.1.2.1
  +++ WebApplicationDescriptor.java	1999/11/09 00:48:32	1.1.1.1.2.2
  @@ -1,7 +1,7 @@
   /*
  - * $Header: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/deployment/WebApplicationDescriptor.java,v
1.1.1.1.2.1 1999/10/30 05:36:25 gonzo Exp $
  - * $Revision: 1.1.1.1.2.1 $
  - * $Date: 1999/10/30 05:36:25 $
  + * $Header: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/deployment/WebApplicationDescriptor.java,v
1.1.1.1.2.2 1999/11/09 00:48:32 akv Exp $
  + * $Revision: 1.1.1.1.2.2 $
  + * $Date: 1999/11/09 00:48:32 $
    *
    * ====================================================================
    *
  @@ -114,6 +114,11 @@
       
       public LoginConfiguration getLoginConfiguration();
       public void setLoginConfiguration(LoginConfiguration loginConfiguration);
  +
  +    /** Get all the TLD location/uri mappings. */
  +    public Enumeration getTagLibConfigs();
  +    public void addTagLibConfig(TagLibConfig tldConfig);
  +    
       // XXX
       // commented out in anticipation they'll eventually be supported
   /*
  
  
  
  1.1.1.1.2.2 +15 -3     jakarta-tomcat/src/share/org/apache/tomcat/deployment/WebApplicationDescriptorImpl.java
  
  Index: WebApplicationDescriptorImpl.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/deployment/WebApplicationDescriptorImpl.java,v
  retrieving revision 1.1.1.1.2.1
  retrieving revision 1.1.1.1.2.2
  diff -u -r1.1.1.1.2.1 -r1.1.1.1.2.2
  --- WebApplicationDescriptorImpl.java	1999/10/30 05:36:26	1.1.1.1.2.1
  +++ WebApplicationDescriptorImpl.java	1999/11/09 00:48:36	1.1.1.1.2.2
  @@ -1,7 +1,7 @@
   /*
  - * $Header: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/deployment/WebApplicationDescriptorImpl.java,v
1.1.1.1.2.1 1999/10/30 05:36:26 gonzo Exp $
  - * $Revision: 1.1.1.1.2.1 $
  - * $Date: 1999/10/30 05:36:26 $
  + * $Header: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/deployment/WebApplicationDescriptorImpl.java,v
1.1.1.1.2.2 1999/11/09 00:48:36 akv Exp $
  + * $Revision: 1.1.1.1.2.2 $
  + * $Date: 1999/11/09 00:48:36 $
    *
    * ====================================================================
    *
  @@ -70,6 +70,7 @@
   /**
    *
    * @author James Todd [gonzo@eng.sun.com]
  + * @author Anil K. Vijendran [akv@eng.sun.com] -- added support for taglib in web.xml
    */
   
   public class WebApplicationDescriptorImpl
  @@ -86,6 +87,8 @@
       private Vector resourceReferences = new Vector();
       private Vector securityRoles = new Vector();
       private Vector securityConstraints = new Vector();
  +    private Vector tldConfigs = new Vector();
  +    
       // XXX
       // commented out in anticipation they'll eventually be supported 
   /*
  @@ -219,6 +222,14 @@
       public void addEnvironmentEntry(EnvironmentEntry environmentEntry) {
   	this.getEnvironmentEntryVector().addElement(environmentEntry);
       }
  +
  +    public Enumeration getTagLibConfigs() {
  +        return tldConfigs.elements();
  +    }
  +    
  +    public void addTagLibConfig(TagLibConfig tldConfig) {
  +        tldConfigs.addElement(tldConfig);
  +    }
       
       public String toString() {
   	String s = "Web App Descriptor ";
  @@ -242,6 +253,7 @@
   */
   	s = s + " \n loginConfiguration " + loginConfiguration;
   	s = s + " \n environmentEntries " + environmentEntries;
  +        s = s + " \n tldConfigs " + tldConfigs;
   
   	return s;
       }
  
  
  
  1.1.1.1.2.1 +23 -4     jakarta-tomcat/src/share/org/apache/tomcat/deployment/WebApplicationReader.java
  
  Index: WebApplicationReader.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/deployment/WebApplicationReader.java,v
  retrieving revision 1.1.1.1
  retrieving revision 1.1.1.1.2.1
  diff -u -r1.1.1.1 -r1.1.1.1.2.1
  --- WebApplicationReader.java	1999/10/09 00:20:46	1.1.1.1
  +++ WebApplicationReader.java	1999/11/09 00:48:44	1.1.1.1.2.1
  @@ -1,7 +1,7 @@
   /*
  - * $Header: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/deployment/WebApplicationReader.java,v
1.1.1.1 1999/10/09 00:20:46 duncan Exp $
  - * $Revision: 1.1.1.1 $
  - * $Date: 1999/10/09 00:20:46 $
  + * $Header: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/deployment/WebApplicationReader.java,v
1.1.1.1.2.1 1999/11/09 00:48:44 akv Exp $
  + * $Revision: 1.1.1.1.2.1 $
  + * $Date: 1999/11/09 00:48:44 $
    *
    * ====================================================================
    *
  @@ -145,12 +145,17 @@
   		processSecurityRoles();
   		processEnvironmentEntries();    
   		processEjbReferences();
  +                processTagLibConfigs();
   	    } else {
   	        String msg = "parsing error";
   
   		throw new IllegalStateException(msg);
   	    }
   
  +            // FIXME: Anil, remove this when you are done - akv
  +            // System.err.println("Printing the web application descriptor: ");
  +            // System.err.println(webApplicationDescriptor.toString());
  +            
   	    return webApplicationDescriptor;
   	} catch (Throwable t) {
   	    String msg = "parsing error: " + t.getMessage();
  @@ -221,6 +226,19 @@
   	    this.webApplicationDescriptor.addContextParameter(param);
   	 }
       }
  +
  +
  +    private void processTagLibConfigs() {
  +        Enumeration enum = this.config.elements(Constants.TAGLIB);
  +        while (enum.hasMoreElements()) {
  +            XMLTree next = (XMLTree) enum.nextElement();
  +            TagLibConfig config 
  +                = (TagLibConfig) this.factory.createDescriptor(TagLibConfig.class);
  +            config.setTagLibURI(next.getFirstElement(Constants.TAGLIB_URI).getValue());
  +            config.setTagLibLocation(next.getFirstElement(Constants.TAGLIB_LOCATION).getValue());
  +            this.webApplicationDescriptor.addTagLibConfig(config);
  +        }
  +    }
       
        private void processErrorPages() {
   	 Enumeration enum = this.config.elements(Constants.ERROR_PAGE);
  @@ -561,9 +579,9 @@
   	}
   	throw new RuntimeException("There is no web component by the name of " + name + " here.");
       }
  +
       
       
  -
       private Vector parseServlets(Enumeration servlets,
           Enumeration servletMaps) {
           Vector webComponentDescriptors = new Vector();
  @@ -718,4 +736,5 @@
   	
   	return sessionTimeOut.intValue();
       }
  +
   }
  
  
  
  1.1.1.1.2.1 +6 -3      jakarta-tomcat/src/share/org/apache/tomcat/deployment/WebDescriptorFactoryImpl.java
  
  Index: WebDescriptorFactoryImpl.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/deployment/WebDescriptorFactoryImpl.java,v
  retrieving revision 1.1.1.1
  retrieving revision 1.1.1.1.2.1
  diff -u -r1.1.1.1 -r1.1.1.1.2.1
  --- WebDescriptorFactoryImpl.java	1999/10/09 00:20:46	1.1.1.1
  +++ WebDescriptorFactoryImpl.java	1999/11/09 00:48:51	1.1.1.1.2.1
  @@ -1,7 +1,7 @@
   /*
  - * $Header: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/deployment/WebDescriptorFactoryImpl.java,v
1.1.1.1 1999/10/09 00:20:46 duncan Exp $
  - * $Revision: 1.1.1.1 $
  - * $Date: 1999/10/09 00:20:46 $
  + * $Header: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/deployment/WebDescriptorFactoryImpl.java,v
1.1.1.1.2.1 1999/11/09 00:48:51 akv Exp $
  + * $Revision: 1.1.1.1.2.1 $
  + * $Date: 1999/11/09 00:48:51 $
    *
    * ====================================================================
    *
  @@ -116,6 +116,9 @@
               WebResourceCollection.class, WebResourceCollectionImpl.class);
   	this.interfaceToImplementationMap.put(ResourceReference.class,
               ResourceReferenceImpl.class);
  +
  +        this.interfaceToImplementationMap.put(TagLibConfig.class, 
  +                                              TagLibConfigImpl.class);
       }
   
       public Object createDescriptor(Class interfaceType) {
  
  
  
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +70 -0     jakarta-tomcat/src/share/org/apache/tomcat/deployment/Attic/TagLibConfig.java
  
  
  
  
  1.1.2.1   +72 -0     jakarta-tomcat/src/share/org/apache/tomcat/deployment/Attic/TagLibConfigImpl.java
  
  
  
  

Mime
View raw message