Class: Zabbix::Client

Inherits:
Object
  • Object
show all
Defined in:
lib/zabbix/client/version.rb,
lib/zabbix/client/client.rb

Defined Under Namespace

Classes: Error, Method

Constant Summary collapse

VERSION =
'0.0.9'

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(url, options = {}) ⇒ Client

Returns a new instance of Client.



127
128
129
130
# File 'lib/zabbix/client/client.rb', line 127

def initialize(url, options = {})
  @url = URI.parse(url)
  @options = options
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(method_name) ⇒ Object



132
133
134
# File 'lib/zabbix/client/client.rb', line 132

def method_missing(method_name)
  Zabbix::Client::Method.new(method_name, self)
end

Instance Attribute Details

#authObject

Returns the value of attribute auth.



125
126
127
# File 'lib/zabbix/client/client.rb', line 125

def auth
  @auth
end

#optionsObject (readonly)

Returns the value of attribute options.



124
125
126
# File 'lib/zabbix/client/client.rb', line 124

def options
  @options
end

#urlObject (readonly)

Method



123
124
125
# File 'lib/zabbix/client/client.rb', line 123

def url
  @url
end