Class: HostedSolr::API::SolrCore
- Inherits:
-
Object
- Object
- HostedSolr::API::SolrCore
- Includes:
- ActiveModel::Model
- Defined in:
- lib/hosted_solr/api/solr_core.rb
Direct Known Subclasses
DrupalSolrCore, MagentoSolrBridgeSearchSolrCore, MagentoSolrCore, SolrForTypo320xSolrCore, SolrForTypo3301SolrCore, SolrForTypo3310SolrCore, SunspotSolrCore
Instance Attribute Summary collapse
-
#created_at ⇒ Object
Returns the value of attribute created_at.
-
#host ⇒ Object
Returns the value of attribute host.
-
#id ⇒ Object
Returns the value of attribute id.
-
#internal_name ⇒ Object
Returns the value of attribute internal_name.
-
#is_activated ⇒ Object
Returns the value of attribute is_activated.
-
#name ⇒ Object
Returns the value of attribute name.
-
#password ⇒ Object
Returns the value of attribute password.
-
#schema ⇒ Object
Returns the value of attribute schema.
-
#solr_version ⇒ Object
Returns the value of attribute solr_version.
-
#system ⇒ Object
Returns the value of attribute system.
-
#updated_at ⇒ Object
Returns the value of attribute updated_at.
Class Method Summary collapse
Instance Method Summary collapse
Instance Attribute Details
#created_at ⇒ Object
Returns the value of attribute created_at.
9 10 11 |
# File 'lib/hosted_solr/api/solr_core.rb', line 9 def created_at @created_at end |
#host ⇒ Object
Returns the value of attribute host.
9 10 11 |
# File 'lib/hosted_solr/api/solr_core.rb', line 9 def host @host end |
#id ⇒ Object
Returns the value of attribute id.
9 10 11 |
# File 'lib/hosted_solr/api/solr_core.rb', line 9 def id @id end |
#internal_name ⇒ Object
Returns the value of attribute internal_name.
9 10 11 |
# File 'lib/hosted_solr/api/solr_core.rb', line 9 def internal_name @internal_name end |
#is_activated ⇒ Object
Returns the value of attribute is_activated.
9 10 11 |
# File 'lib/hosted_solr/api/solr_core.rb', line 9 def is_activated @is_activated end |
#name ⇒ Object
Returns the value of attribute name.
9 10 11 |
# File 'lib/hosted_solr/api/solr_core.rb', line 9 def name @name end |
#password ⇒ Object
Returns the value of attribute password.
9 10 11 |
# File 'lib/hosted_solr/api/solr_core.rb', line 9 def password @password end |
#schema ⇒ Object
Returns the value of attribute schema.
9 10 11 |
# File 'lib/hosted_solr/api/solr_core.rb', line 9 def schema @schema end |
#solr_version ⇒ Object
Returns the value of attribute solr_version.
9 10 11 |
# File 'lib/hosted_solr/api/solr_core.rb', line 9 def solr_version @solr_version end |
#system ⇒ Object
Returns the value of attribute system.
9 10 11 |
# File 'lib/hosted_solr/api/solr_core.rb', line 9 def system @system end |
#updated_at ⇒ Object
Returns the value of attribute updated_at.
9 10 11 |
# File 'lib/hosted_solr/api/solr_core.rb', line 9 def updated_at @updated_at end |
Class Method Details
.from_hash(attributes_hash = {}) ⇒ Object
21 22 23 |
# File 'lib/hosted_solr/api/solr_core.rb', line 21 def self.from_hash(attributes_hash = {}) new(attributes_hash.slice(*%w(id solr_version system schema name host internal_name password is_activated created_at updated_at))) end |
Instance Method Details
#connection_uri ⇒ Object
33 34 35 |
# File 'lib/hosted_solr/api/solr_core.rb', line 33 def connection_uri URI("#{protocol}://#{internal_name}:#{password}@#{host}:#{port}/#{internal_name}/core") end |
#port ⇒ Object
25 26 27 |
# File 'lib/hosted_solr/api/solr_core.rb', line 25 def port 443 end |
#protocol ⇒ Object
29 30 31 |
# File 'lib/hosted_solr/api/solr_core.rb', line 29 def protocol 'https' end |