Class: OTX::Indicator::IP::Malware
- Inherits:
-
Type::Base
- Object
- Type::Base
- OTX::Indicator::IP::Malware
- Defined in:
- lib/otx_ruby/types/ip/malware.rb
Instance Attribute Summary
Attributes inherited from Type::Base
Instance Method Summary collapse
-
#initialize(attributes = {}) ⇒ Malware
constructor
A new instance of Malware.
Constructor Details
#initialize(attributes = {}) ⇒ Malware
Returns a new instance of Malware.
5 6 7 8 9 10 11 12 13 14 15 16 17 |
# File 'lib/otx_ruby/types/ip/malware.rb', line 5 def initialize(attributes={}) attributes.each do |key, value| if key == 'hash' self.class.send(:attr_accessor, 'malware_hash') send('malware_hash=', value) else unless self.respond_to?(key) self.class.send(:attr_accessor, key) end send("#{key.downcase}=", value) end end end |