open_bd 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/lib/open_bd/{content.rb → contents.rb} +3 -3
- data/lib/open_bd/resource.rb +9 -9
- data/lib/open_bd/version.rb +1 -1
- data/lib/open_bd.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 568e64b7433254518a824b5c6f534f590f247a7e
|
4
|
+
data.tar.gz: 82f1b64a62d30c5d3315b898d48be48bab819c04
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f923bd638c13219a44bf73c9aa9de052abc4eb86d9efab7406e64f3baa5f84bc6a9e2fcd62bc43b47e56725d490925a1e9e44af63ff4d3a3032a78bcb6533acd
|
7
|
+
data.tar.gz: 5af5cab38bb2411aebd96458eb765d9b1703d835ab94f6b5104ae430f4f30e2064aaf940a6844ba0f6a5e10cf52c2e9f39629d2995ce8c941fdbc108c062e2ac
|
data/README.md
CHANGED
@@ -1,19 +1,19 @@
|
|
1
1
|
module OpenBD
|
2
|
-
class
|
2
|
+
class Contents
|
3
3
|
attr_reader :source
|
4
4
|
|
5
5
|
def initialize(source)
|
6
6
|
@source = source
|
7
7
|
end
|
8
8
|
|
9
|
-
def
|
9
|
+
def contents
|
10
10
|
value = source.find { |x| x["TextType"] == "02" }
|
11
11
|
if !value.nil?
|
12
12
|
value["Text"]
|
13
13
|
end
|
14
14
|
end
|
15
15
|
|
16
|
-
def
|
16
|
+
def contents_detail
|
17
17
|
value = source.find { |x| x["TextType"] == "03" }
|
18
18
|
if !value.nil?
|
19
19
|
value["Text"]
|
data/lib/open_bd/resource.rb
CHANGED
@@ -6,15 +6,15 @@ module OpenBD
|
|
6
6
|
@source = source
|
7
7
|
end
|
8
8
|
|
9
|
-
def
|
10
|
-
if !
|
11
|
-
|
9
|
+
def contents
|
10
|
+
if !contents_source.nil?
|
11
|
+
Contents.new(contents_source).contents
|
12
12
|
end
|
13
13
|
end
|
14
14
|
|
15
|
-
def
|
16
|
-
if !
|
17
|
-
|
15
|
+
def contents_detail
|
16
|
+
if !contents_source.nil?
|
17
|
+
Contents.new(contents_source).contents_detail
|
18
18
|
end
|
19
19
|
end
|
20
20
|
|
@@ -62,8 +62,8 @@ module OpenBD
|
|
62
62
|
end
|
63
63
|
|
64
64
|
def table_of_contents
|
65
|
-
if !
|
66
|
-
|
65
|
+
if !contents_source.nil?
|
66
|
+
Contents.new(contents_source).table_of_contents
|
67
67
|
end
|
68
68
|
end
|
69
69
|
|
@@ -77,7 +77,7 @@ module OpenBD
|
|
77
77
|
|
78
78
|
private
|
79
79
|
|
80
|
-
def
|
80
|
+
def contents_source
|
81
81
|
source.dig("onix", "CollateralDetail", "TextContent")
|
82
82
|
end
|
83
83
|
end
|
data/lib/open_bd/version.rb
CHANGED
data/lib/open_bd.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: open_bd
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- ryosuke-endo
|
@@ -98,7 +98,7 @@ files:
|
|
98
98
|
- bin/setup
|
99
99
|
- lib/open_bd.rb
|
100
100
|
- lib/open_bd/client.rb
|
101
|
-
- lib/open_bd/
|
101
|
+
- lib/open_bd/contents.rb
|
102
102
|
- lib/open_bd/contributor.rb
|
103
103
|
- lib/open_bd/paper.rb
|
104
104
|
- lib/open_bd/resource.rb
|