Class: GroongaQueryLog::ServerVerifier::GroongaOptions

Inherits:
Object
  • Object
show all
Defined in:
lib/groonga-query-log/server-verifier.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeGroongaOptions

Returns a new instance of GroongaOptions.



234
235
236
237
238
# File 'lib/groonga-query-log/server-verifier.rb', line 234

def initialize
  @host     = "127.0.0.1"
  @port     = 10041
  @protocol = :gqtp
end

Instance Attribute Details

#hostObject

Returns the value of attribute host.



231
232
233
# File 'lib/groonga-query-log/server-verifier.rb', line 231

def host
  @host
end

#portObject

Returns the value of attribute port.



232
233
234
# File 'lib/groonga-query-log/server-verifier.rb', line 232

def port
  @port
end

#protocolObject

Returns the value of attribute protocol.



233
234
235
# File 'lib/groonga-query-log/server-verifier.rb', line 233

def protocol
  @protocol
end

Instance Method Details

#create_client(&block) ⇒ Object



240
241
242
243
244
245
# File 'lib/groonga-query-log/server-verifier.rb', line 240

def create_client(&block)
  Groonga::Client.open(:host     => @host,
                       :port     => @port,
                       :protocol => @protocol,
                       &block)
end