Class: SteamCodec::VDF
- Defined in:
- lib/steam_codec/vdf.rb
Class Method Summary collapse
- .load(data) ⇒ Object
-
.loadFromFile(file) ⇒ Object
About VDF => http://wiki.teamfortress.com/wiki/WebAPI/VDF.
Instance Method Summary collapse
Methods inherited from KeyValues
#asArray, #get, loadFromJSON, #method_missing, #respond_to_missing?
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class SteamCodec::KeyValues
Class Method Details
.load(data) ⇒ Object
11 12 13 14 15 |
# File 'lib/steam_codec/vdf.rb', line 11 def self.load(data) vdf = KeyValues::load(data) return self[vdf] if vdf nil end |
.loadFromFile(file) ⇒ Object
About VDF => http://wiki.teamfortress.com/wiki/WebAPI/VDF
5 6 7 8 9 |
# File 'lib/steam_codec/vdf.rb', line 5 def self.loadFromFile(file) vdf = KeyValues::loadFromFile(file) return self[vdf] if vdf nil end |
Instance Method Details
#isSignaturesValid?(publicKey) ⇒ Boolean
17 18 19 20 21 22 23 24 |
# File 'lib/steam_codec/vdf.rb', line 17 def isSignaturesValid?(publicKey) return true unless key?("kvsignatures") self["kvsignatures"].each do |key, signature| # TODO return false end true end |