cpee-resources 1.0.2 → 1.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +6 -0
- data/cpee-resources.gemspec +1 -1
- data/lib/cpee-resources/implementation.rb +210 -32
- data/lib/cpee-resources/implementation.xml +85 -14
- data/server/data/modifiers/01_Model%20Type/01_Signavio%20BPMN2/patch.xml +3 -3
- data/server/data/modifiers/01_Model%20Type/02_ChatGPT%20Mermaid/patch.xml +1 -1
- data/server/data/modifiers/01_Model%20Type/03_ChatGPT%20Graphviz/patch.xml +1 -1
- data/server/resources +7 -2
- metadata +3 -6
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: c8bdbb327f22bad0692cac431a470706786274b71d0adf951eef431943baf086
|
|
4
|
+
data.tar.gz: 92e6e1db36d873ba1ea0d73311ec938a3e59f4b01b994310be2f114b09683db0
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 62ccf144e75434cf153209fde94e34483690d1a6f103e04b06c7e01c9805b294d94b15f8d6a4d453be985de8bbae73cafd60a5529a1411b519a95a7bae94d551
|
|
7
|
+
data.tar.gz: 55bf1bd602615f1dd360062ce6b54a72bc00b3688a6e99c7e7f0ec05280d4312da461e44d737d170c039aa38c82d62d0fe9498c872dd13dd7acbe980f24e7e60
|
data/README.md
CHANGED
data/cpee-resources.gemspec
CHANGED
|
@@ -16,72 +16,204 @@
|
|
|
16
16
|
# along with CPEE-RESOURCES (file LICENSE in the main directory). If not, see
|
|
17
17
|
# <http://www.gnu.org/licenses/>.
|
|
18
18
|
|
|
19
|
-
require '
|
|
19
|
+
require 'json'
|
|
20
20
|
require 'riddl/server'
|
|
21
21
|
|
|
22
22
|
module CPEE
|
|
23
23
|
module Resources
|
|
24
24
|
|
|
25
25
|
SERVER = File.expand_path(File.join(__dir__,'implementation.xml'))
|
|
26
|
+
NOT_FOUND = 'Existence really is an imperfect tense that never becomes a present. (Friedrich Nietzsche)'
|
|
26
27
|
|
|
27
|
-
class
|
|
28
|
+
class DoFile < Riddl::Implementation #{{{
|
|
28
29
|
def response
|
|
29
30
|
data = @a[1]
|
|
30
|
-
|
|
31
|
-
if
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
31
|
+
file = File.join(data,@a[0],*(@r[@a[2]].map{|e| Riddl::Protocols::Utils::escape(e)}))
|
|
32
|
+
if File.exist?(file)
|
|
33
|
+
Riddl::Parameter::Complex.new(@a[3],@a[4],File.read(file))
|
|
34
|
+
else
|
|
35
|
+
@status = 404
|
|
36
|
+
Riddl::Parameter::Complex.new('exists','text/plain',NOT_FOUND)
|
|
37
|
+
end
|
|
38
|
+
end
|
|
39
|
+
end #}}}
|
|
40
|
+
class DoPutFile < Riddl::Implementation #{{{
|
|
41
|
+
def response
|
|
42
|
+
data = @a[1]
|
|
43
|
+
name = @r[-1]
|
|
44
|
+
file = File.join(data,@a[0],Riddl::Protocols::Utils::escape(name))
|
|
45
|
+
File.open(file,'wb') do |f|
|
|
46
|
+
IO.copy_stream(@p[0].value,f)
|
|
47
|
+
end
|
|
48
|
+
nil
|
|
49
|
+
end
|
|
50
|
+
end #}}}
|
|
51
|
+
class DoPutDescription < Riddl::Implementation #{{{
|
|
52
|
+
def response
|
|
53
|
+
data = @a[1]
|
|
54
|
+
dir = File.join(data,@a[0],Riddl::Protocols::Utils::escape(@r[-3]))
|
|
55
|
+
unless Dir.exist?(dir)
|
|
56
|
+
@status = 404
|
|
57
|
+
return Riddl::Parameter::Complex.new('exists','text/plain',NOT_FOUND)
|
|
58
|
+
end
|
|
59
|
+
ddir = File.join(dir,'descriptions')
|
|
60
|
+
Dir.mkdir(ddir) unless Dir.exist?(ddir)
|
|
61
|
+
File.open(File.join(ddir,@r[-1]),'wb') do |f|
|
|
62
|
+
IO.copy_stream(@p[0].value,f)
|
|
63
|
+
end
|
|
64
|
+
nil
|
|
65
|
+
end
|
|
66
|
+
end #}}}
|
|
67
|
+
class DoPutEndpointFile < Riddl::Implementation #{{{
|
|
68
|
+
def response
|
|
69
|
+
data = @a[1]
|
|
70
|
+
dir = File.join(data,@a[0],Riddl::Protocols::Utils::escape(@r[-2]))
|
|
71
|
+
file = File.join(dir,@r[-1])
|
|
72
|
+
unless Dir.exist?(dir)
|
|
73
|
+
@status = 404
|
|
74
|
+
return Riddl::Parameter::Complex.new('exists','text/plain',NOT_FOUND)
|
|
75
|
+
end
|
|
76
|
+
if @p[0].name == 'name'
|
|
77
|
+
target = File.join('..','..',@a[2],@p[0].value)
|
|
78
|
+
unless File.exist?(File.join(dir,target))
|
|
79
|
+
@status = 404
|
|
80
|
+
return Riddl::Parameter::Complex.new('exists','text/plain',NOT_FOUND)
|
|
38
81
|
end
|
|
82
|
+
File.unlink(file) if File.symlink?(file) || File.exist?(file)
|
|
83
|
+
File.symlink(target,file)
|
|
84
|
+
else
|
|
85
|
+
File.unlink(file) if File.symlink?(file)
|
|
86
|
+
File.open(file,'wb') do |f|
|
|
87
|
+
IO.copy_stream(@p[0].value,f)
|
|
88
|
+
end
|
|
89
|
+
end
|
|
90
|
+
nil
|
|
91
|
+
end
|
|
92
|
+
end #}}}
|
|
93
|
+
class DoDeleteFile < Riddl::Implementation #{{{
|
|
94
|
+
def response
|
|
95
|
+
data = @a[1]
|
|
96
|
+
file = File.join(data,@a[0],*(@r[@a[2]].map{|e| Riddl::Protocols::Utils::escape(e)}))
|
|
97
|
+
if File.exist?(file) || File.symlink?(file)
|
|
98
|
+
File.delete(file)
|
|
99
|
+
nil
|
|
39
100
|
else
|
|
40
101
|
@status = 404
|
|
41
|
-
Riddl::Parameter::Complex.new('exists','text/plain',
|
|
102
|
+
Riddl::Parameter::Complex.new('exists','text/plain',NOT_FOUND)
|
|
42
103
|
end
|
|
43
104
|
end
|
|
44
105
|
end #}}}
|
|
45
|
-
class
|
|
106
|
+
class DoProperties < Riddl::Implementation #{{{
|
|
46
107
|
def response
|
|
47
108
|
data = @a[1]
|
|
48
|
-
dir = File.join(data
|
|
109
|
+
dir = File.join(data,@a[0],Riddl::Protocols::Utils::escape(@r[-2]))
|
|
110
|
+
file = File.join(dir,'properties.json')
|
|
49
111
|
if Dir.exist?(dir)
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
doc.root.add('condition','condition.json') if File.exist?(File.join(dir,'condition.json'))
|
|
55
|
-
doc.root.add('ui','ui.rng') if File.exist?(File.join(dir,'ui.rng'))
|
|
56
|
-
doc.to_s
|
|
57
|
-
end
|
|
112
|
+
props = File.exist?(file) ? JSON.parse(File.read(file)) : {}
|
|
113
|
+
props['global-schema'] = File.symlink?(File.join(dir,'schema.rng'))
|
|
114
|
+
props['global-symbol'] = File.symlink?(File.join(dir,'symbol.svg'))
|
|
115
|
+
Riddl::Parameter::Complex.new('json','application/json',JSON.generate(props))
|
|
58
116
|
else
|
|
59
117
|
@status = 404
|
|
60
|
-
Riddl::Parameter::Complex.new('exists','text/plain',
|
|
118
|
+
Riddl::Parameter::Complex.new('exists','text/plain',NOT_FOUND)
|
|
61
119
|
end
|
|
62
120
|
end
|
|
63
121
|
end #}}}
|
|
64
|
-
class
|
|
122
|
+
class DoGetProperty < Riddl::Implementation #{{{
|
|
65
123
|
def response
|
|
66
124
|
data = @a[1]
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
125
|
+
dir = File.join(data,@a[0],Riddl::Protocols::Utils::escape(@r[-3]))
|
|
126
|
+
file = File.join(dir,'properties.json')
|
|
127
|
+
key = @r[-1]
|
|
128
|
+
props = File.exist?(file) ? JSON.parse(File.read(file)) : {}
|
|
129
|
+
props['global-schema'] = File.symlink?(File.join(dir,'schema.rng'))
|
|
130
|
+
props['global-symbol'] = File.symlink?(File.join(dir,'symbol.svg'))
|
|
131
|
+
if Dir.exist?(dir) && props.key?(key)
|
|
132
|
+
Riddl::Parameter::Complex.new('value','text/plain',props[key].to_s)
|
|
133
|
+
else
|
|
134
|
+
@status = 404
|
|
135
|
+
Riddl::Parameter::Complex.new('exists','text/plain',NOT_FOUND)
|
|
136
|
+
end
|
|
137
|
+
end
|
|
138
|
+
end #}}}
|
|
139
|
+
class DoPutProperty < Riddl::Implementation #{{{
|
|
140
|
+
def response
|
|
141
|
+
data = @a[1]
|
|
142
|
+
dir = File.join(data,@a[0],Riddl::Protocols::Utils::escape(@r[-3]))
|
|
143
|
+
file = File.join(dir,'properties.json')
|
|
144
|
+
key = @r[-1]
|
|
145
|
+
unless Dir.exist?(dir)
|
|
146
|
+
@status = 404
|
|
147
|
+
return Riddl::Parameter::Complex.new('exists','text/plain',NOT_FOUND)
|
|
148
|
+
end
|
|
149
|
+
props = File.exist?(file) && !File.read(file).strip.empty? ? JSON.parse(File.read(file)) : {}
|
|
150
|
+
props[key] = @p[0].value
|
|
151
|
+
File.write(file,JSON.pretty_generate(props))
|
|
152
|
+
nil
|
|
153
|
+
end
|
|
154
|
+
end #}}}
|
|
155
|
+
class DoDeleteProperty < Riddl::Implementation #{{{
|
|
156
|
+
def response
|
|
157
|
+
data = @a[1]
|
|
158
|
+
dir = File.join(data,@a[0],Riddl::Protocols::Utils::escape(@r[-3]))
|
|
159
|
+
file = File.join(dir,'properties.json')
|
|
160
|
+
key = @r[-1]
|
|
161
|
+
props = File.exist?(file) ? JSON.parse(File.read(file)) : {}
|
|
162
|
+
if props.key?(key)
|
|
163
|
+
props.delete(key)
|
|
164
|
+
File.write(file,JSON.pretty_generate(props))
|
|
165
|
+
nil
|
|
70
166
|
else
|
|
71
167
|
@status = 404
|
|
72
|
-
Riddl::Parameter::Complex.new('exists','text/plain',
|
|
168
|
+
Riddl::Parameter::Complex.new('exists','text/plain',NOT_FOUND)
|
|
73
169
|
end
|
|
74
170
|
end
|
|
75
171
|
end #}}}
|
|
172
|
+
class DoNewEndpoint < Riddl::Implementation #{{{
|
|
173
|
+
def response
|
|
174
|
+
data = @a[1]
|
|
175
|
+
dir = File.join(data,@a[0],Riddl::Protocols::Utils::escape(@p[0].value))
|
|
176
|
+
Dir.mkdir(dir)
|
|
177
|
+
File.write(File.join(dir,'properties.json'),'{}')
|
|
178
|
+
@status = 201
|
|
179
|
+
nil
|
|
180
|
+
rescue Errno::EEXIST
|
|
181
|
+
@status = 409
|
|
182
|
+
Riddl::Parameter::Complex.new('exists','text/plain','Endpoint already exists.')
|
|
183
|
+
end
|
|
184
|
+
end #}}}
|
|
76
185
|
class DoList < Riddl::Implementation #{{{
|
|
186
|
+
def response
|
|
187
|
+
data = @a[1]
|
|
188
|
+
@a[2] ||= 0...0
|
|
189
|
+
dir = File.join(data,@a[0],*(@r[@a[2]].map{|e| Riddl::Protocols::Utils::escape(e)}))
|
|
190
|
+
if @a[3] && !Dir.exist?(dir)
|
|
191
|
+
@status = 404
|
|
192
|
+
return Riddl::Parameter::Complex.new('exists','text/plain',NOT_FOUND)
|
|
193
|
+
end
|
|
194
|
+
return Riddl::Parameter::Complex.new('list','text/xml') do
|
|
195
|
+
doc = XML::Smart::string('<resources/>')
|
|
196
|
+
names = Dir.glob(File.join(dir,'*')).map{ |f| File.basename(f) } | (@a[5] || [])
|
|
197
|
+
names.sort.each do |n|
|
|
198
|
+
next if @a[4] && !@a[4].include?(n)
|
|
199
|
+
doc.root.add('resource',n)
|
|
200
|
+
end
|
|
201
|
+
doc.to_s
|
|
202
|
+
end
|
|
203
|
+
end
|
|
204
|
+
end #}}}
|
|
205
|
+
class DoDescList < Riddl::Implementation #{{{
|
|
77
206
|
def response
|
|
78
207
|
data = @a[1]
|
|
79
208
|
@a[2] ||= 0...0
|
|
80
209
|
dir = File.join(data,@a[0],*(@r[@a[2]].map{|e| Riddl::Protocols::Utils::escape(e)}))
|
|
81
210
|
return Riddl::Parameter::Complex.new('list','text/xml') do
|
|
82
211
|
doc = XML::Smart::string('<resources/>')
|
|
83
|
-
Dir.glob(File.join(dir,'*')).
|
|
84
|
-
|
|
212
|
+
Dir.glob(File.join(dir,'*','descriptions')).each do |f|
|
|
213
|
+
n = doc.root.add('resource', 'endpoint' => File.basename(File.dirname(f)))
|
|
214
|
+
n.add('endpoint', File.read(File.join(f,'endpoint.md'))) if File.exist?(File.join(f,'endpoint.md'))
|
|
215
|
+
n.add('functionality', File.read(File.join(f,'functionality.md'))) if File.exist?(File.join(f,'functionality.md'))
|
|
216
|
+
n.add('output', File.read(File.join(f,'output.md'))) if File.exist?(File.join(f,'output.md'))
|
|
85
217
|
end
|
|
86
218
|
doc.to_s
|
|
87
219
|
end
|
|
@@ -93,12 +225,13 @@ module CPEE
|
|
|
93
225
|
|
|
94
226
|
Proc.new do
|
|
95
227
|
on resource do
|
|
228
|
+
run DoList, '', opts[:data_dir] if get
|
|
96
229
|
on resource 'modifiers' do
|
|
97
230
|
run DoList, 'modifiers', opts[:data_dir] if get
|
|
98
231
|
on resource do
|
|
99
232
|
run DoList, 'modifiers', opts[:data_dir], (-1..-1) if get
|
|
100
233
|
on resource do
|
|
101
|
-
run
|
|
234
|
+
run DoList, 'modifiers', opts[:data_dir], (-2..-1), true, %w{patch.xml unpatch.xml condition.json ui.rng} if get
|
|
102
235
|
on resource 'patch.xml' do
|
|
103
236
|
run DoFile, 'modifiers', opts[:data_dir], (-3..-1), 'testset', 'text/xml' if get
|
|
104
237
|
end
|
|
@@ -114,18 +247,63 @@ module CPEE
|
|
|
114
247
|
end
|
|
115
248
|
end
|
|
116
249
|
end
|
|
250
|
+
on resource 'symbols' do
|
|
251
|
+
run DoList, 'symbols', opts[:data_dir] if get
|
|
252
|
+
on resource '[a-z][a-zA-Z0-9_-]*\.svg' do
|
|
253
|
+
run DoFile, 'symbols', opts[:data_dir], (-1..-1), 'svg', 'image/svg+xml' if get
|
|
254
|
+
run DoPutFile, 'symbols', opts[:data_dir] if put 'symbol'
|
|
255
|
+
run DoDeleteFile, 'symbols', opts[:data_dir], (-1..-1) if delete
|
|
256
|
+
end
|
|
257
|
+
end
|
|
258
|
+
on resource 'schemas' do
|
|
259
|
+
run DoList, 'schemas', opts[:data_dir] if get
|
|
260
|
+
on resource '[a-z][a-zA-Z0-9_-]*\.rng' do
|
|
261
|
+
run DoFile, 'schemas', opts[:data_dir], (-1..-1), 'rng', 'text/xml' if get
|
|
262
|
+
run DoPutFile, 'schemas', opts[:data_dir] if put 'schema'
|
|
263
|
+
run DoDeleteFile, 'schemas', opts[:data_dir], (-1..-1) if delete
|
|
264
|
+
end
|
|
265
|
+
end
|
|
117
266
|
on resource 'endpoints' do
|
|
267
|
+
run DoDescList, 'endpoints', opts[:data_dir] if get 'dfilter'
|
|
118
268
|
run DoList, 'endpoints', opts[:data_dir] if get
|
|
269
|
+
run DoNewEndpoint, 'endpoints', opts[:data_dir] if post 'endpoint'
|
|
119
270
|
on resource do
|
|
120
|
-
run
|
|
271
|
+
run DoList, 'endpoints', opts[:data_dir], (-1..-1), true, %w{schema.rng symbol.svg properties.json descriptions}, %w{properties.json} if get
|
|
121
272
|
on resource 'symbol.svg' do
|
|
122
273
|
run DoFile, 'endpoints', opts[:data_dir], (-2..-1), 'svg', 'image/svg+xml' if get
|
|
274
|
+
run DoPutEndpointFile, 'endpoints', opts[:data_dir], 'symbols' if put 'endpoint-symbol'
|
|
275
|
+
run DoDeleteFile, 'endpoints', opts[:data_dir], (-2..-1) if delete
|
|
123
276
|
end
|
|
124
277
|
on resource 'schema.rng' do
|
|
125
278
|
run DoFile, 'endpoints', opts[:data_dir], (-2..-1), 'rng', 'text/xml' if get
|
|
279
|
+
run DoPutEndpointFile, 'endpoints', opts[:data_dir], 'schemas' if put 'endpoint-schema'
|
|
280
|
+
run DoDeleteFile, 'endpoints', opts[:data_dir], (-2..-1) if delete
|
|
126
281
|
end
|
|
127
282
|
on resource 'properties.json' do
|
|
128
|
-
run
|
|
283
|
+
run DoProperties, 'endpoints', opts[:data_dir] if get
|
|
284
|
+
on resource do
|
|
285
|
+
run DoGetProperty, 'endpoints', opts[:data_dir] if get
|
|
286
|
+
run DoPutProperty, 'endpoints', opts[:data_dir] if put 'property'
|
|
287
|
+
run DoDeleteProperty, 'endpoints', opts[:data_dir] if delete
|
|
288
|
+
end
|
|
289
|
+
end
|
|
290
|
+
on resource 'descriptions' do
|
|
291
|
+
run DoList, 'endpoints', opts[:data_dir], (-2..-1), true, %w{functionality.md output.md endpoint.md} if get
|
|
292
|
+
on resource 'functionality.md' do
|
|
293
|
+
run DoFile, 'endpoints', opts[:data_dir], (-3..-1), 'markdown', 'text/markdown' if get
|
|
294
|
+
run DoPutDescription, 'endpoints', opts[:data_dir] if put 'description-file'
|
|
295
|
+
run DoDeleteFile, 'endpoints', opts[:data_dir], (-3..-1) if delete
|
|
296
|
+
end
|
|
297
|
+
on resource 'output.md' do
|
|
298
|
+
run DoFile, 'endpoints', opts[:data_dir], (-3..-1), 'markdown', 'text/markdown' if get
|
|
299
|
+
run DoPutDescription, 'endpoints', opts[:data_dir] if put 'description-file'
|
|
300
|
+
run DoDeleteFile, 'endpoints', opts[:data_dir], (-3..-1) if delete
|
|
301
|
+
end
|
|
302
|
+
on resource 'endpoint.md' do
|
|
303
|
+
run DoFile, 'endpoints', opts[:data_dir], (-3..-1), 'markdown', 'text/markdown' if get
|
|
304
|
+
run DoPutDescription, 'endpoints', opts[:data_dir] if put 'description-file'
|
|
305
|
+
run DoDeleteFile, 'endpoints', opts[:data_dir], (-3..-1) if delete
|
|
306
|
+
end
|
|
129
307
|
end
|
|
130
308
|
end
|
|
131
309
|
end
|
|
@@ -17,14 +17,14 @@
|
|
|
17
17
|
-->
|
|
18
18
|
|
|
19
19
|
<description xmlns="http://riddl.org/ns/description/1.0" xmlns:ann="http://riddl.org/ns/annotation/1.0" xmlns:xi="http://www.w3.org/2001/XInclude" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
|
|
20
|
+
<message name="dfilter">
|
|
21
|
+
<parameter name="description" type="string"/>
|
|
22
|
+
</message>
|
|
20
23
|
<message name="list">
|
|
21
24
|
<parameter name="list" mimetype="*/xml"/>
|
|
22
25
|
</message>
|
|
23
|
-
<message name="
|
|
24
|
-
<
|
|
25
|
-
<parameter name="exists" mimetype="*/xml"/>
|
|
26
|
-
<parameter name="exists" mimetype="text/plain"/>
|
|
27
|
-
</choice>
|
|
26
|
+
<message name="endpoint">
|
|
27
|
+
<parameter name="name" type="string"/>
|
|
28
28
|
</message>
|
|
29
29
|
<message name="testset">
|
|
30
30
|
<choice>
|
|
@@ -33,15 +33,25 @@
|
|
|
33
33
|
</choice>
|
|
34
34
|
</message>
|
|
35
35
|
<message name="symbol">
|
|
36
|
+
<parameter name="*" mimetype="image/svg+xml"/>
|
|
37
|
+
</message>
|
|
38
|
+
<message name="schema">
|
|
39
|
+
<parameter name="*" mimetype="*/xml"/>
|
|
40
|
+
</message>
|
|
41
|
+
<message name="endpoint-symbol">
|
|
36
42
|
<choice>
|
|
37
|
-
<parameter name="
|
|
38
|
-
<parameter name="
|
|
43
|
+
<parameter name="file" mimetype="image/svg+xml"/>
|
|
44
|
+
<parameter name="name" type="string">
|
|
45
|
+
<param name="pattern">[a-z][a-zA-Z0-9_-]*\.svg</param>
|
|
46
|
+
</parameter>
|
|
39
47
|
</choice>
|
|
40
48
|
</message>
|
|
41
|
-
<message name="schema">
|
|
49
|
+
<message name="endpoint-schema">
|
|
42
50
|
<choice>
|
|
43
|
-
<parameter name="
|
|
44
|
-
<parameter name="
|
|
51
|
+
<parameter name="file" mimetype="*/xml"/>
|
|
52
|
+
<parameter name="name" type="string">
|
|
53
|
+
<param name="pattern">[a-z][a-zA-Z0-9_-]*\.rng</param>
|
|
54
|
+
</parameter>
|
|
45
55
|
</choice>
|
|
46
56
|
</message>
|
|
47
57
|
<message name="json">
|
|
@@ -50,14 +60,30 @@
|
|
|
50
60
|
<parameter name="exists" mimetype="text/plain"/>
|
|
51
61
|
</choice>
|
|
52
62
|
</message>
|
|
63
|
+
<message name="property">
|
|
64
|
+
<parameter name="value" type="string"/>
|
|
65
|
+
</message>
|
|
66
|
+
<message name="property-value">
|
|
67
|
+
<parameter name="value" mimetype="text/plain"/>
|
|
68
|
+
</message>
|
|
69
|
+
<message name="markdown">
|
|
70
|
+
<choice>
|
|
71
|
+
<parameter name="markdown" mimetype="text/markdown"/>
|
|
72
|
+
<parameter name="exists" mimetype="text/plain"/>
|
|
73
|
+
</choice>
|
|
74
|
+
</message>
|
|
75
|
+
<message name="description-file">
|
|
76
|
+
<parameter name="*" mimetype="text/markdown"/>
|
|
77
|
+
</message>
|
|
53
78
|
|
|
54
79
|
<resource>
|
|
55
|
-
<
|
|
80
|
+
<get out="list"/>
|
|
81
|
+
<resource relative='modifiers'> <!--{{{-->
|
|
56
82
|
<get out="list"/>
|
|
57
83
|
<resource>
|
|
58
84
|
<get out="list"/>
|
|
59
85
|
<resource>
|
|
60
|
-
<get out="
|
|
86
|
+
<get out="list"/>
|
|
61
87
|
<resource relative="patch.xml">
|
|
62
88
|
<get out="testset"/>
|
|
63
89
|
</resource>
|
|
@@ -72,19 +98,64 @@
|
|
|
72
98
|
</resource>
|
|
73
99
|
</resource>
|
|
74
100
|
</resource>
|
|
101
|
+
</resource> <!--}}}-->
|
|
102
|
+
<resource relative='symbols'>
|
|
103
|
+
<get out="list"/>
|
|
104
|
+
<resource relative="[a-z][a-zA-Z0-9_-]*\.svg">
|
|
105
|
+
<get out="symbol"/>
|
|
106
|
+
<put in="symbol"/>
|
|
107
|
+
<delete/>
|
|
108
|
+
</resource>
|
|
75
109
|
</resource>
|
|
76
|
-
<resource relative='
|
|
110
|
+
<resource relative='schemas'>
|
|
77
111
|
<get out="list"/>
|
|
112
|
+
<resource relative="[a-z][a-zA-Z0-9_-]*\.rng">
|
|
113
|
+
<get out="schema"/>
|
|
114
|
+
<put in="schema"/>
|
|
115
|
+
<delete/>
|
|
116
|
+
</resource>
|
|
117
|
+
</resource>
|
|
118
|
+
<resource relative='endpoints'>
|
|
119
|
+
<get in="dfilter" out="list"/>
|
|
120
|
+
<get in="*" out="list"/>
|
|
121
|
+
<post in="endpoint"/>
|
|
78
122
|
<resource>
|
|
79
|
-
<get out="
|
|
123
|
+
<get out="list"/>
|
|
80
124
|
<resource relative="symbol.svg">
|
|
81
125
|
<get out="symbol"/>
|
|
126
|
+
<put in="endpoint-symbol"/>
|
|
127
|
+
<delete/>
|
|
82
128
|
</resource>
|
|
83
129
|
<resource relative="schema.rng">
|
|
84
130
|
<get out="schema"/>
|
|
131
|
+
<put in="endpoint-schema"/>
|
|
132
|
+
<delete/>
|
|
85
133
|
</resource>
|
|
86
134
|
<resource relative="properties.json">
|
|
87
135
|
<get out="json"/>
|
|
136
|
+
<resource>
|
|
137
|
+
<get out="property-value"/>
|
|
138
|
+
<put in="property"/>
|
|
139
|
+
<delete/>
|
|
140
|
+
</resource>
|
|
141
|
+
</resource>
|
|
142
|
+
<resource relative="descriptions">
|
|
143
|
+
<get out="list"/>
|
|
144
|
+
<resource relative="functionality.md">
|
|
145
|
+
<get out="markdown"/>
|
|
146
|
+
<put in="description-file"/>
|
|
147
|
+
<delete/>
|
|
148
|
+
</resource>
|
|
149
|
+
<resource relative="output.md">
|
|
150
|
+
<get out="markdown"/>
|
|
151
|
+
<put in="description-file"/>
|
|
152
|
+
<delete/>
|
|
153
|
+
</resource>
|
|
154
|
+
<resource relative="endpoint.md">
|
|
155
|
+
<get out="markdown"/>
|
|
156
|
+
<put in="description-file"/>
|
|
157
|
+
<delete/>
|
|
158
|
+
</resource>
|
|
88
159
|
</resource>
|
|
89
160
|
</resource>
|
|
90
161
|
</resource>
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
<modeltype>Signavio</modeltype>
|
|
5
5
|
</attributes>
|
|
6
6
|
<transformation>
|
|
7
|
-
<description type='rest'>http://localhost:9295/bpmn2/</description>
|
|
8
|
-
<dataelements type='rest'>http://localhost:9295/bpmn2/</dataelements>
|
|
9
|
-
<endpoints type='rest'>http://localhost:9295/bpmn2/</endpoints>
|
|
7
|
+
<description type='rest'>http://localhost:9295/cpee/bpmn2/</description>
|
|
8
|
+
<dataelements type='rest'>http://localhost:9295/cpee/bpmn2/</dataelements>
|
|
9
|
+
<endpoints type='rest'>http://localhost:9295/cpee/bpmn2/</endpoints>
|
|
10
10
|
</transformation>
|
|
11
11
|
</testset>
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
<modeltype>ChatGPT_Mermaid</modeltype>
|
|
5
5
|
</attributes>
|
|
6
6
|
<transformation>
|
|
7
|
-
<description type='rest'>http://localhost:9295/mermaid/</description>
|
|
7
|
+
<description type='rest'>http://localhost:9295/cpee/mermaid/</description>
|
|
8
8
|
<dataelements type='none'/>
|
|
9
9
|
<endpoints type='none'/>
|
|
10
10
|
</transformation>
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
<modeltype>ChatGPT_Graphviz</modeltype>
|
|
5
5
|
</attributes>
|
|
6
6
|
<transformation>
|
|
7
|
-
<description type='rest'>http://localhost:9295/graphviz/</description>
|
|
7
|
+
<description type='rest'>http://localhost:9295/cpee/graphviz/</description>
|
|
8
8
|
<dataelements type='none'/>
|
|
9
9
|
<endpoints type='none'/>
|
|
10
10
|
</transformation>
|
data/server/resources
CHANGED
|
@@ -16,8 +16,13 @@
|
|
|
16
16
|
# along with CPEE-RESOURCES (file LICENSE in the main directory). If not, see
|
|
17
17
|
# <http://www.gnu.org/licenses/>.
|
|
18
18
|
|
|
19
|
-
|
|
20
|
-
|
|
19
|
+
if File.exist?(File.join(__dir__,'..','lib','cpee-resources','implementation.rb'))
|
|
20
|
+
require_relative File.join(__dir__,'..','lib','cpee-resources','implementation')
|
|
21
|
+
elsif File.exist?(File.join(Dir.home,'Projects','cpee-resources','lib','cpee-resources','implementation.rb'))
|
|
22
|
+
require_relative File.join(Dir.home, 'Projects','cpee-resources','lib','cpee-resources','implementation')
|
|
23
|
+
else
|
|
24
|
+
require 'cpee-resources/implementation'
|
|
25
|
+
end
|
|
21
26
|
|
|
22
27
|
options = {
|
|
23
28
|
:host => 'localhost',
|
metadata
CHANGED
|
@@ -1,15 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: cpee-resources
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.0.
|
|
4
|
+
version: 1.0.4
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Juergen eTM Mangler
|
|
8
8
|
- Ralph Vigne
|
|
9
|
-
autorequire:
|
|
10
9
|
bindir: tools
|
|
11
10
|
cert_chain: []
|
|
12
|
-
date:
|
|
11
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
|
13
12
|
dependencies:
|
|
14
13
|
- !ruby/object:Gem::Dependency
|
|
15
14
|
name: riddl
|
|
@@ -132,7 +131,6 @@ homepage: http://cpee.org/
|
|
|
132
131
|
licenses:
|
|
133
132
|
- LGPL-3.0-or-later
|
|
134
133
|
metadata: {}
|
|
135
|
-
post_install_message:
|
|
136
134
|
rdoc_options: []
|
|
137
135
|
require_paths:
|
|
138
136
|
- lib
|
|
@@ -147,8 +145,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
147
145
|
- !ruby/object:Gem::Version
|
|
148
146
|
version: '0'
|
|
149
147
|
requirements: []
|
|
150
|
-
rubygems_version: 3.
|
|
151
|
-
signing_key:
|
|
148
|
+
rubygems_version: 3.6.9
|
|
152
149
|
specification_version: 4
|
|
153
150
|
summary: Resources list for the cloud process execution engine (cpee.org)
|
|
154
151
|
test_files: []
|