Class: VirusTotal::Client::Base
- Inherits:
-
Object
- Object
- VirusTotal::Client::Base
- Defined in:
- lib/virustotal/clients/base.rb
Constant Summary collapse
Instance Attribute Summary collapse
-
#key ⇒ Object
readonly
Returns the value of attribute key.
Instance Method Summary collapse
-
#initialize(key: ENV["VIRUSTOTAL_API_KEY"]) ⇒ Base
constructor
A new instance of Base.
Constructor Details
#initialize(key: ENV["VIRUSTOTAL_API_KEY"]) ⇒ Base
Returns a new instance of Base.
16 17 18 19 |
# File 'lib/virustotal/clients/base.rb', line 16 def initialize(key: ENV["VIRUSTOTAL_API_KEY"]) @key = key raise ArgumentError, "No key has been found or provided!" unless key? end |
Instance Attribute Details
#key ⇒ Object (readonly)
Returns the value of attribute key.
14 15 16 |
# File 'lib/virustotal/clients/base.rb', line 14 def key @key end |