sec_entities 0.0.2 → 0.0.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/README.md +4 -4
- data/lib/sec_entities/entity.rb +3 -3
- data/lib/sec_entities/version.rb +1 -1
- data/pkg/sec_entities-0.0.2.gem +0 -0
- metadata +2 -1
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
YjRmNGY5ZTA0ZTA5ODAzZmVmOWI0ZGM5YTEzZGRiOGM1MDlhMzNhZQ==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
NGVjOGM5YjlmMGNhMTc4MDM5NDY3ZjQxYjgzODMyOTc3YWZkZDQzYQ==
|
7
7
|
!binary "U0hBNTEy":
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
NmI4NDQ4OWZjMjljNTc1NDQwNDZjMTk1NjA2NjY5ZDcyZGFiZWM5ZWI4YWQz
|
10
|
+
OGZkNGM1YWNkMGU2ZjA5ZDRiNmRjODEwOGNmOGQ2ODgzOWUwZDRmZDE5Y2Yw
|
11
|
+
NGM3MTI0MTg4NDJhOWJlNjUzZWRmY2EyMzEyOGM0MDVlZjIwMjU=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
YWE1ODQ1YTAzOWZmYzRkNDI4MjIxMWJhZmI1ZTIyYjA2Y2Y1MWRkY2QwMzBj
|
14
|
+
YTI4ZjgwNTdmMmQ3Zjg2ZjY2OGQ1MjMxN2ZlYzhlMzA1ZDU2MGRhYWY0YjVj
|
15
|
+
YzkzNzE2N2ExNDlhMzA4MTRjMGZjZDJlNmUwYTFmMGUyMWI5ZDA=
|
data/README.md
CHANGED
@@ -8,15 +8,15 @@ If I can get the other one to work eventually, I'll retire this one.
|
|
8
8
|
|
9
9
|
## Installation
|
10
10
|
|
11
|
-
To install the '
|
11
|
+
To install the 'sec_entities' Ruby Gem run the following command at the terminal prompt.
|
12
12
|
|
13
13
|
`gem install sec_entities`
|
14
14
|
|
15
|
-
For an example of what type of information '
|
15
|
+
For an example of what type of information 'sec_entities' can retrieve, run the following command:
|
16
16
|
|
17
17
|
`bundle exec rspec spec`
|
18
18
|
|
19
|
-
If running '
|
19
|
+
If running 'sec_entities' from the command prompt in irb:
|
20
20
|
|
21
21
|
`irb -rubygems`
|
22
22
|
|
@@ -28,7 +28,7 @@ If running 'sec_query' from the command prompt in irb:
|
|
28
28
|
|
29
29
|
#### By Name:
|
30
30
|
|
31
|
-
Sec::Entity.find("
|
31
|
+
Sec::Entity.find("WEYERHAUSER")
|
32
32
|
|
33
33
|
|
34
34
|
## License
|
data/lib/sec_entities/entity.rb
CHANGED
@@ -54,13 +54,13 @@ module Sec
|
|
54
54
|
Nokogiri::HTML(response).xpath('//feed/entry').each do |e|
|
55
55
|
# e.remove_namespaces!('link')
|
56
56
|
if e.xpath('//content/company-info').to_s.length > 0
|
57
|
-
doc = Hashie::Mash.new(Crack::XML.parse(e.xpath('//content/company-info').to_s))
|
57
|
+
doc = Hashie::Mash.new(Crack::XML.parse(e.xpath('//content/company-info').to_s)['company_info'])
|
58
58
|
end
|
59
59
|
if e.xpath('//company-info').to_s.length > 0
|
60
|
-
doc = Hashie::Mash.new(Crack::XML.parse(e.xpath('//company-info').to_s))
|
60
|
+
doc = Hashie::Mash.new(Crack::XML.parse(e.xpath('//company-info').to_s)['company_info'])
|
61
61
|
end
|
62
62
|
if e.xpath('//content/accession-nunber').to_s.length > 0
|
63
|
-
doc = Crack::XML.parse(e.xpath('//content').to_s).collect {|k, v| v }
|
63
|
+
doc = Crack::XML.parse(e.xpath('//content').to_s).collect {|k, v| Hashie::Mash.new(v) }
|
64
64
|
end
|
65
65
|
|
66
66
|
entries << doc
|
data/lib/sec_entities/version.rb
CHANGED
Binary file
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sec_entities
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ty Rauber
|
@@ -99,6 +99,7 @@ files:
|
|
99
99
|
- lib/sec_entities/entity.rb
|
100
100
|
- lib/sec_entities/version.rb
|
101
101
|
- pkg/sec_entities-0.0.1.gem
|
102
|
+
- pkg/sec_entities-0.0.2.gem
|
102
103
|
- sec_entities.gemspec
|
103
104
|
- spec/sec_query_spec.rb
|
104
105
|
- spec/spec_helper.rb
|