1 | <accessor debug="false" trace="false"> |
---|
2 | <name>ISOcat.access.data.workspace</name> |
---|
3 | <descr>Get an users workspace.</descr> |
---|
4 | <param mandatory="true"> |
---|
5 | <name>user</name> |
---|
6 | <descr>the user login</descr> |
---|
7 | <type canonical="true">string</type> |
---|
8 | </param> |
---|
9 | <param> |
---|
10 | <name>view</name> |
---|
11 | <descr>the requested view</descr> |
---|
12 | <type canonical="true">string</type> |
---|
13 | <source> |
---|
14 | <param/> |
---|
15 | <default> |
---|
16 | <string>isocat</string> |
---|
17 | </default> |
---|
18 | </source> |
---|
19 | </param> |
---|
20 | <idoc> |
---|
21 | <!-- cleanup the view name --> |
---|
22 | <instr> |
---|
23 | <type>sloot.xpath2eval</type> |
---|
24 | <operand>var:view</operand> |
---|
25 | <operator> |
---|
26 | <xpath>translate(.,'+',' ')</xpath> |
---|
27 | </operator> |
---|
28 | <param> |
---|
29 | <return> |
---|
30 | <canonical/> |
---|
31 | <string/> |
---|
32 | </return> |
---|
33 | </param> |
---|
34 | <target>var:view</target> |
---|
35 | </instr> |
---|
36 | <accessor-debug> |
---|
37 | <instr> |
---|
38 | <type>sloot.log</type> |
---|
39 | <operator> |
---|
40 | <dbg>DBG: workspace user[{string($user)}]</dbg> |
---|
41 | </operator> |
---|
42 | <user>var:user</user> |
---|
43 | </instr> |
---|
44 | <instr> |
---|
45 | <type>copy</type> |
---|
46 | <operand>var:user</operand> |
---|
47 | <target>ffcpl:/trace/workspace.user.xml</target> |
---|
48 | </instr> |
---|
49 | <instr> |
---|
50 | <type>sloot.log</type> |
---|
51 | <operator> |
---|
52 | <dbg>DBG: workspace view[{string($view)}]</dbg> |
---|
53 | </operator> |
---|
54 | <view>var:view</view> |
---|
55 | </instr> |
---|
56 | <instr> |
---|
57 | <type>copy</type> |
---|
58 | <operand>var:view</operand> |
---|
59 | <target>ffcpl:/trace/workspace.view.xml</target> |
---|
60 | </instr> |
---|
61 | </accessor-debug> |
---|
62 | <accessor-trace name="DBX"> |
---|
63 | <instr> |
---|
64 | <type>sloot.dbx</type> |
---|
65 | <login>var:user</login> |
---|
66 | <view>var:view</view> |
---|
67 | <operator>ffcpl:/dbx/user-workspace.xml</operator> |
---|
68 | <props>active:ISOcat.manage.system.properties</props> |
---|
69 | <debug>var:accessor-debug</debug> |
---|
70 | <target>this:response</target> |
---|
71 | </instr> |
---|
72 | </accessor-trace> |
---|
73 | <!-- get the uid --> |
---|
74 | <instr> |
---|
75 | <type>ISOcat.access.data.user.id</type> |
---|
76 | <user>var:user</user> |
---|
77 | <target>var:uid</target> |
---|
78 | </instr> |
---|
79 | <!-- attach the golden thread of the user's WS --> |
---|
80 | <accessor-trace name="GT"> |
---|
81 | <instr> |
---|
82 | <type>sloot.xquery</type> |
---|
83 | <operator> |
---|
84 | <xquery> |
---|
85 | declare variable $uid as node() external; |
---|
86 | |
---|
87 | <string>goldenthread:/user/{string($uid)}/workspace</string> |
---|
88 | </xquery> |
---|
89 | </operator> |
---|
90 | <uid>var:uid</uid> |
---|
91 | <target>var:thread</target> |
---|
92 | </instr> |
---|
93 | <instr> |
---|
94 | <type>sloot.attachGoldenThread</type> |
---|
95 | <operand>this:response</operand> |
---|
96 | <param>var:thread</param> |
---|
97 | <target>this:response</target> |
---|
98 | </instr> |
---|
99 | </accessor-trace> |
---|
100 | </idoc> |
---|
101 | <exception> |
---|
102 | <debug/> |
---|
103 | <trace>ffcpl:/trace/workspace.exception.xml</trace> |
---|
104 | <throw/> |
---|
105 | </exception> |
---|
106 | <response> |
---|
107 | <debug>ffcpl:/trace/workspace.response.xml</debug> |
---|
108 | <validate> |
---|
109 | <schema>active:ISOcat.manage.dm.user.workspace.schema</schema> |
---|
110 | <invalid> |
---|
111 | <trace>ffcpl:/trace/workspace.response.invalid.xml</trace> |
---|
112 | <log>ERR:.....:ISOcat.access.data.workspace: the workspace response is invalid!</log> |
---|
113 | </invalid> |
---|
114 | </validate> |
---|
115 | <mime>application/xml</mime> |
---|
116 | </response> |
---|
117 | </accessor> |
---|