lutaml-express 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/lutaml/express.rb +0 -1
- data/lib/lutaml/express/version.rb +1 -1
- metadata +2 -3
- data/lib/lutaml/express/lutaml_path/document_wrapper.rb +0 -37
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f34f7644f589ec8fee5d8d08c8bc1a94b9633b9981c86e786f0d01175d583daf
|
4
|
+
data.tar.gz: 3b2ea7c09bd9021152b855a69a61fc8330162c745ec1f18f23bbe8733d44b6b6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a79138319ca3b397630ef34b0bd5e9841258eb2b7f51258b79aed99894aa7fe1351877d5c3b377b4e9a795ddcb7c7d88dbf3ab6bb0e923264ab3690a8a1cf7b2
|
7
|
+
data.tar.gz: 571a88b4784eefc9e24ce2e23886d15d2fdde06c6b986a1b6da55e3924113f3ef6738d698d485f1e3ba91fc917180586d6659b67052be652a05204d165964d08
|
data/lib/lutaml/express.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lutaml-express
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-11-
|
11
|
+
date: 2020-11-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: expressir
|
@@ -126,7 +126,6 @@ files:
|
|
126
126
|
- bin/console
|
127
127
|
- bin/setup
|
128
128
|
- lib/lutaml/express.rb
|
129
|
-
- lib/lutaml/express/lutaml_path/document_wrapper.rb
|
130
129
|
- lib/lutaml/express/parsers/exp.rb
|
131
130
|
- lib/lutaml/express/version.rb
|
132
131
|
- lutaml-express.gemspec
|
@@ -1,37 +0,0 @@
|
|
1
|
-
require 'lutaml/lutaml_path/document_wrapper'
|
2
|
-
|
3
|
-
module Lutaml
|
4
|
-
module Express
|
5
|
-
module LutamlPath
|
6
|
-
class DocumentWrapper < ::Lutaml::LutamlPath::DocumentWrapper
|
7
|
-
SCHEMA_ATTRIBUTES = %w[
|
8
|
-
id
|
9
|
-
constants
|
10
|
-
declarations
|
11
|
-
entities
|
12
|
-
functions
|
13
|
-
interfaces
|
14
|
-
procedures
|
15
|
-
rules
|
16
|
-
subtype_constraints
|
17
|
-
types
|
18
|
-
version
|
19
|
-
].freeze
|
20
|
-
|
21
|
-
protected
|
22
|
-
|
23
|
-
def serialize_document(repository)
|
24
|
-
repository.schemas.each_with_object({}) do |schema, res|
|
25
|
-
res['schemas'] ||= []
|
26
|
-
serialized_schema = SCHEMA_ATTRIBUTES.each_with_object({}) do |name, nested_res|
|
27
|
-
attr_value = schema.send(name)
|
28
|
-
nested_res[name] = serialize_value(attr_value)
|
29
|
-
end
|
30
|
-
res[schema.id] = serialized_schema
|
31
|
-
res['schemas'].push(serialized_schema)
|
32
|
-
end
|
33
|
-
end
|
34
|
-
end
|
35
|
-
end
|
36
|
-
end
|
37
|
-
end
|