Class: Khoj::Configuration
- Inherits:
-
Object
- Object
- Khoj::Configuration
- Defined in:
- lib/khoj/configuration.rb
Defined Under Namespace
Classes: Connection
Constant Summary collapse
- DEFAULTS =
{ :api_host => 'http://localhost:9200' }
Class Attribute Summary collapse
-
.api_host ⇒ Object
Returns the value of attribute api_host.
-
.api_key ⇒ Object
Returns the value of attribute api_key.
-
.valid ⇒ Object
Returns the value of attribute valid.
Class Method Summary collapse
Class Attribute Details
.api_host ⇒ Object
Returns the value of attribute api_host.
9 10 11 |
# File 'lib/khoj/configuration.rb', line 9 def api_host @api_host end |
.api_key ⇒ Object
Returns the value of attribute api_key.
8 9 10 |
# File 'lib/khoj/configuration.rb', line 8 def api_key @api_key end |
.valid ⇒ Object
Returns the value of attribute valid.
10 11 12 |
# File 'lib/khoj/configuration.rb', line 10 def valid @valid end |
Class Method Details
.connection ⇒ Object
12 13 14 |
# File 'lib/khoj/configuration.rb', line 12 def connection @connection ||= Connection.new(:url => Configuration.api_host).class end |
.valid? ⇒ Boolean
16 17 18 |
# File 'lib/khoj/configuration.rb', line 16 def valid? self.valid end |