comparison _test/Resources/sample.xml @ 222:84a6382b49c8

resources schema in progress
author sergey
date Mon, 27 Aug 2012 17:28:32 +0400
parents e997e6fbac0b
children edf011437be8
comparison
equal deleted inserted replaced
221:e997e6fbac0b 222:84a6382b49c8
2 <resources xmlns="http://implab.org/schemas/resources" 2 <resources xmlns="http://implab.org/schemas/resources"
3 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 3 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4 xsi:schemaLocation="http://implab.org/schemas/resources resources.xsd "> 4 xsi:schemaLocation="http://implab.org/schemas/resources resources.xsd ">
5 <root> 5 <root>
6 <get> 6 <get>
7 <bind text="model" /> 7 <bind bind="model" />
8 </get> 8 </get>
9 9
10 <resource name="projects"> 10 <resource name="projects">
11 <contract> 11 <contract>
12 <get> 12 <get>
13 <bind text="parent.model.projects" /> 13 <bind bind="parent.model.projects" />
14 </get> 14 </get>
15 <post> 15 <post>
16 <bind text="parent.model.CreateProject($form)"> 16 <bind bind="parent.model.CreateProject($form)">
17 <var name="form" text="request"/> 17 <var name="form" bind="request"/>
18 </bind> 18 </bind>
19 <response xsi:type="redirectResponse">
20 <locatorRef ref="relative-locator"/>
21 </response>
19 </post> 22 </post>
20 </contract> 23 </contract>
24
25 <resource match="(\w+)">
26
27 </resource>
21 </resource> 28 </resource>
22 </root> 29 </root>
23 <typeMap> 30 <typeMap>
24 <item></item>
25 <item></item>
26 </typeMap> 31 </typeMap>
27 <locators> 32 <locators>
28 <locator name="relative"> 33 <locator name="relative-locator">
29 <var name="id" text="model.id" /> 34 <var name="id" bind="model.id" />
30 <var name="parent" text="parent.location" /> 35 <var name="parent" bind="parent.location" />
31 <template>$parent/$id</template> 36 <template>$parent/$id</template>
32 </locator> 37 </locator>
33 <locator name="projects"> 38 <locator name="projects-locator">
34 <var name="id" text="model.id" /> 39 <var name="id" bind="model.id" />
35 <var name="projects" text="application.locate('projects')" /> 40 <var name="projects" bind="application.locate('projects')" />
36 <template>$projects/$id</template> 41 <template>$projects/$id</template>
37 </locator> 42 </locator>
38 </locators> 43 </locators>
39 </resources> 44 </resources>