cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vgritse...@apache.org
Subject cvs commit: xml-cocoon2/src/java/org/apache/cocoon/transformation EncodeURLTransformer.java
Date Tue, 22 Oct 2002 04:04:21 GMT
vgritsenko    2002/10/21 21:04:21

  Modified:    src/java/org/apache/cocoon/transformation
                        EncodeURLTransformer.java
  Log:
  reduce overoptimization
  
  Revision  Changes    Path
  1.3       +10 -12    xml-cocoon2/src/java/org/apache/cocoon/transformation/EncodeURLTransformer.java
  
  Index: EncodeURLTransformer.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/transformation/EncodeURLTransformer.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- EncodeURLTransformer.java	28 May 2002 13:08:13 -0000	1.2
  +++ EncodeURLTransformer.java	22 Oct 2002 04:04:21 -0000	1.3
  @@ -134,6 +134,7 @@
        * @since
        */
       public final static String EXCLUDE_NAME = "exclude-name";
  +
       /**
        * Configuration name for specifying including patterns,
        * ie include-name.
  @@ -149,6 +150,7 @@
        * @since
        */
       public final static String EXCLUDE_NAME_DEFAULT = "img/@src";
  +
       /**
        * Configuration default exclude pattern,
        * ie .*\/@href|.*\/@action|frame/@src
  @@ -184,9 +186,9 @@
           if ( null != this.session ) {
               if ( request.isRequestedSessionIdFromURL() ) {
                   this.response = ObjectModelHelper.getResponse(objectModel);
  -                final String includeName = parameters.getParameter(EncodeURLTransformer.INCLUDE_NAME,
  +                final String includeName = parameters.getParameter(INCLUDE_NAME,
                                                                      this.includeNameConfigure);
  -                final String excludeName = parameters.getParameter(EncodeURLTransformer.EXCLUDE_NAME,
  +                final String excludeName = parameters.getParameter(EXCLUDE_NAME,
                                                                      this.excludeNameConfigure);
                   try {
                       this.elementAttributeMatching = new ElementAttributeMatching(includeName,
excludeName);
  @@ -214,10 +216,10 @@
           if (configuration != null) {
               Configuration child;
   
  -            child = configuration.getChild(EncodeURLTransformer.INCLUDE_NAME);
  +            child = configuration.getChild(INCLUDE_NAME);
               this.includeNameConfigure = child.getValue(INCLUDE_NAME_DEFAULT);
   
  -            child = configuration.getChild(EncodeURLTransformer.EXCLUDE_NAME);
  +            child = configuration.getChild(EXCLUDE_NAME);
               this.excludeNameConfigure = child.getValue(EXCLUDE_NAME_DEFAULT);
           }
           if (this.includeNameConfigure == null) {
  @@ -384,12 +386,8 @@
            * @return               Description of the Returned Value
            * @since
            */
  -        String canonicalizeElementAttribute(String element_name, String attr_name) {
  -            StringBuffer element_attr_name = new StringBuffer();
  -            element_attr_name.append(element_name);
  -            element_attr_name.append("/@");
  -            element_attr_name.append(attr_name);
  -            return element_attr_name.toString();
  +        private String canonicalizeElementAttribute(String element_name, String attr_name)
{
  +            return element_name + "/@" + attr_name;
           }
   
   
  
  
  

----------------------------------------------------------------------
In case of troubles, e-mail:     webmaster@xml.apache.org
To unsubscribe, e-mail:          cocoon-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-cvs-help@xml.apache.org


Mime
View raw message