eve_online 0.4.0 → 0.5.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 98c64387577199f7e1e4206c5dccd26b2ca8cf76
4
- data.tar.gz: b754ef50b32369bd7eaea35405fc4b7aedd1c3b9
3
+ metadata.gz: fdf75e267928f397f239f01bf408e8677f4fc585
4
+ data.tar.gz: 7e611e52cc3180998717127139c46c085df84e18
5
5
  SHA512:
6
- metadata.gz: 2b54c122e27c7be950b76d2964594d248ff68c619091c99e3596fc6e1dc9ab379d445706eb99928b821209711d422517eb07cc86ef5496fb66176b3f3a336193
7
- data.tar.gz: 3f6683afe931ca1ee9383cc526a20648b21cc9de4d5c59dd758770bc1ab361105611c368c19433c3a6128f7d90619c12ad57ced1bf7a607a56021ec117a56bd6
6
+ metadata.gz: 849cdff8b02c5764d8fd72d65c874379965b69314b64e1294ce845221406c25761f939e6c486ecc862fd4944f3c3ab0e45772d6f78b097c7c20bc22444dbff5c
7
+ data.tar.gz: d11af2cab0f45d39d7629231084cce86d2d44f504bf582ba89d834d468df4e80178230117b3806e395213efabee04da1d2a7437cac27a4472bf3674b63123512
data/.travis.yml CHANGED
@@ -6,6 +6,7 @@ rvm:
6
6
  - 2.0
7
7
  - 2.1
8
8
  - 2.2
9
+ - 2.3.0
9
10
  - rbx
10
11
  - jruby
11
12
 
data/README.md CHANGED
@@ -31,6 +31,7 @@ Or install it yourself as:
31
31
  * MRI 2.0
32
32
  * MRI 2.1
33
33
  * MRI 2.2
34
+ * MRI 2.3
34
35
  * Rubinius (latest via RVM)
35
36
  * JRuby (latest via RVM)
36
37
 
@@ -40,7 +41,8 @@ Server status:
40
41
 
41
42
  ```ruby
42
43
  status = EveOnline::Server::Status.new
43
- status.as_json # => {:current_time=>Mon, 23 Nov 2015 18:18:29 UTC +00:00, :cached_until=>Mon, 23 Nov 2015 18:19:44 UTC +00:00, :server_open=>true, :online_players=>25611}
44
+ status.as_json
45
+ # => {:current_time=>Mon, 23 Nov 2015 18:18:29 UTC +00:00, :cached_until=>Mon, 23 Nov 2015 18:19:44 UTC +00:00, :server_open=>true, :online_players=>25611}
44
46
 
45
47
  status.current_time # => Mon, 23 Nov 2015 18:18:29 UTC +00:00
46
48
  status.cached_until # => Mon, 23 Nov 2015 18:19:44 UTC +00:00
@@ -102,7 +104,7 @@ v_code = '9ce9970b18d07586ead3d052e5b83bc8db303171a28a6f754cf35d9e6b66af17'
102
104
 
103
105
  api_key_info = EveOnline::Account::ApiKeyInfo.new(key_id, v_code)
104
106
 
105
- api_key_info.expires # => ""
107
+ api_key_info.expires # => Fri, 02 Dec 2016 18:13:59 UTC +00:00
106
108
  api_key_info.type # => "Account"
107
109
  api_key_info.access_mask # => 1073741823
108
110
  api_key_info.version # => 2
@@ -143,6 +145,70 @@ account_balance.cached_until # => Wed, 02 Dec 2015 20:40:42 UTC +00:00
143
145
  account_balance.version # => 2
144
146
  ```
145
147
 
148
+ Asset List:
149
+ ```ruby
150
+ # TODO:
151
+ ```
152
+
153
+ Calendar Event Attendees:
154
+ ```ruby
155
+ key_id = 1234567
156
+ v_code = '9ce9970b18d07586ead3d052e5b83bc8db303171a28a6f754cf35d9e6b66af17'
157
+ character_id = 90729314
158
+ event_id = 1234567
159
+
160
+ cea = EveOnline::Characters::CalendarEventAttendees.new(key_id, v_code, character_id, event_id)
161
+
162
+ cea.current_time # => Mon, 21 Dec 2015 18:36:33 UTC +00:00
163
+ cea.cached_until # => Mon, 21 Dec 2015 18:36:33 UTC +00:00
164
+ cea.version # => 2
165
+
166
+ # TODO: finish this
167
+
168
+ ````
169
+
170
+ Upcoming Calender Events:
171
+ ```ruby
172
+ key_id = 1234567
173
+ v_code = '9ce9970b18d07586ead3d052e5b83bc8db303171a28a6f754cf35d9e6b66af17'
174
+ character_id = 90729314
175
+
176
+ upcoming_events = EveOnline::Characters::UpcomingCalendarEvents.new(key_id, v_code, character_id)
177
+
178
+ upcoming_events.current_time # => Thu, 17 Dec 2015 20:43:46 UTC +00:00
179
+ upcoming_events.cached_until # => Thu, 17 Dec 2015 21:40:46 UTC +00:00
180
+ upcoming_events.version # => 2
181
+
182
+ upcoming_events.events.size # => 2
183
+
184
+ event = upcoming_events.events.first
185
+ event.as_json
186
+ # => {:event_id=>1234567, :owner_id=>98765432, :owner_name=>"MyCorp", :event_date=>Sat, 26 Dec 2015 19:47:29 UTC +00:00, :event_title=>"Control tower in 99-999", :duration=>60, :importance=>false, :response=>"Undecided", :event_text=>"<b>Minmatar Control Tower</b> will run out of fuel and go offline...", :owner_type_id=>2}
187
+
188
+ event.event_id # => 1234567
189
+ event.owner_id # => 98765432
190
+ event.owner_name # => "MyCorp"
191
+ event.event_date # => Sat, 26 Dec 2015 19:47:29 UTC +00:00
192
+ event.event_title # => "Control tower in 99-999"
193
+ event.duration # => 60
194
+ event.importance # => false
195
+ event.response # => "Undecided"
196
+ event.event_text # => "<b>Minmatar Control Tower</b> will run out of fuel and go offline..."
197
+ event.owner_type_id # => 2
198
+ ```
199
+
200
+ Skill Tree:
201
+ ```ruby
202
+ skill_tree = EveOnline::Eve::SkillTree.new
203
+
204
+ skill_tree.current_time # => Mon, 21 Dec 2015 22:24:48 UTC +00:00
205
+ skill_tree.cached_until # => Tue, 22 Dec 2015 22:24:48 UTC +00:00
206
+ skill_tree.version # => 2
207
+
208
+ # TODO: finish this
209
+
210
+ ```
211
+
146
212
  ## Development
147
213
 
148
214
  After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
@@ -155,23 +221,44 @@ Issue reports and pull requests are welcome on GitHub at https://github.com/biow
155
221
 
156
222
  ## Changelog
157
223
 
158
- master: nothing yet.
224
+ **v0.5.0**
225
+
226
+ * Add `EveOnline::Event` class for handling EveOnline Events
227
+ * `EveOnline::Account::ApiKeyInfo#expires` now returns time with timezone
228
+ * [Upcoming Calendar Events](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_upcomingcalendarevents/)
229
+ * Basic [Calendar Event Attendees](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_calendareventattendees/)
159
230
 
160
- v0.4.0: Time zone fixes. Add EveOnline::Character class for handling each Character. EveOnline::Account::Characters and EveOnline::Account::ApiKeyInfo now supports multiple characters. Fix EveOnline::Characters::AccountBalance class. Fix EveOnline::Characters::AccountBalance#account_key. And #as_json methods.
231
+ **v0.4.0**:
161
232
 
162
- v0.3.0: [Account Characters XML](http://wiki.eve-id.net/APIv2_Account_Characters_XML). Refactoring and bug fixes.
233
+ * Time zone fixes
234
+ * Add `EveOnline::Character` class for handling each Character
235
+ * `EveOnline::Account::Characters` and `EveOnline::Account::ApiKeyInfo` now supports multiple characters
236
+ * Fix `EveOnline::Characters::AccountBalance` class
237
+ * Fix `EveOnline::Characters::AccountBalance#account_key`
238
+ * Add #as_json methods
163
239
 
164
- v0.2.0: [Character Account Balance XML](http://wiki.eve-id.net/APIv2_Char_AccountBalance_XML), [Account APIKeyInfo XML](http://wiki.eve-id.net/APIv2_Account_APIKeyInfo_XML), [Account Status XML](http://wiki.eve-id.net/APIv2_Account_AccountStatus_XML).
240
+ **v0.3.0**:
165
241
 
166
- v0.1.0: [Server Status XML](http://wiki.eve-id.net/APIv2_Server_ServerStatus_XML).
242
+ * [Characters](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/account_characters/)
243
+ * Refactoring and bug fixes
244
+
245
+ **v0.2.0**:
246
+
247
+ * [Account Balance](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_accountbalance/)
248
+ * [API Key Info](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/account_apikeyinfo/)
249
+ * [Account Status](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/account_accountstatus/)
250
+
251
+ **v0.1.0**:
252
+
253
+ * [Server Status](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/serv_serversstatus/)
167
254
 
168
255
  ## Implementation check list:
169
256
 
170
257
  ### Account
171
258
 
172
- - [x] [Account Status XML](http://wiki.eve-id.net/APIv2_Account_AccountStatus_XML)
173
- - [x] [API Key Info XML](http://wiki.eve-id.net/APIv2_Account_APIKeyInfo_XML)
174
- - [x] [Characters (List of) XML](http://wiki.eve-id.net/APIv2_Account_Characters_XML)
259
+ - [x] [Account Status](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/account_accountstatus/)
260
+ - [x] [API Key Info](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/account_apikeyinfo/)
261
+ - [x] [Characters](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/account_characters/)
175
262
 
176
263
  ----
177
264
 
@@ -183,115 +270,130 @@ v0.1.0: [Server Status XML](http://wiki.eve-id.net/APIv2_Server_ServerStatus_XML
183
270
 
184
271
  ### Character
185
272
 
186
- - [x] [Account Balance XML](http://wiki.eve-id.net/APIv2_Char_AccountBalance_XML)
187
- - [ ] [Asset List XML](http://wiki.eve-id.net/APIv2_Char_AssetList_XML)
188
- - [ ] [Calendar Event Attendees XML](http://wiki.eve-id.net/APIv2_Char_CalendarEventAttendees_XML)
189
- - [ ] [Character Sheet XML](http://wiki.eve-id.net/APIv2_Char_CharacterSheet_XML)
190
- - [ ] [Contact List XML](http://wiki.eve-id.net/APIv2_Char_ContactList_XML)
191
- - [ ] [Contact Notifications XML](http://wiki.eve-id.net/APIv2_Char_ContactNotifications_XML)
192
- - [ ] [Contracts XML](http://wiki.eve-id.net/APIv2_Char_Contracts_XML)
193
- - [ ] [ContractItems XML](http://wiki.eve-id.net/APIv2_Char_ContractItems_XML)
194
- - [ ] [ContractBids XML](http://wiki.eve-id.net/APIv2_Char_ContractBids_XML)
195
- - [ ] [Factional Warfare Stats XML](http://wiki.eve-id.net/APIv2_Char_Factional_Warfare_Stats_XML)
196
- - [ ] [Industry Jobs XML](http://wiki.eve-id.net/APIv2_Char_IndustryJobs_XML)
197
- - [ ] [Kill Log (Kill Mails) XML](http://wiki.eve-id.net/APIv2_Char_KillLog_XML)
198
- - [ ] [Locations XML](http://wiki.eve-id.net/APIv2_Char_Locations_XML)
199
- - [ ] [Mail Bodies XML](http://wiki.eve-id.net/APIv2_Char_MailBodies_XML)
200
- - [ ] [Mailing Lists XML](http://wiki.eve-id.net/APIv2_Char_mailinglists_XML)
201
- - [ ] [Mail Messages (Headers) XML](http://wiki.eve-id.net/APIv2_Char_MailMessages_XML)
202
- - [ ] [Market Orders XML](http://wiki.eve-id.net/APIv2_Char_MarketOrders_XML)
203
- - [ ] [Medals XML](http://wiki.eve-id.net/APIv2_Char_Medals_XML)
204
- - [ ] [Notifications XML](http://wiki.eve-id.net/APIv2_Char_Notifications_XML)
205
- - [ ] [NotificationTexts XML](http://wiki.eve-id.net/APIv2_Char_NotificationTexts_XML)
206
- - [ ] [Research XML](http://wiki.eve-id.net/APIv2_Char_Research_XML)
207
- - [ ] [Skill in Training XML](http://wiki.eve-id.net/APIv2_Char_SkillInTraining_XML)
208
- - [ ] [Skill Queue XML](http://wiki.eve-id.net/APIv2_Char_SkillQueue_XML)
209
- - [ ] [Standings (NPC) XML](http://wiki.eve-id.net/APIv2_Char_Standings_XML)
210
- - [ ] [Upcoming Calendar Events XML](http://wiki.eve-id.net/APIv2Char_UpcomingCalendarEvents_XML)
211
- - [ ] [Wallet Journal XML](http://wiki.eve-id.net/APIv2_Char_JournalEntries_XML)
212
- - [ ] [Wallet Transactions XML](http://wiki.eve-id.net/APIv2_Char_MarketTransactions_XML)
273
+ - [x] [Account Balance](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_accountbalance/)
274
+ - [ ] [Asset List](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_assetlist/)
275
+ - [ ] [Blueprints](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_blueprints/)
276
+ - [ ] [Bookmarks](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_bookmarks/)
277
+ - [ ] [Calendar Event Attendees](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_calendareventattendees/)
278
+ - [ ] [Character Sheet](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_charactersheet/)
279
+ - [ ] [Chat Channels](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_chatchannels/)
280
+ - [ ] [Contact List](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_contactlist/)
281
+ - [ ] [Contact Notifications](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_contactnotifications/)
282
+ - [ ] [Contract Bids](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_contractbids/)
283
+ - [ ] [Contract Items](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_contractitems/)
284
+ - [ ] [Contracts](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_contracts/)
285
+ - [ ] [Factional Warfare Stats](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_facwarstats/)
286
+ - [ ] [Industry Jobs](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/char_industryjobs.md)
287
+ - [ ] [Industry Jobs History](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/char_industryjobshistory.md)
288
+ - [ ] [Kill Log](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/char_killlog.md)
289
+ - [ ] [Kill Mails](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/char_killmails.md)
290
+ - [ ] [Locations](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/char_locations.md)
291
+ - [ ] [Mail Bodies](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/char_mailbodies.md)
292
+ - [ ] [Mailing Lists](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_mailinglists/)
293
+ - [ ] [Mail Messages](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_mailmessages/)
294
+ - [ ] [Market Orders](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_marketorders/)
295
+ - [ ] [Medals](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/char_medals.md)
296
+ - [ ] [Notifications](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/char_notifications.md)
297
+ - [ ] [Notification Texts](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/char_notificationtexts.md)
298
+ - [ ] [Planetary Colonies](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_planetarycolonies/)
299
+ - [ ] [Planetary Links](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_planetarylinks/)
300
+ - [ ] [Planetary Pins](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_planetarypins/)
301
+ - [ ] [Planetary Routes](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_planetaryroutes/)
302
+ - [ ] [Research](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_research/)
303
+ - [ ] [Skill in Training](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_skillintraining/)
304
+ - [ ] [Skill Queue](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_skillqueue/)
305
+ - [ ] [Standings (NPC)](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_standings/)
306
+ - [x] [Upcoming Calendar Events](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_upcomingcalendarevents/)
307
+ - [ ] [Wallet Journal](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_walletjournal/)
308
+ - [ ] [Wallet Transactions](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_wallettransactions/)
213
309
 
214
310
  ----
215
311
 
216
312
  ### Corporation
217
313
 
218
- - [ ] [Account Balance XML](http://wiki.eve-id.net/APIv2_Corp_AccountBalance_XML)
219
- - [ ] [Asset List XML](http://wiki.eve-id.net/APIv2_Corp_AssetList_XML)
220
- - [ ] [Contact List XML](http://wiki.eve-id.net/APIv2_Corp_ContactList_XML)
221
- - [ ] [Container Log XML](http://wiki.eve-id.net/APIv2_Corp_ContainerLog_XML)
222
- - [ ] [Contracts XML](http://wiki.eve-id.net/APIv3_Corp_Contracts_XML)
223
- - [ ] [ContractItems XML](http://wiki.eve-id.net/APIv2_Corp_ContractItems_XML)
224
- - [ ] [ContractBids XML](http://wiki.eve-id.net/APIv2_Char_ContractBids_XML)
225
- - [ ] [Corporation Sheet XML](http://wiki.eve-id.net/APIv2_Corp_CorporationSheet_XML)
226
- - [ ] [Factional Warfare Stats XML](http://wiki.eve-id.net/APIv2_Corp_Factional_Warfare_Stats_XML)
227
- - [ ] [Industry Jobs XML](http://wiki.eve-id.net/APIv2_Corp_IndustryJobs_XML)
228
- - [ ] [Kill Log (Kill Mails) XML](http://wiki.eve-id.net/APIv2_Corp_KillLog_XML)
229
- - [ ] [Locations XML](http://wiki.eve-id.net/APIv2_Corp_Locations_XML)
230
- - [ ] [Market Orders XML](http://wiki.eve-id.net/APIv2_Corp_MarketOrders_XML)
231
- - [ ] [Medals XML](http://wiki.eve-id.net/APIv2_Corp_Medals_XML)
232
- - [ ] [Member Medals XML](http://wiki.eve-id.net/APIv2_Corp_MemberMedals_XML)
233
- - [ ] [Member Security XML](http://wiki.eve-id.net/APIv2_Corp_MemberSecurity_XML)
234
- - [ ] [Member Security Log XML](http://wiki.eve-id.net/APIv2_Corp_MemberSecurityLog_XML)
235
- - [ ] [Member Tracking XML](http://wiki.eve-id.net/APIv2_Corp_MemberTracking_XML)
236
- - [ ] [Outpost List XML](http://wiki.eve-id.net/APIv2_Corp_OutpostList_XML)
237
- - [ ] [Outpost Service Detail XML](http://wiki.eve-id.net/APIv2_Corp_OutpostServiceDetail_XML)
238
- - [ ] [Shareholders XML](http://wiki.eve-id.net/APIv2_Corp_Shareholders_XML)
239
- - [ ] [Standings (NPC) XML](http://wiki.eve-id.net/APIv2_Corp_Standings_XML)
240
- - [ ] [StarbaseDetail Details (POS) XML](http://wiki.eve-id.net/APIv2_Corp_StarbaseDetail_XML)
241
- - [ ] [Starbase List (POS) XML](http://wiki.eve-id.net/APIv2_Corp_StarbaseList_XML)
242
- - [ ] [Titles XML](http://wiki.eve-id.net/APIv2_Corp_CorporationTitles_XML)
243
- - [ ] [Wallet Journal XML](http://wiki.eve-id.net/APIv2_Corp_JournalEntries_XML)
244
- - [ ] [Wallet Transactions XML](http://wiki.eve-id.net/APIv2_Corp_MarketTransactions_XML)
314
+ - [ ] [Account Balance](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/corp_accountbalance/)
315
+ - [ ] [Asset List](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_assetlist.md)
316
+ - [ ] [Blueprints](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_blueprints.md)
317
+ - [ ] [Bookmarks](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/corp_bookmarks/)
318
+ - [ ] [Contact List](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_contactlist.md)
319
+ - [ ] [Container Log](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_containerlog.md)
320
+ - [ ] [ContractBids](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_contractbids.md)
321
+ - [ ] [Contract Items](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_contractitems.md)
322
+ - [ ] [Contracts](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_contracts.md)
323
+ - [ ] [Corporation Sheet](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_corporationsheet.md)
324
+ - [ ] [Customs Offices](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_customsoffices.md)
325
+ - [ ] [Facilities](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_facilities.md)
326
+ - [ ] [Factional Warfare Stats](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_facwarstats.md)
327
+ - [ ] [Industry Jobs](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_industryjobs.md)
328
+ - [ ] [Industry Jobs History](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_industryjobshistory.md)
329
+ - [ ] [Kill Mails](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_killmails.md)
330
+ - [ ] [Locations](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_locations.md)
331
+ - [ ] [Market Orders](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_marketorders.md)
332
+ - [ ] [Medals](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_medals.md)
333
+ - [ ] [Member Medals](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_membermedals.md)
334
+ - [ ] [Member Security](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_membersecurity.md)
335
+ - [ ] [Member Security Log](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_membersecuritylog.md)
336
+ - [ ] [Member Tracking](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_membertracking.md)
337
+ - [ ] [Outpost List](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_outpostlist.md)
338
+ - [ ] [Outpost Service Detail](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_outpostservicedetail.md)
339
+ - [ ] [Shareholders](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_shareholders.md)
340
+ - [ ] [Standings (NPC)](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_standings.md)
341
+ - [ ] [Starbase Detail (POS)](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_starbasedetail.md)
342
+ - [ ] [Starbase List (POS)](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_starbaselist.md)
343
+ - [ ] [Titles](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/endpoints/corp_titles.md)
344
+ - [ ] [Wallet Journal](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/corp_walletjournal/)
345
+ - [ ] [Wallet Transactions](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/corp_wallettransactions/)
245
346
 
246
347
  ----
247
348
 
248
349
  ### Eve
249
350
 
250
- - [ ] [Alliance List XML](http://wiki.eve-id.net/APIv2_Eve_AllianceList_XML)
251
- - [ ] [Certificate Tree XML](http://wiki.eve-id.net/APIv2_Certificate_Tree_XML)
252
- - [ ] [Character Affiliation XML](http://wiki.eve-id.net/APIv2_Page_Index?title=APIv2_Eve_CharacterAffiliation_XML&action=edit&redlink=1)
253
- - [ ] [Character ID (Name to ID Conversion) XML](http://wiki.eve-id.net/APIv2_Eve_CharacterID_XML)
254
- - [ ] [Character Info XML](http://wiki.eve-id.net/APIv2_Eve_CharacterInfo_XML)
255
- - [ ] [Character Name (ID to Name Conversion) XML](http://wiki.eve-id.net/APIv2_Eve_CharacterName_XML)
256
- - [ ] [Conquerable Station List (Includes Outposts) XML](http://wiki.eve-id.net/APIv2_Eve_ConquerableStationList_XML)
257
- - [ ] [Error List XML](http://wiki.eve-id.net/APIv2_Eve_ErrorList_XML)
258
- - [ ] [Factional Warfare Stats XML](http://wiki.eve-id.net/APIv2_Factional_Warfare_Stats_XML)
259
- - [ ] [Factional Warfare Top100 Stats XML](http://wiki.eve-id.net/APIv2_Factional_Warfare_Top100_Stats_XML)
260
- - [ ] [RefTypes List XML](http://wiki.eve-id.net/APIv2_Eve_RefTypes_XML)
261
- - [ ] [Skill Tree XML](http://wiki.eve-id.net/APIv2_Eve_SkillTree_XML)
262
- - [ ] [Type Name XML](http://wiki.eve-id.net/APIv2_Eve_TypeName_XML)
351
+ - [ ] [Alliance List](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/eve_alliancelist/)
352
+ - [ ] [Certificate Tree XML (TODO: recheck this)](http://wiki.eve-id.net/APIv2_Certificate_Tree_XML)
353
+ - [ ] [Character Affiliation](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/eve_characteraffiliation/)
354
+ - [ ] [Character ID (Name to ID Conversion)](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/eve_characterid/)
355
+ - [ ] [Character Info](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/eve_characterinfo/)
356
+ - [ ] [Character Name (ID to Name Conversion)](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/eve_charactername/)
357
+ - [ ] [Conquerable Station List (Includes Outposts)](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/eve_conquerablestationlist/)
358
+ - [ ] [Error List](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/eve_errorlist/)
359
+ - [ ] [Factional Warfare Stats XML (TODO: recheck this)](http://wiki.eve-id.net/APIv2_Factional_Warfare_Stats_XML)
360
+ - [ ] [Factional Warfare Top100 Stats XML (TODO: recheck this)](http://wiki.eve-id.net/APIv2_Factional_Warfare_Top100_Stats_XML)
361
+ - [ ] [Ref Types](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/eve_reftypes/)
362
+ - [ ] [Skill Tree XML (TODO: recheck this)](http://wiki.eve-id.net/APIv2_Eve_SkillTree_XML)
363
+ - [ ] [Type Name](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/eve_typename/)
263
364
 
264
365
  ----
265
366
 
266
367
  ### Map
267
368
 
268
- - [ ] [Factional Warfare Systems (Occupancy Map) XML](http://wiki.eve-id.net/APIv2_Factional_Warfare_Occupancy_XML)
269
- - [ ] [Jumps XML](http://wiki.eve-id.net/APIv2_Map_Jumps_XML)
270
- - [ ] [Kills XML](http://wiki.eve-id.net/APIv2_Map_Kills_XML)
271
- - [ ] [Sovereignty XML](http://wiki.eve-id.net/APIv2_Map_Sovereignty_XML)
272
- - [ ] [Sovereignty Status (API disabled) XML](http://wiki.eve-id.net/APIv2_Map_Sovereignty_Status_XML)
369
+ - [ ] [Factional Warfare Systems (Occupancy Map)](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/map_facwarsystems/)
370
+ - [ ] [Jumps](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/map_jumps/)
371
+ - [ ] [Kills](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/map_kills/)
372
+ - [ ] [Sovereignty](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/map_sovereignty/)
373
+ - [ ] [Sovereignty Status (API disabled) XML (TODO: recheck this)](http://wiki.eve-id.net/APIv2_Map_Sovereignty_Status_XML)
273
374
 
274
375
  ----
275
376
 
276
377
  ### Misc
277
378
 
278
- - [ ] [Image (ID to Character Portrait and Corporation/Alliance Logo)](http://wiki.eve-id.net/APIv2_Eve_Image_Service)
279
- - [ ] [Old Portraits](http://wiki.eve-id.net/APIv2_Old_Portraits)
379
+ - [ ] [Image (ID to Character Portrait and Corporation/Alliance Logo) (TODO: recheck this)](http://wiki.eve-id.net/APIv2_Eve_Image_Service)
380
+ - [ ] [Old Portraits (TODO: recheck this)](http://wiki.eve-id.net/APIv2_Old_Portraits)
280
381
 
281
382
  ----
282
383
 
283
384
  ### Server
284
385
 
285
- - [x] [Server Status XML](http://wiki.eve-id.net/APIv2_Server_ServerStatus_XML)
386
+ - [x] [Server Status](https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/serv_serversstatus/)
286
387
 
287
388
  ----
288
389
 
390
+ ## TODO
391
+
392
+ - [ ] Account Status: Support multiCharacterTraining
393
+ - [ ] Access Mask
394
+ - [ ] Caching
395
+ - [ ] Test EVE server
289
396
 
290
397
  ## License
291
398
 
292
399
  The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
293
-
294
-
295
-
296
- [![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/biow0lf/eve_online/trend.png)](https://bitdeli.com/free "Bitdeli Badge")
297
-
data/eve_online.gemspec CHANGED
@@ -17,7 +17,7 @@ Gem::Specification.new do |spec|
17
17
  spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features|bin)/}) }
18
18
  spec.require_paths = ['lib']
19
19
 
20
- spec.required_ruby_version = '>= 2.0'
20
+ spec.required_ruby_version = '>= 1.9.3'
21
21
 
22
22
  spec.add_development_dependency 'bundler', '~> 1.10'
23
23
  spec.add_development_dependency 'rake', '~> 10.0'
@@ -27,6 +27,6 @@ Gem::Specification.new do |spec|
27
27
 
28
28
  spec.add_runtime_dependency 'activesupport', '~> 4'
29
29
  spec.add_runtime_dependency 'nori', '~> 2.6'
30
- # https://github.com/sparklemotion/nokogiri/blob/v1.6.6.4/CHANGELOG.rdoc
31
- spec.add_runtime_dependency 'nokogiri', '>= 1.6.4.4'
30
+ # https://github.com/sparklemotion/nokogiri/blob/v1.6.7.1/CHANGELOG.rdoc
31
+ spec.add_runtime_dependency 'nokogiri', '>= 1.6.7.1'
32
32
  end
data/lib/eve_online.rb CHANGED
@@ -1,12 +1,20 @@
1
1
  require 'eve_online/version'
2
2
  require 'eve_online/base'
3
3
  require 'eve_online/character'
4
- require 'eve_online/account/status'
4
+ require 'eve_online/event'
5
+ require 'eve_online/skill'
6
+ require 'eve_online/skill_group'
5
7
  require 'eve_online/account/api_key_info'
6
8
  require 'eve_online/account/characters'
9
+ require 'eve_online/account/status'
7
10
  require 'eve_online/characters/account_balance'
8
11
  require 'eve_online/characters/asset_list'
9
12
  require 'eve_online/characters/calendar_event_attendees'
13
+ require 'eve_online/characters/contact_list'
14
+ require 'eve_online/characters/contact_notifications'
15
+ require 'eve_online/characters/character_sheet'
16
+ require 'eve_online/characters/upcoming_calendar_events'
17
+ require 'eve_online/eve/skill_tree'
10
18
  require 'eve_online/server/status'
11
19
 
12
20
  module EveOnline
@@ -1,6 +1,6 @@
1
1
  module EveOnline
2
2
  module Account
3
- # http://wiki.eve-id.net/APIv2_Account_APIKeyInfo_XML
3
+ # https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/account_apikeyinfo/
4
4
  class ApiKeyInfo < Base
5
5
  API_ENDPOINT = 'https://api.eveonline.com/account/APIKeyInfo.xml.aspx'
6
6
 
@@ -28,32 +28,28 @@ module EveOnline
28
28
  end
29
29
 
30
30
  def row
31
- rowset.fetch('row')
31
+ @row ||= rowset.fetch('row')
32
32
  end
33
33
 
34
34
  def rowset
35
- key.fetch('rowset')
35
+ @rowset ||= key.fetch('rowset')
36
36
  end
37
37
 
38
38
  def expires
39
- # TODO: convert to Time
40
- key.fetch('@expires')
39
+ @expires ||= \
40
+ ActiveSupport::TimeZone['UTC'].parse(key.fetch('@expires'))
41
41
  end
42
42
 
43
43
  def type
44
- key.fetch('@type')
44
+ @type ||= key.fetch('@type')
45
45
  end
46
46
 
47
47
  def access_mask
48
- key.fetch('@accessMask').to_i
48
+ @access_mask ||= key.fetch('@accessMask').to_i
49
49
  end
50
50
 
51
51
  def key
52
- result.fetch('key')
53
- end
54
-
55
- def version
56
- eveapi.fetch('@version').to_i
52
+ @key ||= result.fetch('key')
57
53
  end
58
54
 
59
55
  def url
@@ -1,6 +1,6 @@
1
1
  module EveOnline
2
2
  module Account
3
- # http://wiki.eve-id.net/APIv2_Account_Characters_XML
3
+ # https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/account_characters/
4
4
  class Characters < Base
5
5
  API_ENDPOINT = 'https://api.eveonline.com/account/Characters.xml.aspx'
6
6
 
@@ -12,10 +12,6 @@ module EveOnline
12
12
  @v_code = v_code
13
13
  end
14
14
 
15
- def version
16
- eveapi.fetch('@version').to_i
17
- end
18
-
19
15
  def characters
20
16
  case row
21
17
  when Hash
@@ -32,11 +28,11 @@ module EveOnline
32
28
  end
33
29
 
34
30
  def row
35
- rowset.fetch('row')
31
+ @row ||= rowset.fetch('row')
36
32
  end
37
33
 
38
34
  def rowset
39
- result.fetch('rowset')
35
+ @rowset ||= result.fetch('rowset')
40
36
  end
41
37
 
42
38
  def url
@@ -1,6 +1,6 @@
1
1
  module EveOnline
2
2
  module Account
3
- # http://wiki.eve-id.net/APIv2_Account_AccountStatus_XML
3
+ # https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/account_accountstatus/
4
4
  class Status < Base
5
5
  API_ENDPOINT = 'https://api.eveonline.com/account/AccountStatus.xml.aspx'
6
6
 
@@ -24,15 +24,13 @@ module EveOnline
24
24
  end
25
25
 
26
26
  def paid_until
27
- @paid_until ||= begin
27
+ @paid_until ||= \
28
28
  ActiveSupport::TimeZone['UTC'].parse(result.fetch('paidUntil'))
29
- end
30
29
  end
31
30
 
32
31
  def create_date
33
- @create_date ||= begin
32
+ @create_date ||= \
34
33
  ActiveSupport::TimeZone['UTC'].parse(result.fetch('createDate'))
35
- end
36
34
  end
37
35
 
38
36
  def logon_count
@@ -43,10 +41,6 @@ module EveOnline
43
41
  @logon_minutes ||= result.fetch('logonMinutes').to_i
44
42
  end
45
43
 
46
- def version
47
- @version ||= eveapi.fetch('@version').to_i
48
- end
49
-
50
44
  def url
51
45
  "#{ API_ENDPOINT }?keyID=#{ key_id }&vCode=#{ v_code }"
52
46
  end
@@ -15,20 +15,17 @@ module EveOnline
15
15
  end
16
16
 
17
17
  def cached_until
18
- @cached_until ||= begin
18
+ @cached_until ||= \
19
19
  ActiveSupport::TimeZone['UTC'].parse(eveapi.fetch('cachedUntil'))
20
- end
21
20
  end
22
21
 
23
22
  def current_time
24
- @current_time ||= begin
23
+ @current_time ||= \
25
24
  ActiveSupport::TimeZone['UTC'].parse(eveapi.fetch('currentTime'))
26
- end
27
25
  end
28
26
 
29
27
  def version
30
- # TODO: check all API for version
31
- raise NotImplementedError
28
+ eveapi.fetch('@version').to_i
32
29
  end
33
30
 
34
31
  def eveapi
@@ -24,7 +24,7 @@ module EveOnline
24
24
  end
25
25
 
26
26
  def character_name
27
- @name = @name || options.fetch('@name', nil) || options.fetch('@characterName')
27
+ @character_name ||= options.fetch('@name', nil) || options.fetch('@characterName')
28
28
  end
29
29
 
30
30
  def corporation_id
@@ -1,6 +1,6 @@
1
1
  module EveOnline
2
2
  module Characters
3
- # http://wiki.eve-id.net/APIv2_Char_AccountBalance_XML
3
+ # https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_accountbalance/
4
4
  class AccountBalance < Base
5
5
  API_ENDPOINT = 'https://api.eveonline.com/char/AccountBalance.xml.aspx'
6
6
 
@@ -24,27 +24,23 @@ module EveOnline
24
24
  end
25
25
 
26
26
  def account_id
27
- row.fetch('@accountID').to_i
27
+ @account_id ||= row.fetch('@accountID').to_i
28
28
  end
29
29
 
30
30
  def account_key
31
- row.fetch('@accountKey').to_i
31
+ @account_key ||= row.fetch('@accountKey').to_i
32
32
  end
33
33
 
34
34
  def balance
35
- row.fetch('@balance')
35
+ @balance ||= row.fetch('@balance')
36
36
  end
37
37
 
38
38
  def row
39
- rowset.fetch('row')
39
+ @row ||= rowset.fetch('row')
40
40
  end
41
41
 
42
42
  def rowset
43
- result.fetch('rowset')
44
- end
45
-
46
- def version
47
- eveapi.fetch('@version').to_i
43
+ @rowset ||= result.fetch('rowset')
48
44
  end
49
45
 
50
46
  def url
@@ -1,9 +1,21 @@
1
- # TODO: finish this
2
1
  module EveOnline
3
2
  module Characters
4
- # http://wiki.eve-id.net/APIv2_Char_AssetList_XML
3
+ # https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_assetlist/
5
4
  class AssetList < Base
6
5
  API_ENDPOINT = 'https://api.eveonline.com/char/AssetList.xml.aspx'
6
+
7
+ attr_reader :key_id, :v_code, :character_id
8
+
9
+ def initialize(key_id, v_code, character_id)
10
+ super()
11
+ @key_id = key_id
12
+ @v_code = v_code
13
+ @character_id = character_id
14
+ end
15
+
16
+ def url
17
+ "#{ API_ENDPOINT }?keyID=#{ key_id }&vCode=#{ v_code }&characterID=#{ character_id }"
18
+ end
7
19
  end
8
20
  end
9
21
  end
@@ -1,9 +1,22 @@
1
- # TODO: finish this
2
1
  module EveOnline
3
2
  module Characters
4
- # http://wiki.eve-id.net/APIv2_Char_CalendarEventAttendees_XML
3
+ # https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_calendareventattendees/
5
4
  class CalendarEventAttendees < Base
6
5
  API_ENDPOINT = 'https://api.eveonline.com/char/CalendarEventAttendees.xml.aspx'
6
+
7
+ attr_reader :key_id, :v_code, :character_id, :event_id
8
+
9
+ def initialize(key_id, v_code, character_id, event_id)
10
+ super()
11
+ @key_id = key_id
12
+ @v_code = v_code
13
+ @character_id = character_id
14
+ @event_id = event_id
15
+ end
16
+
17
+ def url
18
+ "#{ API_ENDPOINT }?keyID=#{ key_id }&vCode=#{ v_code }&characterID=#{ character_id }&eventIDs=#{ event_id }"
19
+ end
7
20
  end
8
21
  end
9
22
  end
@@ -0,0 +1,21 @@
1
+ module EveOnline
2
+ module Characters
3
+ # https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_charactersheet/
4
+ class CharacterSheet < Base
5
+ API_ENDPOINT = 'https://api.eveonline.com/char/CharacterSheet.xml.aspx'
6
+
7
+ attr_reader :key_id, :v_code, :character_id
8
+
9
+ def initialize(key_id, v_code, character_id)
10
+ super()
11
+ @key_id = key_id
12
+ @v_code = v_code
13
+ @character_id = character_id
14
+ end
15
+
16
+ def url
17
+ "#{ API_ENDPOINT }?keyID=#{ key_id }&vCode=#{ v_code }&characterID=#{ character_id }"
18
+ end
19
+ end
20
+ end
21
+ end
@@ -0,0 +1,21 @@
1
+ module EveOnline
2
+ module Characters
3
+ # https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_contactlist/
4
+ class ContactList < Base
5
+ API_ENDPOINT = 'https://api.eveonline.com/char/ContactList.xml.aspx'
6
+
7
+ attr_reader :key_id, :v_code, :character_id
8
+
9
+ def initialize(key_id, v_code, character_id)
10
+ super()
11
+ @key_id = key_id
12
+ @v_code = v_code
13
+ @character_id = character_id
14
+ end
15
+
16
+ def url
17
+ "#{ API_ENDPOINT }?keyID=#{ key_id }&vCode=#{ v_code }&characterID=#{ character_id }"
18
+ end
19
+ end
20
+ end
21
+ end
@@ -0,0 +1,21 @@
1
+ module EveOnline
2
+ module Characters
3
+ # https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_contactnotifications/
4
+ class ContactNotifications < Base
5
+ API_ENDPOINT = 'https://api.eveonline.com/char/ContactNotifications.xml.aspx'
6
+
7
+ attr_reader :key_id, :v_code, :character_id
8
+
9
+ def initialize(key_id, v_code, character_id)
10
+ super()
11
+ @key_id = key_id
12
+ @v_code = v_code
13
+ @character_id = character_id
14
+ end
15
+
16
+ def url
17
+ "#{ API_ENDPOINT }?keyID=#{ key_id }&vCode=#{ v_code }&characterID=#{ character_id }"
18
+ end
19
+ end
20
+ end
21
+ end
@@ -0,0 +1,44 @@
1
+ module EveOnline
2
+ module Characters
3
+ # https://eveonline-third-party-documentation.readthedocs.org/en/latest/xmlapi/char_upcomingcalendarevents/
4
+ class UpcomingCalendarEvents < Base
5
+ API_ENDPOINT = 'https://api.eveonline.com/char/UpcomingCalendarEvents.xml.aspx'
6
+
7
+ attr_reader :key_id, :v_code, :character_id
8
+
9
+ def initialize(key_id, v_code, character_id)
10
+ super()
11
+ @key_id = key_id
12
+ @v_code = v_code
13
+ @character_id = character_id
14
+ end
15
+
16
+ def events
17
+ case row
18
+ when Hash
19
+ [EveOnline::Event.new(row)]
20
+ when Array
21
+ output = []
22
+ row.each do |event|
23
+ output << EveOnline::Event.new(event)
24
+ end
25
+ output
26
+ else
27
+ raise ArgumentError
28
+ end
29
+ end
30
+
31
+ def row
32
+ @row ||= rowset.fetch('row')
33
+ end
34
+
35
+ def rowset
36
+ @rowset ||= result.fetch('rowset')
37
+ end
38
+
39
+ def url
40
+ "#{ API_ENDPOINT }?keyID=#{ key_id }&vCode=#{ v_code }&characterID=#{ character_id }"
41
+ end
42
+ end
43
+ end
44
+ end
@@ -0,0 +1,12 @@
1
+ module EveOnline
2
+ module Eve
3
+ # http://wiki.eve-id.net/APIv2_Eve_SkillTree_XML
4
+ class SkillTree < Base
5
+ API_ENDPOINT = 'https://api.eveonline.com/eve/SkillTree.xml.aspx'
6
+
7
+ def url
8
+ API_ENDPOINT
9
+ end
10
+ end
11
+ end
12
+ end
@@ -0,0 +1,66 @@
1
+ module EveOnline
2
+ class Event
3
+ attr_reader :options
4
+
5
+ def initialize(options = {})
6
+ @options = options
7
+ end
8
+
9
+ def as_json(*args)
10
+ {
11
+ event_id: event_id,
12
+ owner_id: owner_id,
13
+ owner_name: owner_name,
14
+ event_date: event_date,
15
+ event_title: event_title,
16
+ duration: duration,
17
+ importance: importance,
18
+ response: response,
19
+ event_text: event_text,
20
+ owner_type_id: owner_type_id
21
+ }
22
+ end
23
+
24
+ def event_id
25
+ @event_id ||= options.fetch('@eventID').to_i
26
+ end
27
+
28
+ def owner_id
29
+ @owner_id ||= options.fetch('@ownerID').to_i
30
+ end
31
+
32
+ def owner_name
33
+ @owner_name ||= options.fetch('@ownerName')
34
+ end
35
+
36
+ def event_date
37
+ @event_date ||= \
38
+ ActiveSupport::TimeZone['UTC'].parse(options.fetch('@eventDate'))
39
+ end
40
+
41
+ def event_title
42
+ @event_title ||= options.fetch('@eventTitle')
43
+ end
44
+
45
+ def duration
46
+ @duration ||= options.fetch('@duration').to_i
47
+ end
48
+
49
+ def importance
50
+ @importance ||= options.fetch('@importance').eql?('1')
51
+ end
52
+
53
+ def response
54
+ # TODO: convert to symbol. e.g. "Undecided" => :undecided
55
+ @response ||= options.fetch('@response')
56
+ end
57
+
58
+ def event_text
59
+ @event_text ||= options.fetch('@eventText')
60
+ end
61
+
62
+ def owner_type_id
63
+ @owner_type_id ||= options.fetch('@ownerTypeID').to_i
64
+ end
65
+ end
66
+ end
@@ -23,10 +23,6 @@ module EveOnline
23
23
  @online_players ||= result.fetch('onlinePlayers').to_i
24
24
  end
25
25
 
26
- def version
27
- @version ||= eveapi.fetch('@version').to_i
28
- end
29
-
30
26
  def url
31
27
  API_ENDPOINT
32
28
  end
@@ -0,0 +1,5 @@
1
+ module EveOnline
2
+ class Skill
3
+
4
+ end
5
+ end
@@ -0,0 +1,5 @@
1
+ module EveOnline
2
+ class SkillGroup
3
+
4
+ end
5
+ end
@@ -1,3 +1,3 @@
1
1
  module EveOnline
2
- VERSION = '0.4.0'.freeze
2
+ VERSION = '0.5.0'.freeze
3
3
  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.0
4
+ version: 0.5.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: 2015-12-02 00:00:00.000000000 Z
11
+ date: 2016-01-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -114,14 +114,14 @@ dependencies:
114
114
  requirements:
115
115
  - - ">="
116
116
  - !ruby/object:Gem::Version
117
- version: 1.6.4.4
117
+ version: 1.6.7.1
118
118
  type: :runtime
119
119
  prerelease: false
120
120
  version_requirements: !ruby/object:Gem::Requirement
121
121
  requirements:
122
122
  - - ">="
123
123
  - !ruby/object:Gem::Version
124
- version: 1.6.4.4
124
+ version: 1.6.7.1
125
125
  description: EveOnline API. XML and CREST.
126
126
  email:
127
127
  - igor.zubkov@gmail.com
@@ -148,7 +148,15 @@ files:
148
148
  - lib/eve_online/characters/account_balance.rb
149
149
  - lib/eve_online/characters/asset_list.rb
150
150
  - lib/eve_online/characters/calendar_event_attendees.rb
151
+ - lib/eve_online/characters/character_sheet.rb
152
+ - lib/eve_online/characters/contact_list.rb
153
+ - lib/eve_online/characters/contact_notifications.rb
154
+ - lib/eve_online/characters/upcoming_calendar_events.rb
155
+ - lib/eve_online/eve/skill_tree.rb
156
+ - lib/eve_online/event.rb
151
157
  - lib/eve_online/server/status.rb
158
+ - lib/eve_online/skill.rb
159
+ - lib/eve_online/skill_group.rb
152
160
  - lib/eve_online/version.rb
153
161
  homepage: https://github.com/biow0lf/eve_online
154
162
  licenses:
@@ -162,7 +170,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
162
170
  requirements:
163
171
  - - ">="
164
172
  - !ruby/object:Gem::Version
165
- version: '2.0'
173
+ version: 1.9.3
166
174
  required_rubygems_version: !ruby/object:Gem::Requirement
167
175
  requirements:
168
176
  - - ">="
@@ -170,7 +178,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
170
178
  version: '0'
171
179
  requirements: []
172
180
  rubyforge_project:
173
- rubygems_version: 2.4.8
181
+ rubygems_version: 2.5.1
174
182
  signing_key:
175
183
  specification_version: 4
176
184
  summary: EveOnline API. XML and CREST.