Class: ActionDispatch::Routing::Mapper
- Inherits:
-
Object
- Object
- ActionDispatch::Routing::Mapper
- Defined in:
- lib/age_de_xml/rails/routes.rb
Instance Method Summary collapse
-
#age_de_xml(options = {}) ⇒ Object
Includes age_de_xml method for routes.
Instance Method Details
#age_de_xml(options = {}) ⇒ Object
Includes age_de_xml method for routes. This method is responsible to generate age-de.xml route and configure its content.
Examples
age_de_xml host: 'example.de', age: 18
Options
You can configure age-de with some options:
* :domain => host name
* :age => allowed age
16 17 18 19 |
# File 'lib/age_de_xml/rails/routes.rb', line 16 def age_de_xml(={}) AgeDeXml.() if get 'age-de.xml', to: 'age_de_xml#show', defaults: { format: :xml } end |