diff _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
line wrap: on
line diff
--- a/_test/Resources/sample.xml	Fri Aug 24 16:24:14 2012 +0400
+++ b/_test/Resources/sample.xml	Mon Aug 27 17:28:32 2012 +0400
@@ -4,35 +4,40 @@
 	xsi:schemaLocation="http://implab.org/schemas/resources resources.xsd ">
 	<root>
 		<get>
-			<bind text="model" />
+			<bind bind="model" />
 		</get>
 
 		<resource name="projects">
 		    <contract>
 		      <get>
-		          <bind text="parent.model.projects" />
+		          <bind bind="parent.model.projects" />
 		      </get>
 		      <post>
-		          <bind text="parent.model.CreateProject($form)">
-		              <var name="form" text="request"/>
+		          <bind bind="parent.model.CreateProject($form)">
+		              <var name="form" bind="request"/>
 		          </bind>
+		          <response xsi:type="redirectResponse">
+		              <locatorRef ref="relative-locator"/>
+		          </response>
 		      </post>
 		    </contract>
+		    
+		    <resource match="(\w+)">
+		    
+		    </resource>
 		</resource>
 	</root>
 	<typeMap>
-		<item></item>
-		<item></item>
 	</typeMap>
 	<locators>
-		<locator name="relative">
-			<var name="id" text="model.id" />
-			<var name="parent" text="parent.location" />
+		<locator name="relative-locator">
+			<var name="id" bind="model.id" />
+			<var name="parent" bind="parent.location" />
 			<template>$parent/$id</template>
 		</locator>
-		<locator name="projects">
-			<var name="id" text="model.id" />
-			<var name="projects" text="application.locate('projects')" />
+		<locator name="projects-locator">
+			<var name="id" bind="model.id" />
+			<var name="projects" bind="application.locate('projects')" />
 			<template>$projects/$id</template>
 		</locator>
 	</locators>