Exception: RSS::NotAvailableValueError
- Inherits:
-
InvalidRSSError
- Object
- StandardError
- Error
- InvalidRSSError
- RSS::NotAvailableValueError
- Defined in:
- lib/rss/rss.rb
Overview
Attributes are in key-value form, and if there’s no value provided for an attribute, a NotAvailableValueError will be raised.
Instance Attribute Summary collapse
-
#attribute ⇒ Object
readonly
Returns the value of attribute attribute.
-
#tag ⇒ Object
readonly
Returns the value of attribute tag.
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Instance Method Summary collapse
-
#initialize(tag, value, attribute = nil) ⇒ NotAvailableValueError
constructor
A new instance of NotAvailableValueError.
Constructor Details
#initialize(tag, value, attribute = nil) ⇒ NotAvailableValueError
Returns a new instance of NotAvailableValueError.
154 155 156 157 158 159 160 |
# File 'lib/rss/rss.rb', line 154 def initialize(tag, value, attribute=nil) @tag, @value, @attribute = tag, value, attribute = "value <#{value}> of " << "attribute <#{attribute}> of " if attribute << "tag <#{tag}> is not available." super() end |
Instance Attribute Details
#attribute ⇒ Object (readonly)
Returns the value of attribute attribute.
153 154 155 |
# File 'lib/rss/rss.rb', line 153 def attribute @attribute end |
#tag ⇒ Object (readonly)
Returns the value of attribute tag.
153 154 155 |
# File 'lib/rss/rss.rb', line 153 def tag @tag end |
#value ⇒ Object (readonly)
Returns the value of attribute value.
153 154 155 |
# File 'lib/rss/rss.rb', line 153 def value @value end |