Class: GroongaQueryLog::ServerVerifier::GroongaOptions
- Inherits:
-
Object
- Object
- GroongaQueryLog::ServerVerifier::GroongaOptions
- Defined in:
- lib/groonga-query-log/server-verifier.rb
Instance Attribute Summary collapse
-
#host ⇒ Object
Returns the value of attribute host.
-
#port ⇒ Object
Returns the value of attribute port.
-
#protocol ⇒ Object
Returns the value of attribute protocol.
-
#read_timeout ⇒ Object
Returns the value of attribute read_timeout.
Instance Method Summary collapse
- #create_client(&block) ⇒ Object
-
#initialize ⇒ GroongaOptions
constructor
A new instance of GroongaOptions.
Constructor Details
#initialize ⇒ GroongaOptions
Returns a new instance of GroongaOptions.
369 370 371 372 373 374 |
# File 'lib/groonga-query-log/server-verifier.rb', line 369 def initialize @host = "127.0.0.1" @port = 10041 @protocol = :gqtp @read_timeout = Groonga::Client::Default::READ_TIMEOUT end |
Instance Attribute Details
#host ⇒ Object
Returns the value of attribute host.
365 366 367 |
# File 'lib/groonga-query-log/server-verifier.rb', line 365 def host @host end |
#port ⇒ Object
Returns the value of attribute port.
366 367 368 |
# File 'lib/groonga-query-log/server-verifier.rb', line 366 def port @port end |
#protocol ⇒ Object
Returns the value of attribute protocol.
367 368 369 |
# File 'lib/groonga-query-log/server-verifier.rb', line 367 def protocol @protocol end |
#read_timeout ⇒ Object
Returns the value of attribute read_timeout.
368 369 370 |
# File 'lib/groonga-query-log/server-verifier.rb', line 368 def read_timeout @read_timeout end |
Instance Method Details
#create_client(&block) ⇒ Object
376 377 378 379 380 381 382 |
# File 'lib/groonga-query-log/server-verifier.rb', line 376 def create_client(&block) Groonga::Client.open(:host => @host, :port => @port, :protocol => @protocol, :read_timeout => @read_timeout, &block) end |