Class: AemLookout::Sync::Hostname
- Inherits:
-
Object
- Object
- AemLookout::Sync::Hostname
- Defined in:
- lib/aem_lookout/sync.rb
Instance Attribute Summary collapse
-
#url ⇒ Object
Returns the value of attribute url.
Instance Method Summary collapse
- #credentials ⇒ Object
-
#initialize(hostname) ⇒ Hostname
constructor
A new instance of Hostname.
- #url_without_credentials ⇒ Object
Constructor Details
#initialize(hostname) ⇒ Hostname
Returns a new instance of Hostname.
12 13 14 |
# File 'lib/aem_lookout/sync.rb', line 12 def initialize(hostname) @url = URI.parse(hostname) end |
Instance Attribute Details
#url ⇒ Object
Returns the value of attribute url.
10 11 12 |
# File 'lib/aem_lookout/sync.rb', line 10 def url @url end |
Instance Method Details
#credentials ⇒ Object
20 21 22 |
# File 'lib/aem_lookout/sync.rb', line 20 def credentials "#{url.user}:#{url.password}" end |
#url_without_credentials ⇒ Object
16 17 18 |
# File 'lib/aem_lookout/sync.rb', line 16 def url_without_credentials "#{url.scheme}://#{url.host}:#{url.port}/crx/-/jcr:root" end |