eve_online 0.10.0 → 0.11.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.editorconfig +10 -0
- data/.rubocop.yml +2 -7
- data/.travis.yml +4 -1
- data/Gemfile +1 -1
- data/README.md +273 -7
- data/eve_online.gemspec +4 -2
- data/lib/eve_online.rb +32 -2
- data/lib/eve_online/characters/skill_queue.rb +3 -3
- data/lib/eve_online/esi/base.rb +15 -2
- data/lib/eve_online/esi/character.rb +75 -0
- data/lib/eve_online/esi/character_loyalty_points.rb +31 -0
- data/lib/eve_online/esi/character_portrait.rb +61 -0
- data/lib/eve_online/esi/character_skill_queue.rb +31 -0
- data/lib/eve_online/esi/character_skills.rb +41 -0
- data/lib/eve_online/esi/models/loyalty_point.rb +28 -0
- data/lib/eve_online/esi/models/skill.rb +33 -0
- data/lib/eve_online/esi/models/skill_queue_entry.rb +60 -0
- data/lib/eve_online/sde/agt_agent_types.rb +14 -0
- data/lib/eve_online/sde/agt_agents.rb +14 -0
- data/lib/eve_online/sde/agt_research_agents.rb +14 -0
- data/lib/eve_online/sde/base.rb +25 -0
- data/lib/eve_online/sde/chr_races.rb +14 -0
- data/lib/eve_online/sde/inv_flags.rb +14 -0
- data/lib/eve_online/sde/inv_items.rb +14 -0
- data/lib/eve_online/sde/inv_names.rb +14 -0
- data/lib/eve_online/sde/inv_positions.rb +14 -0
- data/lib/eve_online/sde/models/agt_agent.rb +58 -0
- data/lib/eve_online/sde/models/agt_agent_type.rb +28 -0
- data/lib/eve_online/sde/models/agt_research_agent.rb +28 -0
- data/lib/eve_online/sde/models/chr_race.rb +38 -0
- data/lib/eve_online/sde/models/inv_flag.rb +38 -0
- data/lib/eve_online/sde/models/inv_item.rb +48 -0
- data/lib/eve_online/sde/models/inv_name.rb +28 -0
- data/lib/eve_online/sde/models/inv_position.rb +53 -0
- data/lib/eve_online/version.rb +1 -1
- data/lib/eve_online/xml/models/skill_queue_entry.rb +55 -0
- metadata +31 -6
- data/lib/eve_online/esi/characters/character.rb +0 -20
- data/lib/eve_online/skill_queue_entry.rb +0 -51
data/lib/eve_online/version.rb
CHANGED
@@ -0,0 +1,55 @@
|
|
1
|
+
require 'active_support/time'
|
2
|
+
|
3
|
+
module EveOnline
|
4
|
+
module XML
|
5
|
+
module Models
|
6
|
+
class SkillQueueEntry
|
7
|
+
attr_reader :options
|
8
|
+
|
9
|
+
def initialize(options)
|
10
|
+
@options = options
|
11
|
+
end
|
12
|
+
|
13
|
+
def as_json
|
14
|
+
{
|
15
|
+
queue_position: queue_position,
|
16
|
+
type_id: type_id,
|
17
|
+
level: level,
|
18
|
+
start_sp: start_sp,
|
19
|
+
end_sp: end_sp,
|
20
|
+
start_time: start_time,
|
21
|
+
end_time: end_time
|
22
|
+
}
|
23
|
+
end
|
24
|
+
|
25
|
+
def queue_position
|
26
|
+
options.fetch('@queuePosition').to_i
|
27
|
+
end
|
28
|
+
|
29
|
+
def type_id
|
30
|
+
options.fetch('@typeID').to_i
|
31
|
+
end
|
32
|
+
|
33
|
+
def level
|
34
|
+
options.fetch('@level').to_i
|
35
|
+
end
|
36
|
+
|
37
|
+
def start_sp
|
38
|
+
options.fetch('@startSP').to_i
|
39
|
+
end
|
40
|
+
|
41
|
+
def end_sp
|
42
|
+
options.fetch('@endSP').to_i
|
43
|
+
end
|
44
|
+
|
45
|
+
def start_time
|
46
|
+
ActiveSupport::TimeZone['UTC'].parse(options.fetch('@startTime'))
|
47
|
+
end
|
48
|
+
|
49
|
+
def end_time
|
50
|
+
ActiveSupport::TimeZone['UTC'].parse(options.fetch('@endTime'))
|
51
|
+
end
|
52
|
+
end
|
53
|
+
end
|
54
|
+
end
|
55
|
+
end
|
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.11.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:
|
11
|
+
date: 2017-02-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -164,7 +164,7 @@ dependencies:
|
|
164
164
|
- - ">="
|
165
165
|
- !ruby/object:Gem::Version
|
166
166
|
version: '0'
|
167
|
-
description: EveOnline API. XML, CREST and ESI.
|
167
|
+
description: EveOnline API. XML, CREST and ESI. And SDE.
|
168
168
|
email:
|
169
169
|
- igor.zubkov@gmail.com
|
170
170
|
executables: []
|
@@ -172,6 +172,7 @@ extensions: []
|
|
172
172
|
extra_rdoc_files: []
|
173
173
|
files:
|
174
174
|
- ".codeclimate.yml"
|
175
|
+
- ".editorconfig"
|
175
176
|
- ".gitignore"
|
176
177
|
- ".rspec"
|
177
178
|
- ".rubocop.yml"
|
@@ -237,7 +238,14 @@ files:
|
|
237
238
|
- lib/eve_online/contact_notification.rb
|
238
239
|
- lib/eve_online/corporations/market_orders.rb
|
239
240
|
- lib/eve_online/esi/base.rb
|
240
|
-
- lib/eve_online/esi/
|
241
|
+
- lib/eve_online/esi/character.rb
|
242
|
+
- lib/eve_online/esi/character_loyalty_points.rb
|
243
|
+
- lib/eve_online/esi/character_portrait.rb
|
244
|
+
- lib/eve_online/esi/character_skill_queue.rb
|
245
|
+
- lib/eve_online/esi/character_skills.rb
|
246
|
+
- lib/eve_online/esi/models/loyalty_point.rb
|
247
|
+
- lib/eve_online/esi/models/skill.rb
|
248
|
+
- lib/eve_online/esi/models/skill_queue_entry.rb
|
241
249
|
- lib/eve_online/eve/character_id.rb
|
242
250
|
- lib/eve_online/event.rb
|
243
251
|
- lib/eve_online/event_response_object.rb
|
@@ -248,13 +256,30 @@ files:
|
|
248
256
|
- lib/eve_online/jump_clone.rb
|
249
257
|
- lib/eve_online/jump_clone_implant.rb
|
250
258
|
- lib/eve_online/market_order.rb
|
259
|
+
- lib/eve_online/sde/agt_agent_types.rb
|
260
|
+
- lib/eve_online/sde/agt_agents.rb
|
261
|
+
- lib/eve_online/sde/agt_research_agents.rb
|
262
|
+
- lib/eve_online/sde/base.rb
|
263
|
+
- lib/eve_online/sde/chr_races.rb
|
264
|
+
- lib/eve_online/sde/inv_flags.rb
|
265
|
+
- lib/eve_online/sde/inv_items.rb
|
266
|
+
- lib/eve_online/sde/inv_names.rb
|
267
|
+
- lib/eve_online/sde/inv_positions.rb
|
268
|
+
- lib/eve_online/sde/models/agt_agent.rb
|
269
|
+
- lib/eve_online/sde/models/agt_agent_type.rb
|
270
|
+
- lib/eve_online/sde/models/agt_research_agent.rb
|
271
|
+
- lib/eve_online/sde/models/chr_race.rb
|
272
|
+
- lib/eve_online/sde/models/inv_flag.rb
|
273
|
+
- lib/eve_online/sde/models/inv_item.rb
|
274
|
+
- lib/eve_online/sde/models/inv_name.rb
|
275
|
+
- lib/eve_online/sde/models/inv_position.rb
|
251
276
|
- lib/eve_online/server/status.rb
|
252
277
|
- lib/eve_online/skill.rb
|
253
|
-
- lib/eve_online/skill_queue_entry.rb
|
254
278
|
- lib/eve_online/sovereignty/campaigns.rb
|
255
279
|
- lib/eve_online/standing.rb
|
256
280
|
- lib/eve_online/version.rb
|
257
281
|
- lib/eve_online/wallet_journal_entry.rb
|
282
|
+
- lib/eve_online/xml/models/skill_queue_entry.rb
|
258
283
|
- mutant.sh
|
259
284
|
homepage: https://github.com/biow0lf/eve_online
|
260
285
|
licenses:
|
@@ -279,5 +304,5 @@ rubyforge_project:
|
|
279
304
|
rubygems_version: 2.6.8
|
280
305
|
signing_key:
|
281
306
|
specification_version: 4
|
282
|
-
summary: EveOnline API. XML, CREST and ESI.
|
307
|
+
summary: EveOnline API. XML, CREST and ESI. And SDE.
|
283
308
|
test_files: []
|
@@ -1,20 +0,0 @@
|
|
1
|
-
module EveOnline
|
2
|
-
module ESI
|
3
|
-
module Characters
|
4
|
-
class Character < Base
|
5
|
-
API_ENDPOINT = 'https://esi.tech.ccp.is/latest/characters/%s/?datasource=tranquility'.freeze
|
6
|
-
|
7
|
-
attr_reader :character_id
|
8
|
-
|
9
|
-
def initialize(character_id)
|
10
|
-
super()
|
11
|
-
@character_id = character_id
|
12
|
-
end
|
13
|
-
|
14
|
-
def url
|
15
|
-
API_ENDPOINT % character_id
|
16
|
-
end
|
17
|
-
end
|
18
|
-
end
|
19
|
-
end
|
20
|
-
end
|
@@ -1,51 +0,0 @@
|
|
1
|
-
require 'active_support/time'
|
2
|
-
|
3
|
-
module EveOnline
|
4
|
-
class SkillQueueEntry
|
5
|
-
attr_reader :options
|
6
|
-
|
7
|
-
def initialize(options)
|
8
|
-
@options = options
|
9
|
-
end
|
10
|
-
|
11
|
-
def as_json
|
12
|
-
{
|
13
|
-
queue_position: queue_position,
|
14
|
-
type_id: type_id,
|
15
|
-
level: level,
|
16
|
-
start_sp: start_sp,
|
17
|
-
end_sp: end_sp,
|
18
|
-
start_time: start_time,
|
19
|
-
end_time: end_time
|
20
|
-
}
|
21
|
-
end
|
22
|
-
|
23
|
-
def queue_position
|
24
|
-
options.fetch('@queuePosition').to_i
|
25
|
-
end
|
26
|
-
|
27
|
-
def type_id
|
28
|
-
options.fetch('@typeID').to_i
|
29
|
-
end
|
30
|
-
|
31
|
-
def level
|
32
|
-
options.fetch('@level').to_i
|
33
|
-
end
|
34
|
-
|
35
|
-
def start_sp
|
36
|
-
options.fetch('@startSP').to_i
|
37
|
-
end
|
38
|
-
|
39
|
-
def end_sp
|
40
|
-
options.fetch('@endSP').to_i
|
41
|
-
end
|
42
|
-
|
43
|
-
def start_time
|
44
|
-
ActiveSupport::TimeZone['UTC'].parse(options.fetch('@startTime'))
|
45
|
-
end
|
46
|
-
|
47
|
-
def end_time
|
48
|
-
ActiveSupport::TimeZone['UTC'].parse(options.fetch('@endTime'))
|
49
|
-
end
|
50
|
-
end
|
51
|
-
end
|