eve_online 0.18.0 → 0.19.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (54) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +36 -1
  3. data/Gemfile.lock +3 -7
  4. data/Gemfile.mutant.lock +20 -24
  5. data/README.md +208 -52
  6. data/TODO.md +2 -2
  7. data/eve_online.gemspec +1 -2
  8. data/lib/eve_online.rb +62 -35
  9. data/lib/eve_online/esi/alliance_corporations.rb +1 -1
  10. data/lib/eve_online/esi/alliances.rb +1 -1
  11. data/lib/eve_online/esi/ancestries.rb +1 -1
  12. data/lib/eve_online/esi/base.rb +72 -36
  13. data/lib/eve_online/esi/bloodlines.rb +1 -1
  14. data/lib/eve_online/esi/character_assets.rb +0 -4
  15. data/lib/eve_online/esi/character_assets_locations.rb +43 -0
  16. data/lib/eve_online/esi/character_assets_names.rb +43 -0
  17. data/lib/eve_online/esi/character_blueprints.rb +0 -4
  18. data/lib/eve_online/esi/character_bookmark_folders.rb +0 -4
  19. data/lib/eve_online/esi/character_bookmarks.rb +0 -4
  20. data/lib/eve_online/esi/character_implants.rb +1 -1
  21. data/lib/eve_online/esi/character_killmails_recent.rb +0 -4
  22. data/lib/eve_online/esi/character_wallet_journal.rb +0 -4
  23. data/lib/eve_online/esi/corporation_blueprints.rb +0 -4
  24. data/lib/eve_online/esi/corporation_industry_jobs.rb +0 -4
  25. data/lib/eve_online/esi/corporation_killmails_recent.rb +0 -4
  26. data/lib/eve_online/esi/corporation_orders.rb +0 -4
  27. data/lib/eve_online/esi/dogma_attributes.rb +1 -1
  28. data/lib/eve_online/esi/dogma_effect.rb +41 -0
  29. data/lib/eve_online/esi/dogma_effects.rb +19 -0
  30. data/lib/eve_online/esi/factions.rb +1 -1
  31. data/lib/eve_online/esi/models/asset_location.rb +23 -0
  32. data/lib/eve_online/esi/models/asset_name.rb +24 -0
  33. data/lib/eve_online/esi/models/constellation.rb +4 -15
  34. data/lib/eve_online/esi/models/dogma_attribute_short.rb +24 -0
  35. data/lib/eve_online/esi/models/dogma_attributes.rb +21 -0
  36. data/lib/eve_online/esi/models/dogma_effect.rb +118 -0
  37. data/lib/eve_online/esi/models/dogma_effect_modifier.rb +44 -0
  38. data/lib/eve_online/esi/models/dogma_effect_modifiers.rb +21 -0
  39. data/lib/eve_online/esi/models/dogma_effect_short.rb +24 -0
  40. data/lib/eve_online/esi/models/dogma_effects.rb +21 -0
  41. data/lib/eve_online/esi/models/position.rb +29 -0
  42. data/lib/eve_online/esi/models/type.rb +8 -2
  43. data/lib/eve_online/esi/races.rb +1 -1
  44. data/lib/eve_online/esi/universe_constellation.rb +3 -3
  45. data/lib/eve_online/esi/universe_constellations.rb +1 -1
  46. data/lib/eve_online/esi/universe_region.rb +1 -1
  47. data/lib/eve_online/esi/universe_regions.rb +1 -1
  48. data/lib/eve_online/esi/universe_systems.rb +1 -1
  49. data/lib/eve_online/esi/universe_type.rb +2 -2
  50. data/lib/eve_online/esi/universe_types.rb +1 -5
  51. data/lib/eve_online/esi/war_killmails.rb +0 -4
  52. data/lib/eve_online/esi/wars.rb +1 -1
  53. data/lib/eve_online/version.rb +1 -1
  54. metadata +17 -17
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4cfcf5d53856441ce77e196540d444274bb85983d3e21f59fe8fe055ad1c8cf3
4
- data.tar.gz: fc8b99941ea4281d94341dff860c86027d83cfb51411da0b22816c1c76370c02
3
+ metadata.gz: 8ea9c66ce5c8b66cff3e85f8c5fbadad3387dca9964bd0f94081ab1c9424da48
4
+ data.tar.gz: b08ea58f4c6fe3282af0371a76dbdd9ec612ae11de5a21a826220b533845a070
5
5
  SHA512:
6
- metadata.gz: b047f8b03a1fce01689ec02d075f09b3fd83cbbb978f22d2bac6b04f4015716dabac16342a3914476fc3952de43c361c40608ab8b16ebcaf0cb2991dcb279578
7
- data.tar.gz: a5d31f1c67bec23d6d1411ff26d88a6eadb436768f722095cb71ade44abc9463bfab226865c6ff87b654168cc51bc61b9ed90bfcb65968007eba2b675426b775
6
+ metadata.gz: 3ff3242caef5b4451da51868f402f0924bfac87b9b503a44943450bcc8732cfd96ef29560ab3eeece7c9a191c952185f69ecff92a0f4b918e1440dcd87d34d9c
7
+ data.tar.gz: 74a457edf29104186baf7c19fa2ffcbf6116e13b6fff4621ef5bf800f0c9b38bc30cde6196eef071fb3b868fc37ac829fcabc8474d9b970e0eeab5a3d84e8d79
data/CHANGELOG.md CHANGED
@@ -1,5 +1,41 @@
1
1
  # Changelog
2
2
 
3
+ ## v0.19.0
4
+
5
+ * Replace `faraday` gem with ruby `net/http`
6
+ * Add `Etag` / `If-None-Match` support for caching
7
+ * Add `Accept-Language` header support
8
+ * Add `EveOnline::ESI::CharacterAssetsLocations`
9
+ * Add `EveOnline::ESI::Models::Position`
10
+ * Add `EveOnline::ESI::Models::AssetLocation`
11
+ * Add `EveOnline::ESI::Models::AssetName`
12
+ * Add `EveOnline::ESI::CharacterAssetsNames`
13
+ * Remove `EveOnline::ESI::UniverseConstellation#position_x, #position_y, #position_z`. Use new `#position` instead.
14
+ * Add `EveOnline::ESI::UniverseType#dogma_attributes`
15
+ * Add `EveOnline::ESI::UniverseType#dogma_effects`
16
+ * Add `EveOnline::ESI::Models::DogmaAttributeShort`
17
+ * Add `EveOnline::ESI::Models::DogmaEffectShort`
18
+ * Add `EveOnline::ESI::Models::Type#dogma_attributes`
19
+ * Add `EveOnline::ESI::Models::Type#dogma_effects`
20
+ * Add `EveOnline::ESI::Models::DogmaAttributes`
21
+ * Add `EveOnline::ESI::Models::DogmaEffects`
22
+ * Add `EveOnline::ESI::Models::DogmaEffect`
23
+ * Add `EveOnline::ESI::DogmaEffects`
24
+ * Add `EveOnline::ESI::DogmaEffect`
25
+ * Rename `EveOnline::ESI::AllianceCorporations#corporations` to `#corporation_ids`
26
+ * Rename `EveOnline::ESI::Alliances#alliances` to `#alliance_ids`
27
+ * Rename `EveOnline::ESI::Wars#wars_ids` to `#war_ids`
28
+ * Rename `EveOnline::ESI::UniverseTypes#universe_types_ids` to `#universe_type_ids`
29
+ * Rename `EveOnline::ESI::DogmaEffects#effects_ids` to `#effect_ids`
30
+ * Rename `EveOnline::ESI::UniverseSystems#universe_systems_ids` to `#universe_system_ids`
31
+ * Rename `EveOnline::ESI::UniverseRegions#universe_regions_ids` to `#universe_region_ids`
32
+ * Rename `EveOnline::ESI::UniverseConstellations#constellations_ids` to `#constellation_ids`
33
+ * Rename `EveOnline::ESI::DogmaAttributes#attributes` to `#attribute_ids`
34
+ * Rename `EveOnline::ESI::CharacterImplants#implants` to `#implant_ids`
35
+ * Add `EveOnline::ESI::DogmaEffect`
36
+ * Add `EveOnline::ESI::Models::DogmaEffectModifier`
37
+ * Add `EveOnline::ESI::Models::DogmaEffectModifiers`
38
+
3
39
  ## v0.18.0
4
40
 
5
41
  * Add `EveOnline::ESI::Models::CharacterShip`
@@ -26,7 +62,6 @@
26
62
  * Remove `EveOnline::ESI::AlliancesNames`
27
63
  * Lint `README.md`, `CHANGELOG.md` and `TODO.md` with `mdl` gem
28
64
  * Add datasource support. Just add `datasource: tranquility` or `datasource: singularity` to options. Default is `tranquility`.
29
- * Allow change response parser from `JSON` to any json parser compatible with gem `json`. Add `parser: Oj` for `Oj` to default options hash to enable.
30
65
  * Rename `EveOnline::ESI::Models::DogmaAttribute#id` to `#attribute_id`
31
66
  * Rename input `attribute_id:` to `id:` in `EveOnline::ESI::DogmaAttribute`
32
67
  * Rename `EveOnline::ESI::Models::IndustryJob` to `EveOnline::ESI::Models::CharacterIndustryJob`
data/Gemfile.lock CHANGED
@@ -1,9 +1,8 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- eve_online (0.17.0)
4
+ eve_online (0.19.0)
5
5
  activesupport (>= 4.2.0)
6
- faraday
7
6
  json
8
7
  memoist
9
8
 
@@ -25,8 +24,6 @@ GEM
25
24
  safe_yaml (~> 1.0.0)
26
25
  diff-lcs (1.3)
27
26
  docile (1.3.1)
28
- faraday (0.15.2)
29
- multipart-post (>= 1.2, < 3)
30
27
  hashdiff (0.3.7)
31
28
  i18n (1.1.0)
32
29
  concurrent-ruby (~> 1.0)
@@ -44,7 +41,6 @@ GEM
44
41
  mixlib-cli (1.7.0)
45
42
  mixlib-config (2.2.13)
46
43
  tomlrb
47
- multipart-post (2.0.0)
48
44
  nokogiri (1.8.4)
49
45
  mini_portile2 (~> 2.3.0)
50
46
  parallel (1.12.1)
@@ -73,7 +69,7 @@ GEM
73
69
  diff-lcs (>= 1.2.0, < 2.0)
74
70
  rspec-support (~> 3.8.0)
75
71
  rspec-support (3.8.0)
76
- rubocop (0.59.1)
72
+ rubocop (0.59.2)
77
73
  jaro_winkler (~> 1.5.1)
78
74
  parallel (~> 1.10)
79
75
  parser (>= 2.5, != 2.5.1.1)
@@ -121,4 +117,4 @@ DEPENDENCIES
121
117
  webmock
122
118
 
123
119
  BUNDLED WITH
124
- 1.16.4
120
+ 1.16.5
data/Gemfile.mutant.lock CHANGED
@@ -1,9 +1,8 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- eve_online (0.16.0)
4
+ eve_online (0.18.0)
5
5
  activesupport (>= 4.2.0)
6
- faraday
7
6
  json
8
7
  memoist
9
8
 
@@ -35,8 +34,6 @@ GEM
35
34
  diff-lcs (1.3)
36
35
  docile (1.3.1)
37
36
  equalizer (0.0.11)
38
- faraday (0.15.2)
39
- multipart-post (>= 1.2, < 3)
40
37
  hashdiff (0.3.7)
41
38
  i18n (1.1.0)
42
39
  concurrent-ruby (~> 1.0)
@@ -64,8 +61,7 @@ GEM
64
61
  equalizer (~> 0.0.9)
65
62
  ice_nine (~> 0.11.0)
66
63
  procto (~> 0.0.2)
67
- multipart-post (2.0.0)
68
- mutant (0.8.15)
64
+ mutant (0.8.17)
69
65
  abstract_type (~> 0.0.7)
70
66
  adamantium (~> 0.2.0)
71
67
  anima (~> 0.3.0)
@@ -77,38 +73,38 @@ GEM
77
73
  memoizable (~> 0.4.2)
78
74
  morpher (~> 0.2.6)
79
75
  parallel (~> 1.3)
80
- parser (>= 2.3.1.4, < 2.5)
76
+ parser (~> 2.5.1)
81
77
  procto (~> 0.0.2)
82
78
  regexp_parser (~> 0.4.9)
83
79
  unparser (~> 0.2.5)
84
- mutant-rspec (0.8.15)
85
- mutant (~> 0.8.15)
86
- rspec-core (>= 3.4.0, < 3.8.0)
80
+ mutant-rspec (0.8.17)
81
+ mutant (~> 0.8.17)
82
+ rspec-core (>= 3.4.0, < 4.0.0)
87
83
  nokogiri (1.8.4)
88
84
  mini_portile2 (~> 2.3.0)
89
85
  parallel (1.12.1)
90
- parser (2.4.0.2)
91
- ast (~> 2.3)
86
+ parser (2.5.1.2)
87
+ ast (~> 2.4.0)
92
88
  procto (0.0.3)
93
89
  public_suffix (3.0.3)
94
90
  rake (12.3.1)
95
91
  regexp_parser (0.4.13)
96
- rspec (3.7.0)
97
- rspec-core (~> 3.7.0)
98
- rspec-expectations (~> 3.7.0)
99
- rspec-mocks (~> 3.7.0)
100
- rspec-core (3.7.1)
101
- rspec-support (~> 3.7.0)
102
- rspec-expectations (3.7.0)
92
+ rspec (3.8.0)
93
+ rspec-core (~> 3.8.0)
94
+ rspec-expectations (~> 3.8.0)
95
+ rspec-mocks (~> 3.8.0)
96
+ rspec-core (3.8.0)
97
+ rspec-support (~> 3.8.0)
98
+ rspec-expectations (3.8.1)
103
99
  diff-lcs (>= 1.2.0, < 2.0)
104
- rspec-support (~> 3.7.0)
100
+ rspec-support (~> 3.8.0)
105
101
  rspec-its (1.2.0)
106
102
  rspec-core (>= 3.0.0)
107
103
  rspec-expectations (>= 3.0.0)
108
- rspec-mocks (3.7.0)
104
+ rspec-mocks (3.8.0)
109
105
  diff-lcs (>= 1.2.0, < 2.0)
110
- rspec-support (~> 3.7.0)
111
- rspec-support (3.7.1)
106
+ rspec-support (~> 3.8.0)
107
+ rspec-support (3.8.0)
112
108
  safe_yaml (1.0.4)
113
109
  simplecov (0.16.1)
114
110
  docile (~> 1.1)
@@ -151,4 +147,4 @@ DEPENDENCIES
151
147
  webmock
152
148
 
153
149
  BUNDLED WITH
154
- 1.16.4
150
+ 1.16.5
data/README.md CHANGED
@@ -8,9 +8,9 @@
8
8
 
9
9
  This gem implement Ruby API for EveOnline MMORPG (ESI).
10
10
 
11
- Looking for [EveOnline SSO OAuth2 Strategy for OmniAuth](https://github.com/biow0lf/omniauth-eve_online-sso)?
11
+ Looking for [EveOnline SSO OAuth2 Strategy for OmniAuth](https://github.com/evemonk/omniauth-eve_online-sso)?
12
12
 
13
- This gem was extracted from [EveMonk](http://evemonk.com). Source code of evemonk backend published [here](https://github.com/biow0lf/evemonk).
13
+ This gem was extracted from [EveMonk](http://evemonk.com). Source code of evemonk backend published [here](https://github.com/evemonk/evemonk).
14
14
 
15
15
  ## TOC
16
16
 
@@ -72,9 +72,9 @@ alliances = EveOnline::ESI::Alliances.new
72
72
 
73
73
  alliances.scope # => nil
74
74
 
75
- alliances.alliances.size # => 3013
75
+ alliances.alliance_ids.size # => 3013
76
76
 
77
- alliances.alliances.first # => 1354830081
77
+ alliances.alliance_ids.first # => 1354830081
78
78
  ```
79
79
 
80
80
  #### Get alliance information
@@ -112,9 +112,9 @@ alliance_corporations = EveOnline::ESI::AllianceCorporations.new(options)
112
112
 
113
113
  alliance_corporations.scope # => nil
114
114
 
115
- alliance_corporations.corporations.size # => 33
115
+ alliance_corporations.corporation_ids.size # => 33
116
116
 
117
- alliance_corporations.corporations.first # => 98134807
117
+ alliance_corporations.corporation_ids.first # => 98134807
118
118
  ```
119
119
 
120
120
  #### Get alliance icon
@@ -173,8 +173,50 @@ asset.type_id # => 1010
173
173
 
174
174
  #### Get character asset locations
175
175
 
176
+ ```ruby
177
+ options = { token: 'token123', character_id: 1337512245, item_ids: [1001215602246] }
178
+
179
+ character_assets_locations = EveOnline::ESI::CharacterAssetsLocations.new(options)
180
+
181
+ character_assets_locations.scope # => "esi-assets.read_assets.v1"
182
+
183
+ character_assets_locations.assets_locations.size # => 1
184
+
185
+ asset_location = character_assets_locations.assets_locations.first
186
+
187
+ asset_location.as_json # => {:item_id=>1001215602246}
188
+
189
+ asset_location.item_id # => 1001215602246
190
+
191
+ asset_location.position.as_json # => {:x=>-928621543221.3319,
192
+ # :y=>297645715142.40234,
193
+ # :z=>-971212198300.4812}
194
+
195
+ asset_location.position.x # => -928621543221.3319
196
+ asset_location.position.y # => 297645715142.40234
197
+ asset_location.position.z # => -971212198300.4812
198
+ ```
199
+
176
200
  #### Get character asset names
177
201
 
202
+ ```ruby
203
+ options = { token: 'token123', character_id: 1337512245, item_ids: [1001215602246] }
204
+
205
+ character_assets_names = EveOnline::ESI::CharacterAssetsNames.new(options)
206
+
207
+ character_assets_names.scope # => "esi-assets.read_assets.v1"
208
+
209
+ character_assets_names.assets_names.size # => 1
210
+
211
+ character_asset_name = character_assets_names.assets_names.first
212
+
213
+ character_asset_name.as_json # => {:item_id=>1001215602246,
214
+ # :name=>"HOLE"}
215
+
216
+ character_asset_name.item_id # => 1001215602246
217
+ character_asset_name.name # => "HOLE"
218
+ ```
219
+
178
220
  #### Get corporation assets
179
221
 
180
222
  #### Get corporation asset locations
@@ -517,9 +559,9 @@ character_implants = EveOnline::ESI::CharacterImplants.new(options)
517
559
 
518
560
  character_implants.scope # => "esi-clones.read_implants.v1"
519
561
 
520
- character_implants.implants.size # => 5
562
+ character_implants.implant_ids.size # => 5
521
563
 
522
- character_implants.implants # => [9899, 9941, 9942, 9943, 9956]
564
+ character_implants.implant_ids # => [9899, 9941, 9942, 9943, 9956]
523
565
  ```
524
566
 
525
567
  ### Contacts
@@ -689,9 +731,9 @@ dogma_attributes = EveOnline::ESI::DogmaAttributes.new
689
731
 
690
732
  dogma_attributes.scope # => nil
691
733
 
692
- dogma_attributes.attributes.size # => 2385
734
+ dogma_attributes.attribute_ids.size # => 2385
693
735
 
694
- dogma_attributes.attributes.first # => 2
736
+ dogma_attributes.attribute_ids.first # => 2
695
737
  ```
696
738
 
697
739
  #### Get attribute information
@@ -730,8 +772,86 @@ dogma_attribute.unit_id # => nil
730
772
 
731
773
  #### Get effects
732
774
 
775
+ ```ruby
776
+ dogma_effects = EveOnline::ESI::DogmaEffects.new
777
+
778
+ dogma_effects.scope # => nil
779
+
780
+ dogma_effects.effects_ids.size # => 4123
781
+
782
+ dogma_effects.effects_ids.first # => 4
783
+ ```
784
+
733
785
  #### Get effect information
734
786
 
787
+ ```ruby
788
+ options = { id: 6717 }
789
+
790
+ dogma_effect = EveOnline::ESI::DogmaEffect.new(options)
791
+
792
+ dogma_effect.scope # => nil
793
+
794
+ dogma_effect.as_json # => {:description=>"Automatically generated effect",
795
+ # :disallow_auto_repeat=>nil,
796
+ # :discharge_attribute_id=>nil,
797
+ # :display_name=>"",
798
+ # :duration_attribute_id=>nil,
799
+ # :effect_category=>0,
800
+ # :effect_id=>6717,
801
+ # :electronic_chance=>nil,
802
+ # :falloff_attribute_id=>nil,
803
+ # :icon_id=>nil,
804
+ # :is_assistance=>nil,
805
+ # :is_offensive=>nil,
806
+ # :is_warp_safe=>nil,
807
+ # :name=>"roleBonusIceOreMiningDurationCap",
808
+ # :post_expression=>19291,
809
+ # :pre_expression=>19290,
810
+ # :published=>nil,
811
+ # :range_attribute_id=>nil,
812
+ # :range_chance=>nil,
813
+ # :tracking_speed_attribute_id=>nil}
814
+
815
+ dogma_effect.description # => "Automatically generated effect"
816
+ dogma_effect.disallow_auto_repeat # => nil
817
+ dogma_effect.discharge_attribute_id # => nil
818
+ dogma_effect.display_name # => ""
819
+ dogma_effect.duration_attribute_id # => nil
820
+ dogma_effect.effect_category # => 0
821
+ dogma_effect.effect_id # => 6717
822
+ dogma_effect.electronic_chance # => nil
823
+ dogma_effect.falloff_attribute_id # => nil
824
+ dogma_effect.icon_id # => nil
825
+ dogma_effect.is_assistance # => nil
826
+ dogma_effect.is_offensive # => nil
827
+ dogma_effect.is_warp_safe # => nil
828
+ dogma_effect.name # => "roleBonusIceOreMiningDurationCap"
829
+ dogma_effect.post_expression # => 19291
830
+ dogma_effect.pre_expression # => 19290
831
+ dogma_effect.published # => nil
832
+ dogma_effect.range_attribute_id # => nil
833
+ dogma_effect.range_chance # => nil
834
+ dogma_effect.tracking_speed_attribute_id # => nil
835
+
836
+ dogma_effect.modifiers.size # => 4
837
+
838
+ modifier = dogma_effect.modifiers.first
839
+
840
+ modifier.as_json # => {:domain=>"shipID",
841
+ # :effect_id=>nil,
842
+ # :func=>"LocationRequiredSkillModifier",
843
+ # :modified_attribute_id=>73,
844
+ # :modifying_attribute_id=>2458,
845
+ # :operator=>6}
846
+
847
+ modifier.domain # => "shipID"
848
+ modifier.effect_id # => nil
849
+ modifier.func # => "LocationRequiredSkillModifier"
850
+ modifier.modified_attribute_id # => 73
851
+ modifier.modifying_attribute_id # => 2458
852
+ modifier.operator # => 6
853
+ ```
854
+
735
855
  ### Faction Warfare
736
856
 
737
857
  #### Overview of a character involved in faction warfare
@@ -1365,7 +1485,9 @@ server_status.vip # => nil
1365
1485
  #### Get ancestries
1366
1486
 
1367
1487
  ```ruby
1368
- ancestries = EveOnline::ESI::Ancestries.new
1488
+ options = { language: 'en-us' }
1489
+
1490
+ ancestries = EveOnline::ESI::Ancestries.new(options)
1369
1491
 
1370
1492
  ancestries.scope # => nil
1371
1493
 
@@ -1386,8 +1508,6 @@ ancestry.icon_id # => 1664
1386
1508
  ancestry.ancestry_id # => 24
1387
1509
  ancestry.name # => "Slave Child"
1388
1510
  ancestry.short_description # => "Torn from the cold and brought to the warmth of a new life."
1389
-
1390
- # TODO: add languages
1391
1511
  ```
1392
1512
 
1393
1513
  #### Get asteroid belt information
@@ -1395,7 +1515,9 @@ ancestry.short_description # => "Torn from the cold and brought to the warmth of
1395
1515
  #### Get bloodlines
1396
1516
 
1397
1517
  ```ruby
1398
- bloodlines = EveOnline::ESI::Bloodlines.new
1518
+ options = { language: 'en-us' }
1519
+
1520
+ bloodlines = EveOnline::ESI::Bloodlines.new(options)
1399
1521
 
1400
1522
  bloodlines.scope # => nil
1401
1523
 
@@ -1426,8 +1548,6 @@ bloodline.perception # => 9
1426
1548
  bloodline.race_id # => 2
1427
1549
  bloodline.ship_type_id # => 588
1428
1550
  bloodline.willpower # => 7
1429
-
1430
- # TODO: add languages
1431
1551
  ```
1432
1552
 
1433
1553
  #### Get item categories
@@ -1441,15 +1561,15 @@ constellations = EveOnline::ESI::UniverseConstellations.new
1441
1561
 
1442
1562
  constellations.scope # => nil
1443
1563
 
1444
- constellations.constellations_ids.size # => 1146
1564
+ constellations.constellation_ids.size # => 1146
1445
1565
 
1446
- constellations.constellations_ids.first # => 20000001
1566
+ constellations.constellation_ids.first # => 20000001
1447
1567
  ```
1448
1568
 
1449
1569
  #### Get constellation information
1450
1570
 
1451
1571
  ```ruby
1452
- options = { id: 20000001 }
1572
+ options = { id: 20000001, language: 'en-us' }
1453
1573
 
1454
1574
  constellation = EveOnline::ESI::UniverseConstellation.new(options)
1455
1575
 
@@ -1457,27 +1577,29 @@ constellation.scope # => nil
1457
1577
 
1458
1578
  constellation.as_json # => {:constellation_id=>20000001,
1459
1579
  # :name=>"San Matar",
1460
- # :position_x=>-9.404655970099134e+16,
1461
- # :position_y=>4.952015315379885e+16,
1462
- # :position_z=>-4.273873181840197e+16,
1463
1580
  # :region_id=>10000001,
1464
1581
  # :systems=>[30000001, 30000002, 30000003, 30000004, 30000005, 30000006, 30000007, 30000008]}
1465
1582
 
1466
1583
  constellation.constellation_id # => 20000001
1467
1584
  constellation.name # => "San Matar"
1468
- constellation.position_x # => -9.404655970099134e+16
1469
- constellation.position_y # => 4.952015315379885e+16
1470
- constellation.position_z # => -4.273873181840197e+16
1471
1585
  constellation.region_id # => 10000001
1472
1586
  constellation.systems # => [30000001, 30000002, 30000003, 30000004, 30000005, 30000006, 30000007, 30000008]
1473
1587
 
1474
- # TODO: translations
1588
+ constellation.position.as_json # => {:x=>-9.404655970099134e+16,
1589
+ # :y=>4.952015315379885e+16,
1590
+ # :z=>-4.273873181840197e+16}
1591
+
1592
+ constellation.position.x # => -9.404655970099134e+16
1593
+ constellation.position.y # => 4.952015315379885e+16
1594
+ constellation.position.z # => -4.273873181840197e+16
1475
1595
  ```
1476
1596
 
1477
1597
  #### Get factions
1478
1598
 
1479
1599
  ```ruby
1480
- factions = EveOnline::ESI::Factions.new
1600
+ options = { language: 'en-us' }
1601
+
1602
+ factions = EveOnline::ESI::Factions.new(options)
1481
1603
 
1482
1604
  factions.scope # => nil
1483
1605
 
@@ -1506,8 +1628,6 @@ faction.size_factor # => 5.0
1506
1628
  faction.solar_system_id # => 30002544
1507
1629
  faction.station_count # => 570
1508
1630
  faction.station_system_count # => 291
1509
-
1510
- # TODO: add languages
1511
1631
  ```
1512
1632
 
1513
1633
  #### Get graphics
@@ -1529,7 +1649,9 @@ faction.station_system_count # => 291
1529
1649
  #### Get character races
1530
1650
 
1531
1651
  ```ruby
1532
- races = EveOnline::ESI::Races.new
1652
+ options = { language: 'en-us' }
1653
+
1654
+ races = EveOnline::ESI::Races.new(options)
1533
1655
 
1534
1656
  races.scope # => nil
1535
1657
 
@@ -1546,8 +1668,6 @@ race.alliance_id # => 500002
1546
1668
  race.description # => "Once a thriving tribal civilization, the Minmatar..."
1547
1669
  race.name # => "Minmatar"
1548
1670
  race.race_id # => 2
1549
-
1550
- # TODO: add languages
1551
1671
  ```
1552
1672
 
1553
1673
  #### Get regions
@@ -1557,15 +1677,15 @@ regions = EveOnline::ESI::UniverseRegions.new
1557
1677
 
1558
1678
  regions.scope # => nil
1559
1679
 
1560
- regions.universe_regions_ids.size # => 106
1680
+ regions.universe_region_ids.size # => 106
1561
1681
 
1562
- regions.universe_regions_ids.first # => 10000001
1682
+ regions.universe_region_ids.first # => 10000001
1563
1683
  ```
1564
1684
 
1565
1685
  #### Get region information
1566
1686
 
1567
1687
  ```ruby
1568
- options = { id: 10000001 }
1688
+ options = { id: 10000001, language: 'en-us' }
1569
1689
 
1570
1690
  region = EveOnline::ESI::UniverseRegion.new(options)
1571
1691
 
@@ -1580,8 +1700,6 @@ region.constellations # => [20000001,20000002,20000003,20000016]
1580
1700
  region.description # => "The Derelik region..."
1581
1701
  region.name # => "Derelik"
1582
1702
  region.region_id # => 10000001
1583
-
1584
- # TODO: translations
1585
1703
  ```
1586
1704
 
1587
1705
  #### Get stargate information
@@ -1605,9 +1723,9 @@ systems = EveOnline::ESI::UniverseSystems.new
1605
1723
 
1606
1724
  systems.scope # => nil
1607
1725
 
1608
- systems.universe_systems_ids.size # => 8285
1726
+ systems.universe_system_ids.size # => 8285
1609
1727
 
1610
- systems.universe_systems_ids.first # => 30000001
1728
+ systems.universe_system_ids.first # => 30000001
1611
1729
  ```
1612
1730
 
1613
1731
  #### Get solar system information
@@ -1625,15 +1743,15 @@ types.page # => 1
1625
1743
 
1626
1744
  types.total_pages # => 35
1627
1745
 
1628
- types.universe_types_ids.size # => 1000
1746
+ types.universe_type_ids.size # => 1000
1629
1747
 
1630
- types.universe_types_ids.first # => 0
1748
+ types.universe_type_ids.first # => 0
1631
1749
  ```
1632
1750
 
1633
1751
  #### Get type information
1634
1752
 
1635
1753
  ```ruby
1636
- options = { id: 192 }
1754
+ options = { id: 192, language: 'en-us' }
1637
1755
 
1638
1756
  type = EveOnline::ESI::UniverseType.new(options)
1639
1757
 
@@ -1669,9 +1787,25 @@ type.radius # => 1.0
1669
1787
  type.type_id # => 192
1670
1788
  type.volume # => 0.0125
1671
1789
 
1672
- # TODO: dogma_attributes
1673
- # TODO: dogma_effects
1674
- # TODO: add localization
1790
+ type.dogma_attributes.size # => 17
1791
+
1792
+ type_dogma_attribute = type.dogma_attributes.first
1793
+
1794
+ type_dogma_attribute.as_json # => {:attribute_id=>128,
1795
+ # :value=>2.0}
1796
+
1797
+ dogma_attribute.attribute_id # => 128
1798
+ dogma_attribute.value # => 2.0
1799
+
1800
+ type.dogma_effects.size # => 3
1801
+
1802
+ type_dogma_effect = type.dogma_effects.first
1803
+
1804
+ type_dogma_effect.as_json # => {:effect_id=>596,
1805
+ # :is_default=>false}
1806
+
1807
+ type_dogma_effect.effect_id # => 596
1808
+ type_dogma_effect.is_default # => false
1675
1809
  ```
1676
1810
 
1677
1811
  ### User Interface
@@ -1755,9 +1889,9 @@ wars = EveOnline::ESI::Wars.new
1755
1889
 
1756
1890
  wars.scope # => nil
1757
1891
 
1758
- wars.wars_ids.size # => 2000
1892
+ wars.war_ids.size # => 2000
1759
1893
 
1760
- wars.wars_ids.first # => 615639
1894
+ wars.war_ids.first # => 615639
1761
1895
 
1762
1896
  # TODO: max_war_id
1763
1897
  ```
@@ -1818,13 +1952,13 @@ List of exceptions:
1818
1952
 
1819
1953
  ## Timeouts
1820
1954
 
1821
- `eve_online` gem uses `faraday` for network request. `faraday` configured with:
1955
+ `eve_online` gem uses `net/http` for network request. `net/http` configured with:
1822
1956
 
1823
1957
  ```ruby
1824
- faraday = Faraday.new
1958
+ http = Net::HTTP.new
1825
1959
 
1826
- faraday.options.timeout = 60
1827
- faraday.options.open_timeout = 60
1960
+ http.read_timeout = 60
1961
+ http.open_timeout = 60
1828
1962
  ```
1829
1963
 
1830
1964
  You can configure default timeouts with adding `read_timeout:` and `open_timeout:` to default hash with options:
@@ -1859,6 +1993,28 @@ options = { datasource: 'singularity' }
1859
1993
  races = EveOnline::ESI::Races.new(options)
1860
1994
  ```
1861
1995
 
1996
+ ## Languages support
1997
+
1998
+ Default language is `en-us`. Supported languages: `de`, `en-us`, `fr`, `ja`, `ru`, `zh`.
1999
+
2000
+ If you want change it, for e.g., to `de`, add `language: 'de'` to default hash with options:
2001
+
2002
+ ```ruby
2003
+ options = { language: 'de' }
2004
+
2005
+ races = EveOnline::ESI::Races.new(options)
2006
+ ```
2007
+
2008
+ ## Oj as JSON Parser
2009
+
2010
+ ```ruby
2011
+ require 'oj'
2012
+
2013
+ Oj.mimic_JSON()
2014
+
2015
+ races = EveOnline::ESI::Races.new
2016
+ ```
2017
+
1862
2018
  ## Useful links
1863
2019
 
1864
2020
  * [BREAKING CHANGES AND YOU - HOW TO USE ALT-ROUTES TO ENHANCE YOUR SANITY](https://developers.eveonline.com/blog/article/breaking-changes-and-you)
@@ -1876,7 +2032,7 @@ To install this gem onto your local machine, run `bundle exec rake install`. To
1876
2032
 
1877
2033
  ## Contributing
1878
2034
 
1879
- Issue reports and pull requests are welcome on GitHub at <https://github.com/biow0lf/eve_online>.
2035
+ Issue reports and pull requests are welcome on GitHub at <https://github.com/evemonk/eve_online>.
1880
2036
 
1881
2037
  ## Author
1882
2038