Class: GraylogAPI::Extractors
- Inherits:
-
Object
- Object
- GraylogAPI::Extractors
- Defined in:
- lib/graylogapi/extractors.rb
Overview
class for manage Extractors of an input
Instance Method Summary collapse
-
#create(input_id, params) ⇒ GraylogAPI::Client::Response
add key to an input.
-
#delete(input_id, key) ⇒ GraylogAPI::Client::Response
delete key of an input.
-
#initialize(client) ⇒ Extractors
constructor
A new instance of Extractors.
Constructor Details
#initialize(client) ⇒ Extractors
Returns a new instance of Extractors.
4 5 6 |
# File 'lib/graylogapi/extractors.rb', line 4 def initialize(client) @client = client end |
Instance Method Details
#create(input_id, params) ⇒ GraylogAPI::Client::Response
add key to an input
13 14 15 |
# File 'lib/graylogapi/extractors.rb', line 13 def create(input_id, params) @client.request(:post, "/system/inputs/#{input_id}/extractors", params) end |
#delete(input_id, key) ⇒ GraylogAPI::Client::Response
delete key of an input
22 23 24 |
# File 'lib/graylogapi/extractors.rb', line 22 def delete(input_id, key) @client.request(:delete, "/system/inputs/#{input_id}/extractors/#{key}") end |