Class: BreadcrumbsOnRails::Breadcrumbs::Element
- Inherits:
-
Object
- Object
- BreadcrumbsOnRails::Breadcrumbs::Element
- Defined in:
- lib/breadcrumbs_on_rails/breadcrumbs.rb
Overview
Represents a navigation element in the breadcrumb collection.
Instance Attribute Summary collapse
-
#name ⇒ String
The element/link name.
-
#options ⇒ Hash
The element/link options.
-
#path ⇒ String
The element/link URL.
Instance Method Summary collapse
-
#initialize(name, path = nil, options = {}) ⇒ Element
constructor
Initializes the Element with given parameters.
Constructor Details
#initialize(name, path = nil, options = {}) ⇒ Element
Initializes the Element with given parameters.
121 122 123 124 125 |
# File 'lib/breadcrumbs_on_rails/breadcrumbs.rb', line 121 def initialize(name, path = nil, = {}) self.name = name self.path = path self. = end |
Instance Attribute Details
#name ⇒ String
Returns The element/link name.
108 109 110 |
# File 'lib/breadcrumbs_on_rails/breadcrumbs.rb', line 108 def name @name end |
#options ⇒ Hash
Returns The element/link options.
112 113 114 |
# File 'lib/breadcrumbs_on_rails/breadcrumbs.rb', line 112 def @options end |
#path ⇒ String
Returns The element/link URL.
110 111 112 |
# File 'lib/breadcrumbs_on_rails/breadcrumbs.rb', line 110 def path @path end |