Class: SecureNative::Options

Inherits:
Object
  • Object
show all
Defined in:
lib/securenative/options.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_key: nil, api_url: "https://api.securenative.com/collector/api/v1", interval: 1000, max_events: 1000, timeout: 1500, auto_send: true, disable: false, log_level: "FATAL", fail_over_strategy: FailOverStrategy::FAIL_OPEN, proxy_headers: nil) ⇒ Options

Returns a new instance of Options.



8
9
10
11
12
13
14
15
16
17
18
19
20
21
# File 'lib/securenative/options.rb', line 8

def initialize(api_key: nil, api_url: "https://api.securenative.com/collector/api/v1", interval: 1000,
               max_events: 1000, timeout: 1500, auto_send: true, disable: false, log_level: "FATAL",
               fail_over_strategy: FailOverStrategy::FAIL_OPEN, proxy_headers: nil)
  @api_key = api_key
  @api_url = api_url
  @interval = interval
  @max_events = max_events
  @timeout = timeout
  @auto_send = auto_send
  @disable = disable
  @log_level = log_level
  @fail_over_strategy = fail_over_strategy
  @proxy_headers = proxy_headers
end

Instance Attribute Details

#api_keyObject

Returns the value of attribute api_key.



5
6
7
# File 'lib/securenative/options.rb', line 5

def api_key
  @api_key
end

#api_urlObject

Returns the value of attribute api_url.



5
6
7
# File 'lib/securenative/options.rb', line 5

def api_url
  @api_url
end

#auto_sendObject

Returns the value of attribute auto_send.



5
6
7
# File 'lib/securenative/options.rb', line 5

def auto_send
  @auto_send
end

#disableObject

Returns the value of attribute disable.



5
6
7
# File 'lib/securenative/options.rb', line 5

def disable
  @disable
end

#fail_over_strategyObject

Returns the value of attribute fail_over_strategy.



5
6
7
# File 'lib/securenative/options.rb', line 5

def fail_over_strategy
  @fail_over_strategy
end

#intervalObject

Returns the value of attribute interval.



5
6
7
# File 'lib/securenative/options.rb', line 5

def interval
  @interval
end

#log_levelObject

Returns the value of attribute log_level.



5
6
7
# File 'lib/securenative/options.rb', line 5

def log_level
  @log_level
end

#max_eventsObject

Returns the value of attribute max_events.



5
6
7
# File 'lib/securenative/options.rb', line 5

def max_events
  @max_events
end

#proxy_headersObject

Returns the value of attribute proxy_headers.



5
6
7
# File 'lib/securenative/options.rb', line 5

def proxy_headers
  @proxy_headers
end

#timeoutObject

Returns the value of attribute timeout.



5
6
7
# File 'lib/securenative/options.rb', line 5

def timeout
  @timeout
end