Changeset 700

Show
Ignore:
Timestamp:
12/15/07 13:51:16 (1 year ago)
Author:
laurentj
Message:

task #373: updated relaxng schemas

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/lib/jelix/docs/ns/dao.rng

    r386 r700  
    6464               <optional><attribute name="regexp" /></optional> 
    6565               <optional><attribute name="sequence" /></optional> 
    66                <optional><attribute name="updatemotif" /></optional> 
    67                <optional><attribute name="insertmotif" /></optional> 
    68                <optional><attribute name="selectmotif" /></optional> 
     66               <optional><attribute name="updatepattern" /></optional> 
     67               <optional><attribute name="insertpattern" /></optional> 
     68               <optional><attribute name="selectpattern" /></optional> 
     69               <optional><attribute name="default" /></optional> 
    6970            </element> 
    7071         </oneOrMore> 
     
    7677   <define name="factory"> 
    7778      <element name="factory"> 
     79         <optional><attribute name="events" /></optional> 
    7880         <oneOrMore> 
    7981            <ref name="method" /> 
     
    99101            <attribute name="type"><value>delete</value></attribute> 
    100102            <ref name="method.common" /> 
     103            <ref name="method.events" /> 
    101104            <ref name="method.conditions"/> 
    102105         </element> 
     
    115118            <ref name="method.common" /> 
    116119            <ref name="method.values" /> 
     120            <ref name="method.events" /> 
    117121            <ref name="method.conditions" /> 
    118122         </element> 
     
    130134                <attribute name="distinct" /> 
    131135            </optional> 
     136            <optional> 
     137                <attribute name="groupby" /> 
     138            </optional> 
    132139            <ref name="method.common" /> 
    133140            <ref name="method.conditions" /> 
     
    147154         </element> 
    148155      </zeroOrMore> 
     156   </define> 
     157 
     158   <define name="method.events"> 
     159       <optional> 
     160           <attribute name="eventbefore"> 
     161               <choice> 
     162                  <value>true</value> 
     163                  <value>false</value> 
     164              </choice> 
     165           </attribute> 
     166       </optional> 
     167       <optional> 
     168           <attribute name="eventafter"> 
     169               <choice> 
     170                   <value>true</value> 
     171                   <value>false</value> 
     172               </choice> 
     173           </attribute> 
     174       </optional> 
    149175   </define> 
    150176 
     
    299325         <value>date</value> 
    300326         <value>string</value> 
     327         <value>text</value> 
     328         <value>boolean</value> 
    301329      </choice> 
    302330   </define> 
  • trunk/lib/jelix/docs/ns/dao.rng

    r386 r700  
    6464               <optional><attribute name="regexp" /></optional> 
    6565               <optional><attribute name="sequence" /></optional> 
    66                <optional><attribute name="updatemotif" /></optional> 
    67                <optional><attribute name="insertmotif" /></optional> 
    68                <optional><attribute name="selectmotif" /></optional> 
     66               <optional><attribute name="updatepattern" /></optional> 
     67               <optional><attribute name="insertpattern" /></optional> 
     68               <optional><attribute name="selectpattern" /></optional> 
     69               <optional><attribute name="default" /></optional> 
    6970            </element> 
    7071         </oneOrMore> 
     
    7677   <define name="factory"> 
    7778      <element name="factory"> 
     79         <optional><attribute name="events" /></optional> 
    7880         <oneOrMore> 
    7981            <ref name="method" /> 
     
    99101            <attribute name="type"><value>delete</value></attribute> 
    100102            <ref name="method.common" /> 
     103            <ref name="method.events" /> 
    101104            <ref name="method.conditions"/> 
    102105         </element> 
     
    115118            <ref name="method.common" /> 
    116119            <ref name="method.values" /> 
     120            <ref name="method.events" /> 
    117121            <ref name="method.conditions" /> 
    118122         </element> 
     
    130134                <attribute name="distinct" /> 
    131135            </optional> 
     136            <optional> 
     137                <attribute name="groupby" /> 
     138            </optional> 
    132139            <ref name="method.common" /> 
    133140            <ref name="method.conditions" /> 
     
    147154         </element> 
    148155      </zeroOrMore> 
     156   </define> 
     157 
     158   <define name="method.events"> 
     159       <optional> 
     160           <attribute name="eventbefore"> 
     161               <choice> 
     162                  <value>true</value> 
     163                  <value>false</value> 
     164              </choice> 
     165           </attribute> 
     166       </optional> 
     167       <optional> 
     168           <attribute name="eventafter"> 
     169               <choice> 
     170                   <value>true</value> 
     171                   <value>false</value> 
     172               </choice> 
     173           </attribute> 
     174       </optional> 
    149175   </define> 
    150176 
     
    299325         <value>date</value> 
    300326         <value>string</value> 
     327         <value>text</value> 
     328         <value>boolean</value> 
    301329      </choice> 
    302330   </define> 
  • trunk/lib/jelix/docs/ns/jforms.rng

    r581 r700  
    33  xmlns="http://relaxng.org/ns/structure/1.0" 
    44  xmlns:ev="http://www.w3.org/2001/xml-events" 
     5  datatype="http://www.w3.org/2001/XMLSchema-datatypes" 
    56  ns="http://jelix.org/ns/forms/1.0"> 
    67 
     
    3940     <element name="input"> 
    4041       <ref name="control.common" /> 
    41        <optional><ref name="control.datatypes" /></optional> 
     42         <choice> 
     43            <group> 
     44                <attribute name="type"><value>string</value></attribute> 
     45                <ref name="attr.length" /> 
     46                <ref name="attr.size" /> 
     47            </group> 
     48            <attribute name="type"> 
     49                <choice> 
     50                    <value>boolean</value> 
     51                    <value>decimal</value> 
     52                    <value>integer</value> 
     53                    <value>hexadecimal</value> 
     54                    <value>datetime</value> 
     55                    <value>date</value> 
     56                    <value>time</value> 
     57                    <value>localedatetime</value> 
     58                    <value>localedate</value> 
     59                    <value>localetime</value> 
     60                    <value>url</value> 
     61                    <value>email</value> 
     62                    <value>ipv4</value> 
     63                    <value>ipv6</value> 
     64                </choice> 
     65            </attribute> 
     66            <ref name="attr.length" /> 
     67        </choice> 
    4268       <ref name="UI.attr.readonly" /> 
    4369       <ref name="UI.attr.required" /> 
     
    5278       <ref name="UI.attr.required" /> 
    5379       <ref name="UI.attr.defaultvalue" /> 
     80       <ref name="attr.length" /> 
     81       <optional><attribute name="rows"><data type="integer" /></attribute></optional> 
     82       <optional><attribute name="cols"><data type="integer" /></attribute></optional> 
    5483     </element> 
    5584  </define> 
     
    6089       <ref name="UI.attr.readonly" /> 
    6190       <ref name="UI.attr.required" /> 
     91       <ref name="attr.size" /> 
    6292       <optional> 
    6393          <element name="confirm"> 
     
    81111       <ref name="UI.attr.required" /> 
    82112       <optional><attribute name="mimetype" /></optional> 
    83        <optional><attribute name="maxsize" /></optional> 
     113       <optional><attribute name="maxsize"><data type="integer" /></attribute></optional> 
    84114       <!--<element name="storage"> 
    85115           <attribute name="type"><choice><value>file</value><value>blob</value></choice></attribute> 
     
    111141       <ref name="control.common" /> 
    112142       <ref name="control.list.common" /> 
     143       <ref name="attr.size" /> 
    113144       <optional> 
    114145            <attribute name="multiple"> 
     
    116147            </attribute> 
    117148       </optional> 
    118        <optional> 
    119             <attribute name="size" /> 
    120        </optional> 
    121149     </element> 
    122150  </define> 
     
    146174     <element name="submit"> 
    147175       <ref name="control.common" /> 
    148        <choice> 
    149             <oneOrMore> 
    150                 <ref name="item" /> 
    151             </oneOrMore> 
    152             <ref name="data.dao" /> 
     176       <ref name="datasources" /> 
     177     </element> 
     178  </define> 
     179 
     180  <define name="control.common"> 
     181     <attribute name="ref" /> 
     182     <ref name="label" /> 
     183     <optional> 
     184        <ref name="help" /> 
     185     </optional> 
     186     <optional> 
     187        <ref name="hint" /> 
     188     </optional> 
     189     <optional> 
     190        <ref name="alert" /> 
     191     </optional> 
     192  </define> 
     193   
     194  <define name="UI.attr.readonly"> 
     195      <optional><attribute name="readonly"><choice><value>true</value><value>false</value></choice></attribute></optional> 
     196  </define> 
     197  <define name="UI.attr.required"> 
     198      <optional><attribute name="required"><choice><value>true</value><value>false</value></choice></attribute></optional> 
     199  </define> 
     200  <define name="UI.attr.defaultvalue"> 
     201      <optional><attribute name="defaultvalue" /></optional> 
     202  </define> 
     203   
     204  <define name="attr.length"> 
     205      <optional><attribute name="minlength"><data type="integer" /></attribute></optional> 
     206      <optional><attribute name="maxlength"><data type="integer" /></attribute></optional> 
     207  </define> 
     208 
     209  <define name="attr.size"> 
     210      <optional><attribute name="size"><data type="integer" /></attribute></optional> 
     211  </define> 
     212 
     213 
     214  <define name="control.list.common"> 
     215     <ref name="UI.attr.readonly" /> 
     216     <ref name="UI.attr.required" /> 
     217    <ref name="datasources" /> 
     218    <optional> 
     219        <choice> 
     220            <attribute name="selectedvalue" /> 
     221            <element name="selectedvalues"> 
     222                <oneOrMore> 
     223                    <element name="value"><text/></element> 
     224                </oneOrMore> 
     225            </element> 
    153226        </choice> 
    154      </element> 
    155   </define> 
     227    </optional> 
     228  </define> 
     229 
     230  <define name="datasources"> 
     231     <optional><choice> 
     232        <ref name="datasources.items" /> 
     233        <ref name="datasources.dao" /> 
     234        <ref name="datasources.class" /> 
     235    </choice></optional> 
     236  </define> 
     237 
     238  <define name="datasources.items"> 
     239     <oneOrMore> 
     240        <element name="item"> 
     241            <choice> 
     242                <text /> 
     243                <empty /> 
     244                <group> 
     245                    <attribute name="locale" /> 
     246                    <empty/> 
     247                </group> 
     248            </choice> 
     249            <optional><attribute name="selected"><choice><value>true</value><value>false</value></choice></attribute></optional> 
     250            <attribute name="value" /> 
     251        </element> 
     252    </oneOrMore> 
     253  </define> 
     254 
     255  <define name="datasources.dao"> 
     256      <attribute name="dao" /> 
     257      <attribute name="daomethod" /> 
     258      <attribute name="daolabelproperty" /> 
     259      <optional><attribute name="daovalueproperty" /></optional> 
     260  </define> 
     261 
     262  <define name="datasources.class"> 
     263      <attribute name="dsclass" /> 
     264  </define> 
     265 
     266  <define name="message.content"> 
     267      <choice> 
     268          <text /> 
     269          <attribute name="locale" /> 
     270      </choice> 
     271  </define> 
     272 
     273  <define name="label"> 
     274     <element name="label"> 
     275        <ref name="message.content" /> 
     276     </element> 
     277  </define> 
     278 
     279  <define name="help"> 
     280     <element name="help"> 
     281        <ref name="message.content" /> 
     282     </element> 
     283  </define> 
     284 
     285  <define name="hint"> 
     286     <element name="hint"> 
     287        <ref name="message.content" /> 
     288     </element> 
     289  </define> 
     290 
     291  <define name="alert"> 
     292     <element name="alert"> 
     293        <optional> 
     294           <attribute name="type"> 
     295                <choice> 
     296                    <value>required</value> 
     297                    <value>invalid</value> 
     298                </choice> 
     299            </attribute> 
     300        </optional> 
     301        <ref name="message.content" /> 
     302     </element> 
     303  </define> 
     304 
     305   <!-- 
     306   <define name="any"> 
     307      <element> 
     308         <anyName/> 
     309         <zeroOrMore> 
     310            <choice> 
     311               <attribute> 
     312                  <anyName/> 
     313               </attribute> 
     314               <text/> 
     315               <ref name="any"/> 
     316            </choice> 
     317         </zeroOrMore> 
     318      </element> 
     319   </define> 
     320--> 
    156321 
    157322   
     
    177342   
    178343 
    179   <define name="control.common"> 
    180      <attribute name="ref" /> 
    181      <ref name="label" /> 
    182      <optional> 
    183         <ref name="help" /> 
    184      </optional> 
    185      <optional> 
    186         <ref name="hint" /> 
    187      </optional> 
    188      <optional> 
    189         <ref name="alert" /> 
    190      </optional> 
    191   </define> 
    192    
    193   <define name="UI.attr.readonly"> 
    194       <optional><attribute name="readonly"><choice><value>true</value><value>false</value></choice></attribute></optional> 
    195   </define> 
    196   <define name="UI.attr.required"> 
    197       <optional><attribute name="required"><choice><value>true</value><value>false</value></choice></attribute></optional> 
    198   </define> 
    199   <define name="UI.attr.defaultvalue"> 
    200       <optional><attribute name="defaultvalue" /></optional> 
    201   </define> 
    202    
    203    
    204   <define name="control.list.common"> 
    205      <ref name="UI.attr.readonly" /> 
    206      <ref name="UI.attr.required" /> 
    207      <choice> 
    208         <oneOrMore> 
    209             <ref name="item" /> 
    210         </oneOrMore> 
    211         <ref name="data.dao" /> 
    212     </choice> 
    213     <optional> 
    214         <choice> 
    215             <attribute name="selectedvalue" /> 
    216             <element name="selectedvalues"> 
    217                 <oneOrMore> 
    218                 <element name="value"><text/></element> 
    219                 </oneOrMore> 
    220             </element> 
    221         </choice> 
    222     </optional> 
    223   </define> 
    224    
    225   <define name="item"> 
    226      <element name="item"> 
    227         <choice> 
    228             <text /> 
    229             <empty /> 
    230             <group> 
    231                 <attribute name="locale" /> 
    232                 <empty/> 
    233             </group> 
    234         </choice> 
    235          <optional><attribute name="selected"><choice><value>true</value><value>false</value></choice></attribute></optional> 
    236          <attribute name="value" /> 
    237      </element> 
    238   </define> 
    239    
    240   <define name="data.dao"> 
    241       <attribute name="dao" /> 
    242       <attribute name="daomethod" /> 
    243       <attribute name="daolabelproperty" /> 
    244       <optional><attribute name="daovalueproperty" /></optional> 
    245   </define> 
    246    
    247   <define name="control.datatypes"> 
    248      <!--<choice>--> 
    249         <ref name="datatype.attr"/> 
    250      <!--   <element name="datatype"> 
    251            <ref name="datatype.attr"/> 
    252            <optional><attribute name="length" /></optional> 
    253            <optional><attribute name="minlength" /></optional> 
    254            <optional><attribute name="maxlength" /></optional> 
    255            <optional><attribute name="pattern" /></optional> 
    256            <optional><attribute name="maxvalue" /></optional> 
    257            <optional><attribute name="minvalue" /></optional> 
    258            <empty /> 
    259         </element>--> 
    260   </define> 
    261  
    262   <define ref="datatype.attr"> 
    263       <attribute name="type"> 
    264           <choice> 
    265               <value>string</value> 
    266               <value>boolean</value> 
    267               <value>decimal</value> 
    268               <value>integer</value> 
    269               <value>hexadecimal</value> 
    270               <value>datetime</value> 
    271               <value>date</value> 
    272               <value>time</value> 
    273               <value>localedatetime</value> 
    274               <value>localedate</value> 
    275               <value>localetime</value> 
    276               <value>url</value> 
    277               <value>email</value> 
    278               <value>ipv4</value> 
    279               <value>ipv6</value> 
    280          </choice> 
    281       </attribute> 
    282   </define> 
    283  
    284   <define name="message.content"> 
    285       <choice> 
    286           <text /> 
    287           <attribute name="locale" /> 
    288       </choice> 
    289   </define> 
    290  
    291  
    292   <define name="label"> 
    293      <element name="label"> 
    294         <ref name="message.content" /> 
    295      </element> 
    296   </define> 
    297  
    298   <define name="help"> 
    299      <element name="help"> 
    300         <ref name="message.content" /> 
    301      </element> 
    302   </define> 
    303  
    304   <define name="hint"> 
    305      <element name="hint"> 
    306         <ref name="message.content" /> 
    307      </element> 
    308   </define> 
    309    
    310   <define name="alert"> 
    311      <element name="alert"> 
    312         <optional> 
    313            <attribute name="type"> 
    314                 <choice> 
    315                     <value>required</value> 
    316                     <value>invalid</value> 
    317                 </choice> 
    318             </attribute> 
    319         </optional> 
    320         <ref name="message.content" /> 
    321      </element> 
    322   </define> 
    323     
    324    <!-- 
    325    <define name="any"> 
    326       <element> 
    327          <anyName/> 
    328          <zeroOrMore> 
    329             <choice> 
    330                <attribute> 
    331                   <anyName/> 
    332                </attribute> 
    333                <text/> 
    334                <ref name="any"/> 
    335             </choice> 
    336          </zeroOrMore> 
    337       </element> 
    338    </define> 
    339 --> 
    340344</grammar> 
  • trunk/lib/jelix/docs/ns/jforms.rng

    r581 r700  
    33  xmlns="http://relaxng.org/ns/structure/1.0" 
    44  xmlns:ev="http://www.w3.org/2001/xml-events" 
     5  datatype="http://www.w3.org/2001/XMLSchema-datatypes" 
    56  ns="http://jelix.org/ns/forms/1.0"> 
    67 
     
    3940     <element name="input"> 
    4041       <ref name="control.common" /> 
    41        <optional><ref name="control.datatypes" /></optional> 
     42         <choice> 
     43            <group> 
     44                <attribute name="type"><value>string</value></attribute> 
     45                <ref name="attr.length" /> 
     46                <ref name="attr.size" /> 
     47            </group> 
     48            <attribute name="type"> 
     49                <choice> 
     50                    <value>boolean</value> 
     51                    <value>decimal</value> 
     52                    <value>integer</value> 
     53                    <value>hexadecimal</value> 
     54                    <value>datetime</value> 
     55                    <value>date</value> 
     56                    <value>time</value> 
     57                    <value>localedatetime</value> 
     58                    <value>localedate</value> 
     59                    <value>localetime</value> 
     60                    <value>url</value> 
     61                    <value>email</value> 
     62                    <value>ipv4</value> 
     63                    <value>ipv6</value> 
     64                </choice> 
     65            </attribute> 
     66            <ref name="attr.length" /> 
     67        </choice> 
    4268       <ref name="UI.attr.readonly" /> 
    4369       <ref name="UI.attr.required" /> 
     
    5278       <ref name="UI.attr.required" /> 
    5379       <ref name="UI.attr.defaultvalue" /> 
     80       <ref name="attr.length" /> 
     81       <optional><attribute name="rows"><data type="integer" /></attribute></optional> 
     82       <optional><attribute name="cols"><data type="integer" /></attribute></optional> 
    5483     </element> 
    5584  </define> 
     
    6089       <ref name="UI.attr.readonly" /> 
    6190       <ref name="UI.attr.required" /> 
     91       <ref name="attr.size" /> 
    6292       <optional> 
    6393          <element name="confirm"> 
     
    81111       <ref name="UI.attr.required" /> 
    82112       <optional><attribute name="mimetype" /></optional> 
    83        <optional><attribute name="maxsize" /></optional> 
     113       <optional><attribute name="maxsize"><data type="integer" /></attribute></optional> 
    84114       <!--<element name="storage"> 
    85115           <attribute name="type"><choice><value>file</value><value>blob</value></choice></attribute> 
     
    111141       <ref name="control.common" /> 
    112142       <ref name="control.list.common" /> 
     143       <ref name="attr.size" /> 
    113144       <optional> 
    114145            <attribute name="multiple"> 
     
    116147            </attribute> 
    117148       </optional> 
    118        <optional> 
    119             <attribute name="size" /> 
    120        </optional> 
    121149     </element> 
    122150  </define> 
     
    146174     <element name="submit"> 
    147175       <ref name="control.common" /> 
    148        <choice> 
    149             <oneOrMore> 
    150                 <ref name="item" /> 
    151             </oneOrMore> 
    152             <ref name="data.dao" /> 
     176       <ref name="datasources" /> 
     177     </element> 
     178  </define> 
     179 
     180  <define name="control.common"> 
     181     <attribute name="ref" /> 
     182     <ref name="label" /> 
     183     <optional> 
     184        <ref name="help" /> 
     185     </optional> 
     186     <optional> 
     187        <ref name="hint" /> 
     188     </optional> 
     189     <optional> 
     190        <ref name="alert" /> 
     191     </optional> 
     192  </define> 
     193   
     194  <define name="UI.attr.readonly"> 
     195      <optional><attribute name="readonly"><choice><value>true</value><value>false</value></choice></attribute></optional> 
     196  </define> 
     197  <define name="UI.attr.required"> 
     198      <optional><attribute name="required"><choice><value>true</value><value>false</value></choice></attribute></optional> 
     199  </define> 
     200  <define name="UI.attr.defaultvalue"> 
     201      <optional><attribute name="defaultvalue" /></optional> 
     202  </define> 
     203   
     204  <define name="attr.length"> 
     205      <optional><attribute name="minlength"><data type="integer" /></attribute></optional> 
     206      <optional><attribute name="maxlength"><data type="integer" /></attribute></optional> 
     207  </define> 
     208 
     209  <define name="attr.size"> 
     210      <optional><attribute name="size"><data type="integer" /></attribute></optional> 
     211  </define> 
     212 
     213 
     214  <define name="control.list.common"> 
     215     <ref name="UI.attr.readonly" /> 
     216     <ref name="UI.attr.required" /> 
     217    <ref name="datasources" /> 
     218    <optional> 
     219        <choice> 
     220            <attribute name="selectedvalue" /> 
     221            <element name="selectedvalues"> 
     222                <oneOrMore> 
     223                    <element name="value"><text/></element> 
     224                </oneOrMore> 
     225            </element> 
    153226        </choice> 
    154      </element> 
    155   </define> 
     227    </optional> 
     228  </define> 
     229 
     230  <define name="datasources"> 
     231     <optional><choice> 
     232        <ref name="datasources.items" /> 
     233        <ref name="datasources.dao" /> 
     234        <ref name="datasources.class" /> 
     235    </choice></optional> 
     236  </define> 
     237 
     238  <define name="datasources.items"> 
     239     <oneOrMore> 
     240        <element name="item"> 
     241            <choice> 
     242                <text /> 
     243                <empty /> 
     244                <group> 
     245                    <attribute name="locale" /> 
     246                    <empty/> 
     247                </group> 
     248            </choice> 
     249            <optional><attribute name="selected"><choice><value>true</value><value>false</value></choice></attribute></optional> 
     250            <attribute name="value" /> 
     251        </element> 
     252    </oneOrMore> 
     253  </define> 
     254 
     255  <define name="datasources.dao"> 
     256      <attribute name="dao" /> 
     257      <attribute name="daomethod" /> 
     258      <attribute name="daolabelproperty" /> 
     259      <optional><attribute name="daovalueproperty" /></optional> 
     260  </define> 
     261 
     262  <define name="datasources.class"> 
     263      <attribute name="dsclass" /> 
     264  </define> 
     265 
     266  <define name="message.content"> 
     267      <choice> 
     268          <text /> 
     269          <attribute name="locale" /> 
     270      </choice> 
     271  </define> 
     272 
     273  <define name="label"> 
     274     <element name="label"> 
     275        <ref name="message.content" /> 
     276     </element> 
     277  </define> 
     278 
     279  <define name="help"> 
     280     <element name="help"> 
     281        <ref name="message.content" /> 
     282     </element> 
     283  </define> 
     284 
     285  <define name="hint"> 
     286     <element name="hint"> 
     287        <ref name="message.content" /> 
     288     </element> 
     289  </define> 
     290 
     291  <define name="alert"> 
     292     <element name="alert"> 
     293        <optional> 
     294           <attribute name="type"> 
     295                <choice> 
     296                    <value>required</value> 
     297                    <value>invalid</value> 
     298                </choice> 
     299            </attribute> 
     300        </optional> 
     301        <ref name="message.content" /> 
     302     </element> 
     303  </define> 
     304 
     305   <!-- 
     306   <define name="any"> 
     307      <element> 
     308         <anyName/> 
     309         <zeroOrMore> 
     310            <choice> 
     311               <attribute> 
     312                  <anyName/> 
     313               </attribute> 
     314               <text/> 
     315               <ref name="any"/> 
     316            </choice> 
     317         </zeroOrMore> 
     318      </element> 
     319   </define> 
     320--> 
    156321 
    157322   
     
    177342   
    178343 
    179   <define name="control.common"> 
    180      <attribute name="ref" /> 
    181      <ref name="label" /> 
    182      <optional> 
    183         <ref name="help" /> 
    184      </optional> 
    185      <optional> 
    186         <ref name="hint" /> 
    187      </optional> 
    188      <optional> 
    189         <ref name="alert" /> 
    190      </optional> 
    191   </define> 
    192    
    193   <define name="UI.attr.readonly"> 
    194       <optional><attribute name="readonly"><choice><value>true</value><value>false</value></choice></attribute></optional> 
    195   </define> 
    196   <define name="UI.attr.required"> 
    197       <optional><attribute name="required"><choice><value>true</value><value>false</value></choice></attribute></optional> 
    198   </define> 
    199   <define name="UI.attr.defaultvalue"> 
    200       <optional><attribute name="defaultvalue" /></optional> 
    201   </define> 
    202    
    203    
    204   <define name="control.list.common"> 
    205      <ref name="UI.attr.readonly" /> 
    206      <ref name="UI.attr.required" /> 
    207      <choice> 
    208         <oneOrMore> 
    209             <ref name="item" /> 
    210         </oneOrMore> 
    211         <ref name="data.dao" /> 
    212     </choice> 
    213     <optional> 
    214         <choice> 
    215             <attribute name="selectedvalue" /> 
    216             <element name="selectedvalues"> 
    217                 <oneOrMore> 
    218                 <element name="value"><text/></element> 
    219                 </oneOrMore> 
    220             </element> 
    221         </choice> 
    222     </optional> 
    223   </define> 
    224    
    225   <define name="item"> 
    226      <element name="item"> 
    227         <choice> 
    228             <text /> 
    229             <empty /> 
    230             <group> 
    231                 <attribute name="locale" /> 
    232                 <empty/> 
    233             </group> 
    234         </choice> 
    235          <optional><attribute name="selected"><choice><value>true</value><value>false</value></choice></attribute></optional> 
    236          <attribute name="value" /> 
    237      </element> 
    238   </define> 
    239    
    240   <define name="data.dao"> 
    241       <attribute name="dao" /> 
    242       <attribute name="daomethod" /> 
    243       <attribute name="daolabelproperty" /> 
    244       <optional><attribute name="daovalueproperty" /></optional> 
    245   </define> 
    246    
    247   <define name="control.datatypes"> 
    248      <!--<choice>--> 
    249         <ref name="datatype.attr"/> 
    250      <!--   <element name="datatype"> 
    251            <ref name="datatype.attr"/> 
    252            <optional><attribute name="length" /></optional> 
    253            <optional><attribute name="minlength" /></optional> 
    254            <optional><attribute name="maxlength" /></optional> 
    255            <optional><attribute name="pattern" /></optional> 
    256            <optional><attribute name="maxvalue" /></optional> 
    257            <optional><attribute name="minvalue" /></optional> 
    258            <empty /> 
    259         </element>--> 
    260   </define> 
    261  
    262   <define ref="datatype.attr"> 
    263       <attribute name="type"> 
    264           <choice> 
    265               <value>string</value> 
    266               <value>boolean</value> 
    267               <value>decimal</value> 
    268               <value>integer</value> 
    269               <value>hexadecimal</value> 
    270               <value>datetime</value> 
    271               <value>date</value> 
    272               <value>time</value> 
    273               <value>localedatetime</value> 
    274               <value>localedate</value> 
    275               <value>localetime</value> 
    276               <value>url</value> 
    277               <value>email</value> 
    278               <value>ipv4</value> 
    279               <value>ipv6</value> 
    280          </choice> 
    281       </attribute> 
    282   </define> 
    283  
    284   <define name="message.content"> 
    285       <choice> 
    286           <text /> 
    287           <attribute name="locale" /> 
    288       </choice> 
    289   </define> 
    290  
    291  
    292   <define name="label"> 
    293      <element name="label"> 
    294         <ref name="message.content" /> 
    295      </element> 
    296   </define> 
    297  
    298   <define name="help"> 
    299      <element name="help"> 
    300         <ref name="message.content" /> 
    301      </element> 
    302   </define> 
    303  
    304   <define name="hint"> 
    305      <element name="hint"> 
    306         <ref name="message.content" /> 
    307      </element> 
    308   </define> 
    309    
    310   <define name="alert"> 
    311      <element name="alert"> 
    312         <optional> 
    313            <attribute name="type"> 
    314                 <choice> 
    315                     <value>required</value> 
    316                     <value>invalid</value> 
    317                 </choice> 
    318             </attribute> 
    319         </optional> 
    320         <ref name="message.content" /> 
    321      </element> 
    322   </define> 
    323     
    324    <!-- 
    325    <define name="any"> 
    326       <element> 
    327          <anyName/> 
    328          <zeroOrMore> 
    329             <choice> 
    330                <attribute> 
    331                   <anyName/> 
    332                </attribute> 
    333                <text/> 
    334                <ref name="any"/> 
    335             </choice> 
    336          </zeroOrMore> 
    337       </element> 
    338    </define> 
    339 --> 
    340344</grammar> 
  • trunk/lib/jelix/docs/ns/urls.rng

    </
    r386 r700  
    2323            <name>xmlentrypoint</name> 
    2424            <name>xulentrypoint</name> 
     25            <name>cssentrypoint</name> 
    2526         </choice> 
    2627 
     28         <attribute name="name"/>