You are viewing a plain text version of this content. The canonical link for it is here.
Posted to slide-dev@jakarta.apache.org by ju...@apache.org on 2002/05/22 09:36:40 UTC

cvs commit: jakarta-slide/src/share/org/apache/slide/common RequestedPropertiesImpl.java

juergen     02/05/22 00:36:40

  Modified:    src/share/org/apache/slide/common
                        RequestedPropertiesImpl.java
  Log:
  Just a minor refactoring so it may be reused as a super class of PropPatchProperties.
  (ralf)
  
  Revision  Changes    Path
  1.6       +21 -5     jakarta-slide/src/share/org/apache/slide/common/RequestedPropertiesImpl.java
  
  Index: RequestedPropertiesImpl.java
  ===================================================================
  RCS file: /home/cvs/jakarta-slide/src/share/org/apache/slide/common/RequestedPropertiesImpl.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- RequestedPropertiesImpl.java	25 Apr 2002 21:30:12 -0000	1.5
  +++ RequestedPropertiesImpl.java	22 May 2002 07:36:40 -0000	1.6
  @@ -1,7 +1,7 @@
   /*
  - * $Header: /home/cvs/jakarta-slide/src/share/org/apache/slide/common/RequestedPropertiesImpl.java,v 1.5 2002/04/25 21:30:12 jericho Exp $
  - * $Revision: 1.5 $
  - * $Date: 2002/04/25 21:30:12 $
  + * $Header: /home/cvs/jakarta-slide/src/share/org/apache/slide/common/RequestedPropertiesImpl.java,v 1.6 2002/05/22 07:36:40 juergen Exp $
  + * $Revision: 1.6 $
  + * $Date: 2002/05/22 07:36:40 $
    *
    * ====================================================================
    *
  @@ -78,7 +78,7 @@
    * Holds one property as part of the SELECT element.
    *
    * @author <a href="mailto:martin.wallmer@softwareag.com">Martin Wallmer</a>
  - * @version $Revision: 1.5 $
  + * @version $Revision: 1.6 $
    */
   public class RequestedPropertiesImpl implements RequestedProperties {
       
  @@ -115,11 +115,27 @@
   					name = prop.getAttributeValue ("name");
   				}
   
  -				addProperty (new RequestedPropertyImpl (name, uri));
  +                addProperty (createRequestedProperty(name, uri, prop.getText(), prop.getChildren()));
   			}
   		}
       }
       
  +    
  +    /**
  +     * Creates a RequestedProperty from the given parameters. This method
  +     * may be overwritten by subclasses in order to create appropriate
  +     * implementations of RequestedProperty.
  +     *
  +     * @param      name       the name of the propery.
  +     * @param      namespace  the namespace of the propery.
  +     * @param      text       the text of the propery element.
  +     * @param      children   the children of the propery element.
  +     *
  +     * @return     the created RequestedProperty.
  +     */
  +    protected RequestedProperty createRequestedProperty(String name, String namespace, String text, List children) {
  +        return new RequestedPropertyImpl(name, namespace);
  +    }
       
       /**
   	 * Returns an iterator for all selected properties
  
  
  

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>