equal
deleted
inserted
replaced
14 variable "project", "ns:GetProject()"; |
14 variable "project", "ns:GetProject()"; |
15 |
15 |
16 variable "stdlib", "ns:GetStdLibs()"; |
16 variable "stdlib", "ns:GetStdLibs()"; |
17 |
17 |
18 variable "extensions", "ns:GetExtensions()"; |
18 variable "extensions", "ns:GetExtensions()"; |
|
19 |
|
20 variable "all", "$project | $stdlib | $extensions"; |
19 |
21 |
20 function "add_root" { |
22 function "add_root" { |
21 param "class"; |
23 param "class"; |
22 param "type"; |
24 param "type"; |
23 param "edit" > true |
25 param "edit" > true |
169 } |
171 } |
170 |
172 |
171 template "*[self::ppx:type or self::ppx:baseType]/ppx:derived", mode="var_class" { |
173 template "*[self::ppx:type or self::ppx:baseType]/ppx:derived", mode="var_class" { |
172 param "default_class"; |
174 param "default_class"; |
173 variable "type_name", "@name"; |
175 variable "type_name", "@name"; |
174 variable "pou_infos", "($project|$stdlib|$extensions)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name]"; |
176 variable "pou_infos", "$all/ppx:types/ppx:pous/ppx:pou[@name=$type_name]"; |
175 choose { |
177 choose { |
176 when "$pou_infos" { |
178 when "$pou_infos" { |
177 apply "$pou_infos", mode="var_class"; |
179 apply "$pou_infos", mode="var_class"; |
178 } |
180 } |
179 otherwise { |
181 otherwise { |
216 > «local-name()» |
218 > «local-name()» |
217 } |
219 } |
218 |
220 |
219 template "*[self::ppx:type or self::ppx:baseType]/ppx:derived", mode="var_edit" { |
221 template "*[self::ppx:type or self::ppx:baseType]/ppx:derived", mode="var_edit" { |
220 variable "type_name", "@name"; |
222 variable "type_name", "@name"; |
221 variable "pou_infos", "$project/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name]"; |
223 variable "pou_infos", "$project/ppx:types/ppx:pous/ppx:pou[@name=$type_name]"; |
222 choose { |
224 choose { |
223 when "$pou_infos" > true |
225 when "$pou_infos" > true |
224 otherwise > false |
226 otherwise > false |
225 } |
227 } |
226 } |
228 } |
233 > false |
235 > false |
234 } |
236 } |
235 |
237 |
236 template "*[self::ppx:type or self::ppx:baseType]/ppx:derived", mode="var_debug" { |
238 template "*[self::ppx:type or self::ppx:baseType]/ppx:derived", mode="var_debug" { |
237 variable "type_name", "@name"; |
239 variable "type_name", "@name"; |
238 variable "datatype_infos", "($project|$stdlib|$extensions)/ppx:project/ppx:types/ppx:pous/ppx:pou[@name=$type_name]"; |
240 variable "datatype_infos", """ |
|
241 $project/ppx:types/ppx:pous/ppx:pou[@name=$type_name] | |
|
242 $all/ppx:types/ppx:dataTypes/ppx:dataType[@name=$type_name] |
|
243 """; |
239 choose { |
244 choose { |
240 when "$datatype_infos != ''" { |
245 when "$datatype_infos" { |
241 apply "$datatype_infos", mode="var_debug"; |
246 apply "$datatype_infos", mode="var_debug"; |
242 } |
247 } |
243 otherwise > false |
248 otherwise > false |
244 } |
249 } |
245 } |
250 } |