mpo         2003/12/19 00:06:50

  Modified:    src/blocks/woody/java/org/apache/cocoon/woody/binding
                        JXpathBindingBuilderBase.java
  Log:
  Additional check for deprecated @readonly.
  
  Revision  Changes    Path
  1.6       +6 -2      
cocoon-2.1/src/blocks/woody/java/org/apache/cocoon/woody/binding/JXpathBindingBuilderBase.java
  
  Index: JXpathBindingBuilderBase.java
  ===================================================================
  RCS file: 
/home/cvs/cocoon-2.1/src/blocks/woody/java/org/apache/cocoon/woody/binding/JXpathBindingBuilderBase.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- JXpathBindingBuilderBase.java     18 Dec 2003 07:57:21 -0000      1.5
  +++ JXpathBindingBuilderBase.java     19 Dec 2003 08:06:50 -0000      1.6
  @@ -123,8 +123,12 @@
        */
        static CommonAttributes getCommonAttributes(Element bindingElm) throws 
BindingException {
           try {
  -            //TODO: should we evetually remove this?
  -            //throw an error if people are still using the old-style 
@read-only
  +            //TODO: should we eventually remove this?
  +            //throw an error if people are still using the old-style 
@read-only or @readonly
  +            if (DomHelper.getAttributeAsBoolean(bindingElm, "readonly", 
false)) {
  +                throw new BindingException("Error in binding file " + 
DomHelper.getLocation(bindingElm) 
  +                        + "\nThe usage of the attribute @readonly has been 
depricated in favour of @direction.");
  +            }
               if (DomHelper.getAttributeAsBoolean(bindingElm, "read-only", 
false)) {
                   throw new BindingException("Error in binding file " + 
DomHelper.getLocation(bindingElm) 
                           + "\nThe usage of the attribute @read-only has been 
depricated in favour of @direction.");
  
  
  

Reply via email to