Class: ThinkingSphinx::Connection::JRuby

Inherits:
Object
  • Object
show all
Defined in:
lib/thinking_sphinx/connection.rb

Instance Attribute Summary (collapse)

Instance Method Summary (collapse)

Constructor Details

- (JRuby) initialize(address, port, options)

Returns a new instance of JRuby



97
98
99
100
101
# File 'lib/thinking_sphinx/connection.rb', line 97

def initialize(address, port, options)
  address = "jdbc:mysql://#{address}:#{searchd.mysql41}"
  @client = java.sql.DriverManager.getConnection address,
    options[:username], options[:password]
end

Instance Attribute Details

- (Object) client (readonly)

Returns the value of attribute client



95
96
97
# File 'lib/thinking_sphinx/connection.rb', line 95

def client
  @client
end

Instance Method Details

- (Object) execute(statement)



103
104
105
# File 'lib/thinking_sphinx/connection.rb', line 103

def execute(statement)
  client.createStatement.execute statement
end

- (Object) query(statement)



107
108
109
# File 'lib/thinking_sphinx/connection.rb', line 107

def query(statement)
  #
end

- (Object) query_all(*statements)



111
112
113
# File 'lib/thinking_sphinx/connection.rb', line 111

def query_all(*statements)
  #
end