dsander-reve 0.0.122 → 0.0.123
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.
- data/lib/reve/classes.rb +4 -4
- data/lib/reve.rb +1 -0
- metadata +2 -2
data/lib/reve/classes.rb
CHANGED
|
@@ -425,7 +425,7 @@ module Reve #:nodoc:
|
|
|
425
425
|
# * assets ( [Asset] ) - A list of Asset objects that are contained in this AssetContainer.
|
|
426
426
|
# See Also: Asset, Reve::API#corporate_assets_list, Reve::API#personal_assets_list
|
|
427
427
|
class AssetContainer
|
|
428
|
-
attr_reader :item_id, :location_id, :type_id, :quantity, :flag, :singleton
|
|
428
|
+
attr_reader :item_id, :location_id, :type_id, :quantity, :flag, :singleton, :xml_hash
|
|
429
429
|
attr_accessor :assets
|
|
430
430
|
def initialize(elem)
|
|
431
431
|
@item_id = elem['itemID'].to_i
|
|
@@ -436,7 +436,7 @@ module Reve #:nodoc:
|
|
|
436
436
|
@singleton = elem['singleton'] == "1"
|
|
437
437
|
@assets = []
|
|
438
438
|
#@xml_hash = elem.to_s.gsub(/\n|\r|\s/,'')
|
|
439
|
-
|
|
439
|
+
@xml_hash = ::Digest::SHA1.hexdigest elem.to_s.gsub(/\n|\r|\s/,'')
|
|
440
440
|
end
|
|
441
441
|
end
|
|
442
442
|
|
|
@@ -448,7 +448,7 @@ module Reve #:nodoc:
|
|
|
448
448
|
# * flag ( Fixnum ) - Inventory flag, refer to http://wiki.eve-dev.net/API_Inventory_Flags (See also KillLoss's flag)
|
|
449
449
|
# See Also: AssetContainer, Reve::API#corporate_assets_list, Reve::API#personal_assets_list
|
|
450
450
|
class Asset
|
|
451
|
-
attr_reader :item_id, :type_id, :quantity, :flag, :singleton
|
|
451
|
+
attr_reader :item_id, :type_id, :quantity, :flag, :singleton, :xml_hash
|
|
452
452
|
def initialize(elem) #:nodoc:
|
|
453
453
|
@item_id = elem['itemID'].to_i
|
|
454
454
|
@type_id = elem['typeID'].to_i
|
|
@@ -456,7 +456,7 @@ module Reve #:nodoc:
|
|
|
456
456
|
@flag = elem['flag'].to_i
|
|
457
457
|
@singleton = elem['singleton'].to_i
|
|
458
458
|
#@xml_hash = elem.to_s.gsub(/\n|\r|\s/,'')
|
|
459
|
-
|
|
459
|
+
@xml_hash = ::Digest::SHA1.hexdigest elem.to_s.gsub(/\n|\r|\s/,'')
|
|
460
460
|
end
|
|
461
461
|
end
|
|
462
462
|
|
data/lib/reve.rb
CHANGED