Class: ZabbixApi::Proxies
- Defined in:
- lib/zabbixapi/classes/proxies.rb
Instance Method Summary collapse
-
#delete(data) ⇒ Integer
Delete Proxy object using Zabbix API.
-
#indentify ⇒ String
The id field name used for identifying specific Proxy objects via Zabbix API.
-
#isreadable(data) ⇒ Boolean
Check if a Proxy object is readable using Zabbix API.
-
#iswritable(data) ⇒ Boolean
Check if a Proxy object is writable using Zabbix API.
-
#method_name ⇒ String
The method name used for interacting with Proxies via Zabbix API.
Methods inherited from Basic
#add, #all, #create, #create_or_update, #default_options, #destroy, #dump_by_id, #get, #get_full_data, #get_id, #get_or_create, #get_raw, #hash_equals?, #initialize, #key, #keys, #log, #merge_params, #normalize_array, #normalize_hash, #parse_keys, #symbolize_keys, #update
Constructor Details
This class inherits a constructor from ZabbixApi::Basic
Instance Method Details
#delete(data) ⇒ Integer
Delete Proxy object using Zabbix API
23 24 25 26 |
# File 'lib/zabbixapi/classes/proxies.rb', line 23 def delete(data) result = @client.api_request(:method => 'proxy.delete', :params => data) result.empty? ? nil : result['proxyids'][0].to_i end |
#indentify ⇒ String
The id field name used for identifying specific Proxy objects via Zabbix API
13 14 15 |
# File 'lib/zabbixapi/classes/proxies.rb', line 13 def indentify 'host' end |
#isreadable(data) ⇒ Boolean
Check if a Proxy object is readable using Zabbix API
34 35 36 |
# File 'lib/zabbixapi/classes/proxies.rb', line 34 def isreadable(data) @client.api_request(:method => 'proxy.isreadable', :params => data) end |
#iswritable(data) ⇒ Boolean
Check if a Proxy object is writable using Zabbix API
44 45 46 |
# File 'lib/zabbixapi/classes/proxies.rb', line 44 def iswritable(data) @client.api_request(:method => 'proxy.iswritable', :params => data) end |
#method_name ⇒ String
The method name used for interacting with Proxies via Zabbix API
6 7 8 |
# File 'lib/zabbixapi/classes/proxies.rb', line 6 def method_name 'proxy' end |