Class: Middleman::Sitemap::Extensions::Proxies::ProxyConfiguration
- Inherits:
-
Object
- Object
- Middleman::Sitemap::Extensions::Proxies::ProxyConfiguration
- Defined in:
- lib/middleman-core/sitemap/extensions/proxies.rb
Overview
Configuration for a proxy instance
Instance Attribute Summary collapse
-
#metadata ⇒ Object
Additional metadata like blocks and locals to apply to the proxy.
-
#path ⇒ Object
The path that this proxy will appear at in the sitemap.
-
#target ⇒ Object
The existing sitemap path that this will proxy to.
Instance Method Summary collapse
-
#eql?(other) ⇒ Boolean
Two configurations are equal if they reference the same path.
-
#hash ⇒ Object
Two configurations are equal if they reference the same path.
-
#initialize(options = {}) ⇒ ProxyConfiguration
constructor
Create a new proxy configuration from hash options.
Constructor Details
#initialize(options = {}) ⇒ ProxyConfiguration
Create a new proxy configuration from hash options
146 147 148 149 150 |
# File 'lib/middleman-core/sitemap/extensions/proxies.rb', line 146 def initialize(={}) .each do |key, value| send "#{key}=", value end end |
Instance Attribute Details
#metadata ⇒ Object
Additional metadata like blocks and locals to apply to the proxy
143 144 145 |
# File 'lib/middleman-core/sitemap/extensions/proxies.rb', line 143 def @metadata end |
#path ⇒ Object
The path that this proxy will appear at in the sitemap
131 132 133 |
# File 'lib/middleman-core/sitemap/extensions/proxies.rb', line 131 def path @path end |
#target ⇒ Object
The existing sitemap path that this will proxy to
137 138 139 |
# File 'lib/middleman-core/sitemap/extensions/proxies.rb', line 137 def target @target end |
Instance Method Details
#eql?(other) ⇒ Boolean
Two configurations are equal if they reference the same path
153 154 155 |
# File 'lib/middleman-core/sitemap/extensions/proxies.rb', line 153 def eql?(other) other.path == path end |
#hash ⇒ Object
Two configurations are equal if they reference the same path
158 159 160 |
# File 'lib/middleman-core/sitemap/extensions/proxies.rb', line 158 def hash path.hash end |