[Laszlo-dev] For Review: Change 20080601-hqm-o Summary: add new 'node' type for attributes

Henry Minsky henry.minsky at gmail.com
Sun Jun 1 18:52:20 PDT 2008


Change 20080601-hqm-o by hqm at badtzmaru.home on 2008-06-01 21:48:11 EDT
     in /Users/hqm/openlaszlo/trunk4
     for http://svn.openlaszlo.org/openlaszlo/trunk

Summary: add new 'node' type for attributes

New Features:

Bugs Fixed: LPP-5799

Technical Reviewer: ptw
QA Reviewer: max
Doc Reviewer: dtemkin

Documentation:

You can declare an attribute with the new LZX type 'node', which means  
that it is acceptable
to have a named child with that attribute name. For example:

<class name="myclass">
    <attribute name="titleview" type="node"/>
</class>

<myclass>
   <view name="titleview"/> <!-- this is fine, will not give warning -->
   <view name="source"/>  <!-- this overrides a non-node-type  
attribute, and will give a warning -->
</myclass>


Release Notes:


Details:

Tests:

<canvas>
   <class name="myclass">
     <attribute name="titleview" type="node"/>
   </class>

   <myclass>
     <!-- should be no warning for this, it's a node-type attribute -->
     <view name="titleview"/>

     <!-- should get warning for this, about ndoe name conflicting  
with 'source' attribute -->
     <view name="source"/>
   </myclass>
</canvas>


Files:
M      WEB-INF/lps/server/src/org/openlaszlo/compiler/ViewSchema.java
M      WEB-INF/lps/server/src/org/openlaszlo/compiler/NodeModel.java


Changeset: http://svn.openlaszlo.org/openlaszlo/patches/20080601-hqm-o.tar


More information about the Laszlo-dev mailing list