eve_online 0.40.0 → 0.41.0
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/.circleci/config.yml +9 -9
- data/.github/dependabot.yml +10 -0
- data/.rubocop.yml +11 -0
- data/.ruby-version +1 -1
- data/Appraisals +2 -0
- data/CHANGELOG.md +4 -0
- data/Gemfile.lock +52 -37
- data/README.md +77 -1
- data/lib/eve_online/esi/base.rb +1 -3
- data/lib/eve_online/esi/models/search.rb +64 -0
- data/lib/eve_online/esi/search.rb +61 -0
- data/lib/eve_online/version.rb +1 -1
- data/lib/eve_online.rb +3 -0
- metadata +7 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 65d576fbc17478176c4263d33598813505b783b6e796885b43f5024e32463950
|
|
4
|
+
data.tar.gz: f6aa4d023bcd8a2a2b08a0c975d192f06360b0d56d0e4fbff03d2f4cfac67a6f
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 1d2f7a4fe87043d80116ece05d4db4e45f56045e80f722d375a006e78aaee80c19ee5807336cc3b452e0841169c9dd78ef82a7f0aff05c6cc9f26f460c5a3926
|
|
7
|
+
data.tar.gz: 91fb7f5dc523c480e68924dbc49b38a28926742dde3947e281d3cf7ed75e5f93864931d57af5b45e155be5204de98e2c3162da7b4c7134c6e6d871fb9bae6bab
|
data/.circleci/config.yml
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
version: 2
|
|
2
2
|
|
|
3
3
|
jobs:
|
|
4
|
-
ruby-2.6.
|
|
4
|
+
ruby-2.6.8:
|
|
5
5
|
docker:
|
|
6
|
-
- image: circleci/ruby:2.6.
|
|
6
|
+
- image: circleci/ruby:2.6.8
|
|
7
7
|
steps:
|
|
8
8
|
- checkout
|
|
9
9
|
- run: rm Gemfile.lock
|
|
@@ -14,9 +14,9 @@ jobs:
|
|
|
14
14
|
- run: bundle exec standardrb
|
|
15
15
|
- run: bundle exec fasterer
|
|
16
16
|
- run: bundle exec mdl README.md CHANGELOG.md
|
|
17
|
-
ruby-2.7.
|
|
17
|
+
ruby-2.7.4:
|
|
18
18
|
docker:
|
|
19
|
-
- image: circleci/ruby:2.7.
|
|
19
|
+
- image: circleci/ruby:2.7.4
|
|
20
20
|
steps:
|
|
21
21
|
- checkout
|
|
22
22
|
- run: rm Gemfile.lock
|
|
@@ -27,9 +27,9 @@ jobs:
|
|
|
27
27
|
- run: bundle exec standardrb
|
|
28
28
|
- run: bundle exec fasterer
|
|
29
29
|
- run: bundle exec mdl README.md CHANGELOG.md
|
|
30
|
-
ruby-3.0.
|
|
30
|
+
ruby-3.0.2:
|
|
31
31
|
docker:
|
|
32
|
-
- image: circleci/ruby:3.0.
|
|
32
|
+
- image: circleci/ruby:3.0.2
|
|
33
33
|
steps:
|
|
34
34
|
- checkout
|
|
35
35
|
- run: rm Gemfile.lock
|
|
@@ -45,6 +45,6 @@ workflows:
|
|
|
45
45
|
version: 2
|
|
46
46
|
tests:
|
|
47
47
|
jobs:
|
|
48
|
-
- ruby-2.6.
|
|
49
|
-
- ruby-2.7.
|
|
50
|
-
- ruby-3.0.
|
|
48
|
+
- ruby-2.6.8
|
|
49
|
+
- ruby-2.7.4
|
|
50
|
+
- ruby-3.0.2
|
data/.rubocop.yml
ADDED
data/.ruby-version
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
3.0.
|
|
1
|
+
3.0.2
|
data/Appraisals
CHANGED
data/CHANGELOG.md
CHANGED
data/Gemfile.lock
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
PATH
|
|
2
2
|
remote: .
|
|
3
3
|
specs:
|
|
4
|
-
eve_online (0.
|
|
4
|
+
eve_online (0.41.0)
|
|
5
5
|
activesupport (>= 5.2.0)
|
|
6
6
|
faraday
|
|
7
7
|
faraday_middleware
|
|
@@ -9,40 +9,55 @@ PATH
|
|
|
9
9
|
GEM
|
|
10
10
|
remote: https://rubygems.org/
|
|
11
11
|
specs:
|
|
12
|
-
activesupport (6.1.
|
|
12
|
+
activesupport (6.1.4.1)
|
|
13
13
|
concurrent-ruby (~> 1.0, >= 1.0.2)
|
|
14
14
|
i18n (>= 1.6, < 2)
|
|
15
15
|
minitest (>= 5.1)
|
|
16
16
|
tzinfo (~> 2.0)
|
|
17
17
|
zeitwerk (~> 2.3)
|
|
18
|
-
addressable (2.
|
|
18
|
+
addressable (2.8.0)
|
|
19
19
|
public_suffix (>= 2.0.2, < 5.0)
|
|
20
|
-
appraisal (2.4.
|
|
20
|
+
appraisal (2.4.1)
|
|
21
21
|
bundler
|
|
22
22
|
rake
|
|
23
23
|
thor (>= 0.14.0)
|
|
24
24
|
ast (2.4.2)
|
|
25
25
|
awesome_print (1.9.2)
|
|
26
|
-
chef-utils (
|
|
26
|
+
chef-utils (17.4.25)
|
|
27
|
+
concurrent-ruby
|
|
27
28
|
coderay (1.1.3)
|
|
28
29
|
colorize (0.8.1)
|
|
29
|
-
concurrent-ruby (1.1.
|
|
30
|
+
concurrent-ruby (1.1.9)
|
|
30
31
|
crack (0.4.5)
|
|
31
32
|
rexml
|
|
32
33
|
diff-lcs (1.4.4)
|
|
33
|
-
docile (1.
|
|
34
|
-
faraday (1.
|
|
34
|
+
docile (1.4.0)
|
|
35
|
+
faraday (1.7.0)
|
|
36
|
+
faraday-em_http (~> 1.0)
|
|
37
|
+
faraday-em_synchrony (~> 1.0)
|
|
38
|
+
faraday-excon (~> 1.1)
|
|
39
|
+
faraday-httpclient (~> 1.0.1)
|
|
35
40
|
faraday-net_http (~> 1.0)
|
|
41
|
+
faraday-net_http_persistent (~> 1.1)
|
|
42
|
+
faraday-patron (~> 1.0)
|
|
43
|
+
faraday-rack (~> 1.0)
|
|
36
44
|
multipart-post (>= 1.2, < 3)
|
|
37
|
-
ruby2_keywords
|
|
45
|
+
ruby2_keywords (>= 0.0.4)
|
|
46
|
+
faraday-em_http (1.0.0)
|
|
47
|
+
faraday-em_synchrony (1.0.0)
|
|
48
|
+
faraday-excon (1.1.0)
|
|
49
|
+
faraday-httpclient (1.0.1)
|
|
38
50
|
faraday-net_http (1.0.1)
|
|
39
|
-
|
|
51
|
+
faraday-net_http_persistent (1.2.0)
|
|
52
|
+
faraday-patron (1.0.0)
|
|
53
|
+
faraday-rack (1.0.0)
|
|
54
|
+
faraday_middleware (1.1.0)
|
|
40
55
|
faraday (~> 1.0)
|
|
41
56
|
fasterer (0.9.0)
|
|
42
57
|
colorize (~> 0.7)
|
|
43
58
|
ruby_parser (>= 3.14.1)
|
|
44
59
|
hashdiff (1.0.1)
|
|
45
|
-
i18n (1.8.
|
|
60
|
+
i18n (1.8.10)
|
|
46
61
|
concurrent-ruby (~> 1.0)
|
|
47
62
|
kramdown (2.3.1)
|
|
48
63
|
rexml
|
|
@@ -55,7 +70,7 @@ GEM
|
|
|
55
70
|
mixlib-config (>= 2.2.1, < 4)
|
|
56
71
|
mixlib-shellout
|
|
57
72
|
method_source (1.0.0)
|
|
58
|
-
mini_portile2 (2.
|
|
73
|
+
mini_portile2 (2.6.1)
|
|
59
74
|
minitest (5.14.4)
|
|
60
75
|
mixlib-cli (2.1.8)
|
|
61
76
|
mixlib-config (3.0.9)
|
|
@@ -63,23 +78,23 @@ GEM
|
|
|
63
78
|
mixlib-shellout (3.2.5)
|
|
64
79
|
chef-utils
|
|
65
80
|
multipart-post (2.1.1)
|
|
66
|
-
nokogiri (1.
|
|
67
|
-
mini_portile2 (~> 2.
|
|
81
|
+
nokogiri (1.12.3)
|
|
82
|
+
mini_portile2 (~> 2.6.1)
|
|
68
83
|
racc (~> 1.4)
|
|
69
|
-
nokogiri (1.
|
|
84
|
+
nokogiri (1.12.3-x86_64-darwin)
|
|
70
85
|
racc (~> 1.4)
|
|
71
|
-
parallel (1.20.
|
|
72
|
-
parser (3.0.
|
|
86
|
+
parallel (1.20.2)
|
|
87
|
+
parser (3.0.2.0)
|
|
73
88
|
ast (~> 2.4.1)
|
|
74
|
-
pry (0.14.
|
|
89
|
+
pry (0.14.1)
|
|
75
90
|
coderay (~> 1.1)
|
|
76
91
|
method_source (~> 1.0)
|
|
77
92
|
public_suffix (4.0.6)
|
|
78
93
|
racc (1.5.2)
|
|
79
94
|
rainbow (3.0.0)
|
|
80
|
-
rake (13.0.
|
|
95
|
+
rake (13.0.6)
|
|
81
96
|
regexp_parser (2.1.1)
|
|
82
|
-
rexml (3.2.
|
|
97
|
+
rexml (3.2.5)
|
|
83
98
|
rspec (3.10.0)
|
|
84
99
|
rspec-core (~> 3.10.0)
|
|
85
100
|
rspec-expectations (~> 3.10.0)
|
|
@@ -96,42 +111,42 @@ GEM
|
|
|
96
111
|
diff-lcs (>= 1.2.0, < 2.0)
|
|
97
112
|
rspec-support (~> 3.10.0)
|
|
98
113
|
rspec-support (3.10.2)
|
|
99
|
-
rubocop (1.
|
|
114
|
+
rubocop (1.19.1)
|
|
100
115
|
parallel (~> 1.10)
|
|
101
116
|
parser (>= 3.0.0.0)
|
|
102
117
|
rainbow (>= 2.2.2, < 4.0)
|
|
103
118
|
regexp_parser (>= 1.8, < 3.0)
|
|
104
119
|
rexml
|
|
105
|
-
rubocop-ast (>= 1.
|
|
120
|
+
rubocop-ast (>= 1.9.1, < 2.0)
|
|
106
121
|
ruby-progressbar (~> 1.7)
|
|
107
122
|
unicode-display_width (>= 1.4.0, < 3.0)
|
|
108
|
-
rubocop-ast (1.
|
|
109
|
-
parser (>=
|
|
110
|
-
rubocop-performance (1.
|
|
111
|
-
rubocop (>=
|
|
123
|
+
rubocop-ast (1.11.0)
|
|
124
|
+
parser (>= 3.0.1.1)
|
|
125
|
+
rubocop-performance (1.11.5)
|
|
126
|
+
rubocop (>= 1.7.0, < 2.0)
|
|
112
127
|
rubocop-ast (>= 0.4.0)
|
|
113
128
|
ruby-progressbar (1.11.0)
|
|
114
|
-
ruby2_keywords (0.0.
|
|
115
|
-
ruby_parser (3.
|
|
116
|
-
sexp_processor (~> 4.
|
|
117
|
-
sexp_processor (4.15.
|
|
129
|
+
ruby2_keywords (0.0.5)
|
|
130
|
+
ruby_parser (3.17.0)
|
|
131
|
+
sexp_processor (~> 4.15, >= 4.15.1)
|
|
132
|
+
sexp_processor (4.15.3)
|
|
118
133
|
simplecov (0.21.2)
|
|
119
134
|
docile (~> 1.1)
|
|
120
135
|
simplecov-html (~> 0.11)
|
|
121
136
|
simplecov_json_formatter (~> 0.1)
|
|
122
137
|
simplecov-html (0.12.3)
|
|
123
|
-
simplecov_json_formatter (0.1.
|
|
124
|
-
standard (1.0
|
|
125
|
-
rubocop (= 1.
|
|
126
|
-
rubocop-performance (= 1.
|
|
138
|
+
simplecov_json_formatter (0.1.3)
|
|
139
|
+
standard (1.2.0)
|
|
140
|
+
rubocop (= 1.19.1)
|
|
141
|
+
rubocop-performance (= 1.11.5)
|
|
127
142
|
thor (1.1.0)
|
|
128
143
|
tomlrb (2.0.1)
|
|
129
144
|
tzinfo (2.0.4)
|
|
130
145
|
concurrent-ruby (~> 1.0)
|
|
131
146
|
unicode-display_width (2.0.0)
|
|
132
147
|
vcr (6.0.0)
|
|
133
|
-
webmock (3.
|
|
134
|
-
addressable (>= 2.
|
|
148
|
+
webmock (3.14.0)
|
|
149
|
+
addressable (>= 2.8.0)
|
|
135
150
|
crack (>= 0.3.2)
|
|
136
151
|
hashdiff (>= 0.4.0, < 2.0.0)
|
|
137
152
|
zeitwerk (2.4.2)
|
|
@@ -159,4 +174,4 @@ DEPENDENCIES
|
|
|
159
174
|
webmock
|
|
160
175
|
|
|
161
176
|
BUNDLED WITH
|
|
162
|
-
2.2.
|
|
177
|
+
2.2.26
|
data/README.md
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
[](https://badge.fury.io/rb/eve_online)
|
|
5
5
|
[](https://rubygems.org/gems/eve_online)
|
|
6
6
|
[](https://snyk.io/test/github/evemonk/eve_online)
|
|
7
|
-
[](https://hakiri.io/github/evemonk/eve_online/main)
|
|
8
8
|
[](https://deepsource.io/gh/evemonk/eve_online/?ref=repository-badge)
|
|
9
9
|
[](https://github.com/testdouble/standard)
|
|
10
10
|
|
|
@@ -1898,6 +1898,81 @@ market_prices.etag # => "2d5acc3bd4555821bb91d787596f5ddad129f849739e83162e93c02
|
|
|
1898
1898
|
|
|
1899
1899
|
#### Search on a string
|
|
1900
1900
|
|
|
1901
|
+
```ruby
|
|
1902
|
+
# simple search
|
|
1903
|
+
|
|
1904
|
+
options = { search: "Jita" }
|
|
1905
|
+
|
|
1906
|
+
search = EveOnline::ESI::Search.new(options)
|
|
1907
|
+
|
|
1908
|
+
search.as_json # => {:agent_ids=>[3018357],
|
|
1909
|
+
# :alliance_ids=>[99011026, 99005382, 99010662, 99010663, 99010665, 99010666],
|
|
1910
|
+
# :character_ids=>[2118081143, ... 2114943117],
|
|
1911
|
+
# :constellation_ids=>[],
|
|
1912
|
+
# :corporation_ids=>[],
|
|
1913
|
+
# :faction_ids=>[],
|
|
1914
|
+
# :inventory_type_ids=>[56844, 56847, 56846, 56853, 56849, 56852, 56850, 52275, 56848, 56851, 56845],
|
|
1915
|
+
# :region_ids=>[],
|
|
1916
|
+
# :solar_system_ids=>[30000142],
|
|
1917
|
+
# :station_ids=>[]}
|
|
1918
|
+
|
|
1919
|
+
search.agent_ids # => [3018357]
|
|
1920
|
+
search.alliance_ids # => [99011026, 99005382, 99010662, 99010663, 99010665, 99010666]
|
|
1921
|
+
search.character_ids.size # => 467
|
|
1922
|
+
search.character_ids.first # => 2118081143
|
|
1923
|
+
search.constellation_ids # => []
|
|
1924
|
+
search.corporation_ids # => []
|
|
1925
|
+
search.faction_ids # => []
|
|
1926
|
+
search.inventory_type_ids # => [56844, 56847, 56846, 56853, 56849, 56852, 56850, 52275, 56848, 56851, 56845]
|
|
1927
|
+
search.region_ids # => []
|
|
1928
|
+
search.solar_system_ids # => [30000142]
|
|
1929
|
+
search.station_ids # => []
|
|
1930
|
+
|
|
1931
|
+
search.etag # => "b6602e595e8d8df37b5191b82e75faba91284281b6fe71965d09e2f1"
|
|
1932
|
+
|
|
1933
|
+
# strict search
|
|
1934
|
+
|
|
1935
|
+
options = { search: "Jita", strict: true }
|
|
1936
|
+
|
|
1937
|
+
search = EveOnline::ESI::Search.new(options)
|
|
1938
|
+
|
|
1939
|
+
search.as_json # => {:agent_ids=>[],
|
|
1940
|
+
# :alliance_ids=>[99005382],
|
|
1941
|
+
# :character_ids=>[1392050776],
|
|
1942
|
+
# :constellation_ids=>[],
|
|
1943
|
+
# :corporation_ids=>[98004200, 98049474, 383768304, 98358437],
|
|
1944
|
+
# :faction_ids=>[],
|
|
1945
|
+
# :inventory_type_ids=>[],
|
|
1946
|
+
# :region_ids=>[],
|
|
1947
|
+
# :solar_system_ids=>[30000142],
|
|
1948
|
+
# :station_ids=>[]}
|
|
1949
|
+
|
|
1950
|
+
# strict search with filter by categories
|
|
1951
|
+
|
|
1952
|
+
# List of default categories (used when categories is empty):
|
|
1953
|
+
# ["agent", "alliance", "character", "constellation", "corporation", "faction",
|
|
1954
|
+
# "inventory_type", "region", "solar_system", "station"]
|
|
1955
|
+
|
|
1956
|
+
# So, add `categories: ['solar_system']` and see:
|
|
1957
|
+
|
|
1958
|
+
options = { search: "Jita", categories: ["solar_system"], strict: true }
|
|
1959
|
+
|
|
1960
|
+
search = EveOnline::ESI::Search.new(options)
|
|
1961
|
+
|
|
1962
|
+
search.as_json # => {:agent_ids=>[],
|
|
1963
|
+
# :alliance_ids=>[],
|
|
1964
|
+
# :character_ids=>[],
|
|
1965
|
+
# :constellation_ids=>[],
|
|
1966
|
+
# :corporation_ids=>[],
|
|
1967
|
+
# :faction_ids=>[],
|
|
1968
|
+
# :inventory_type_ids=>[],
|
|
1969
|
+
# :region_ids=>[],
|
|
1970
|
+
# :solar_system_ids=>[30000142],
|
|
1971
|
+
# :station_ids=>[]}
|
|
1972
|
+
|
|
1973
|
+
search.solar_system_ids # => [30000142]
|
|
1974
|
+
```
|
|
1975
|
+
|
|
1901
1976
|
### Skills
|
|
1902
1977
|
|
|
1903
1978
|
#### Get character attributes
|
|
@@ -3210,6 +3285,7 @@ Thank you everyone!
|
|
|
3210
3285
|
* Ian Flynn (@monban)
|
|
3211
3286
|
* Mekaret Eriker (@Mekaret)
|
|
3212
3287
|
* Y. (@lunohodov)
|
|
3288
|
+
* Trevor Copeland (@sicks)
|
|
3213
3289
|
|
|
3214
3290
|
## License
|
|
3215
3291
|
|
data/lib/eve_online/esi/base.rb
CHANGED
|
@@ -113,8 +113,6 @@ module EveOnline
|
|
|
113
113
|
f.use middleware[:class]
|
|
114
114
|
end
|
|
115
115
|
end
|
|
116
|
-
# f.use Faraday::Response::Logger
|
|
117
|
-
# f.use FaradayMiddleware::FollowRedirects, limit: 5
|
|
118
116
|
f.response :json, content_type: "application/json"
|
|
119
117
|
f.adapter adapter
|
|
120
118
|
end
|
|
@@ -147,7 +145,7 @@ module EveOnline
|
|
|
147
145
|
hash[param] = public_send(param)
|
|
148
146
|
end
|
|
149
147
|
|
|
150
|
-
hash.reject { |_, v| v.
|
|
148
|
+
hash.reject { |_, v| v.nil? || v == "" }
|
|
151
149
|
end
|
|
152
150
|
|
|
153
151
|
def resource
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module EveOnline
|
|
4
|
+
module ESI
|
|
5
|
+
module Models
|
|
6
|
+
class Search < Base
|
|
7
|
+
def as_json
|
|
8
|
+
{
|
|
9
|
+
agent_ids: agent_ids,
|
|
10
|
+
alliance_ids: alliance_ids,
|
|
11
|
+
character_ids: character_ids,
|
|
12
|
+
constellation_ids: constellation_ids,
|
|
13
|
+
corporation_ids: corporation_ids,
|
|
14
|
+
faction_ids: faction_ids,
|
|
15
|
+
inventory_type_ids: inventory_type_ids,
|
|
16
|
+
region_ids: region_ids,
|
|
17
|
+
solar_system_ids: solar_system_ids,
|
|
18
|
+
station_ids: station_ids
|
|
19
|
+
}
|
|
20
|
+
end
|
|
21
|
+
|
|
22
|
+
def agent_ids
|
|
23
|
+
options.fetch("agent", [])
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
def alliance_ids
|
|
27
|
+
options.fetch("alliance", [])
|
|
28
|
+
end
|
|
29
|
+
|
|
30
|
+
def character_ids
|
|
31
|
+
options.fetch("character", [])
|
|
32
|
+
end
|
|
33
|
+
|
|
34
|
+
def constellation_ids
|
|
35
|
+
options.fetch("constellation", [])
|
|
36
|
+
end
|
|
37
|
+
|
|
38
|
+
def corporation_ids
|
|
39
|
+
options.fetch("corporation", [])
|
|
40
|
+
end
|
|
41
|
+
|
|
42
|
+
def faction_ids
|
|
43
|
+
options.fetch("faction", [])
|
|
44
|
+
end
|
|
45
|
+
|
|
46
|
+
def inventory_type_ids
|
|
47
|
+
options.fetch("inventory_type", [])
|
|
48
|
+
end
|
|
49
|
+
|
|
50
|
+
def region_ids
|
|
51
|
+
options.fetch("region", [])
|
|
52
|
+
end
|
|
53
|
+
|
|
54
|
+
def solar_system_ids
|
|
55
|
+
options.fetch("solar_system", [])
|
|
56
|
+
end
|
|
57
|
+
|
|
58
|
+
def station_ids
|
|
59
|
+
options.fetch("stations", [])
|
|
60
|
+
end
|
|
61
|
+
end
|
|
62
|
+
end
|
|
63
|
+
end
|
|
64
|
+
end
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
require "forwardable"
|
|
4
|
+
|
|
5
|
+
module EveOnline
|
|
6
|
+
module ESI
|
|
7
|
+
class Search < Base
|
|
8
|
+
extend Forwardable
|
|
9
|
+
|
|
10
|
+
API_PATH = "/v2/search/"
|
|
11
|
+
|
|
12
|
+
DEFAULT_CATEGORIES = [
|
|
13
|
+
"agent",
|
|
14
|
+
"alliance",
|
|
15
|
+
"character",
|
|
16
|
+
"constellation",
|
|
17
|
+
"corporation",
|
|
18
|
+
"faction",
|
|
19
|
+
"inventory_type",
|
|
20
|
+
"region",
|
|
21
|
+
"solar_system",
|
|
22
|
+
"station"
|
|
23
|
+
]
|
|
24
|
+
|
|
25
|
+
attr_reader :search, :strict, :raw_categories, :categories
|
|
26
|
+
|
|
27
|
+
def initialize(options)
|
|
28
|
+
super
|
|
29
|
+
|
|
30
|
+
@search = options.fetch(:search)
|
|
31
|
+
@strict = options.fetch(:strict, false)
|
|
32
|
+
@raw_categories = options.fetch(:categories, DEFAULT_CATEGORIES)
|
|
33
|
+
@raw_categories.each do |c|
|
|
34
|
+
unless DEFAULT_CATEGORIES.include?(c)
|
|
35
|
+
raise(ArgumentError)
|
|
36
|
+
end
|
|
37
|
+
end
|
|
38
|
+
@categories = @raw_categories.join(",")
|
|
39
|
+
end
|
|
40
|
+
|
|
41
|
+
def_delegators :model, :as_json, :agent_ids, :alliance_ids,
|
|
42
|
+
:character_ids, :constellation_ids, :corporation_ids, :faction_ids,
|
|
43
|
+
:inventory_type_ids, :region_ids, :solar_system_ids, :station_ids
|
|
44
|
+
|
|
45
|
+
def model
|
|
46
|
+
@model ||= Models::Search.new(response)
|
|
47
|
+
end
|
|
48
|
+
|
|
49
|
+
def scope
|
|
50
|
+
end
|
|
51
|
+
|
|
52
|
+
def additional_query_params
|
|
53
|
+
[:search, :categories, :strict]
|
|
54
|
+
end
|
|
55
|
+
|
|
56
|
+
def path
|
|
57
|
+
format(API_PATH, search: search, categories: categories, strict: strict)
|
|
58
|
+
end
|
|
59
|
+
end
|
|
60
|
+
end
|
|
61
|
+
end
|
data/lib/eve_online/version.rb
CHANGED
data/lib/eve_online.rb
CHANGED
|
@@ -92,6 +92,8 @@ module EveOnline
|
|
|
92
92
|
autoload :MarketGroup, "eve_online/esi/market_group"
|
|
93
93
|
autoload :MarketPrices, "eve_online/esi/market_prices"
|
|
94
94
|
|
|
95
|
+
autoload :Search, "eve_online/esi/search"
|
|
96
|
+
|
|
95
97
|
autoload :CharacterAttributes, "eve_online/esi/character_attributes"
|
|
96
98
|
autoload :CharacterSkillQueue, "eve_online/esi/character_skill_queue"
|
|
97
99
|
autoload :CharacterSkills, "eve_online/esi/character_skills"
|
|
@@ -175,6 +177,7 @@ module EveOnline
|
|
|
175
177
|
autoload :WalletTransaction, "eve_online/esi/models/wallet_transaction"
|
|
176
178
|
autoload :CorporationOrder, "eve_online/esi/models/corporation_order"
|
|
177
179
|
autoload :HomeLocation, "eve_online/esi/models/home_location"
|
|
180
|
+
autoload :Search, "eve_online/esi/models/search"
|
|
178
181
|
autoload :ServerStatus, "eve_online/esi/models/server_status"
|
|
179
182
|
|
|
180
183
|
autoload :MarketHistory, "eve_online/esi/models/market_history"
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: eve_online
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.41.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Igor Zubkov
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2021-
|
|
11
|
+
date: 2021-08-27 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: bundler
|
|
@@ -189,8 +189,10 @@ files:
|
|
|
189
189
|
- ".deepsource.toml"
|
|
190
190
|
- ".fasterer.yml"
|
|
191
191
|
- ".github/FUNDING.yml"
|
|
192
|
+
- ".github/dependabot.yml"
|
|
192
193
|
- ".gitignore"
|
|
193
194
|
- ".mdlrc"
|
|
195
|
+
- ".rubocop.yml"
|
|
194
196
|
- ".ruby-version"
|
|
195
197
|
- ".standard.yml"
|
|
196
198
|
- Appraisals
|
|
@@ -330,6 +332,7 @@ files:
|
|
|
330
332
|
- lib/eve_online/esi/models/public_contract_item.rb
|
|
331
333
|
- lib/eve_online/esi/models/race.rb
|
|
332
334
|
- lib/eve_online/esi/models/region.rb
|
|
335
|
+
- lib/eve_online/esi/models/search.rb
|
|
333
336
|
- lib/eve_online/esi/models/server_status.rb
|
|
334
337
|
- lib/eve_online/esi/models/skill.rb
|
|
335
338
|
- lib/eve_online/esi/models/skill_queue_entry.rb
|
|
@@ -346,6 +349,7 @@ files:
|
|
|
346
349
|
- lib/eve_online/esi/models/war.rb
|
|
347
350
|
- lib/eve_online/esi/public_contract.rb
|
|
348
351
|
- lib/eve_online/esi/public_contracts.rb
|
|
352
|
+
- lib/eve_online/esi/search.rb
|
|
349
353
|
- lib/eve_online/esi/server_status.rb
|
|
350
354
|
- lib/eve_online/esi/universe_ancestries.rb
|
|
351
355
|
- lib/eve_online/esi/universe_asteroid_belt.rb
|
|
@@ -416,7 +420,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
416
420
|
- !ruby/object:Gem::Version
|
|
417
421
|
version: '0'
|
|
418
422
|
requirements: []
|
|
419
|
-
rubygems_version: 3.2.
|
|
423
|
+
rubygems_version: 3.2.26
|
|
420
424
|
signing_key:
|
|
421
425
|
specification_version: 4
|
|
422
426
|
summary: EveOnline ESI API
|