Exception: ImmutableAttributeError
- Defined in:
- lib/puppet/external/event-loop/better-definers.rb
Instance Method Summary collapse
-
#initialize(attribute = nil, message = nil) ⇒ ImmutableAttributeError
constructor
A new instance of ImmutableAttributeError.
- #to_s ⇒ Object
Constructor Details
#initialize(attribute = nil, message = nil) ⇒ ImmutableAttributeError
Returns a new instance of ImmutableAttributeError.
198 199 200 201 |
# File 'lib/puppet/external/event-loop/better-definers.rb', line 198 def initialize (attribute=nil, =nil) super @attribute = attribute end |
Instance Method Details
#to_s ⇒ Object
205 206 207 208 209 210 211 212 213 214 215 |
# File 'lib/puppet/external/event-loop/better-definers.rb', line 205 def to_s if @attribute and @message "cannot change the value of `#@attribute': #@message" elsif @attribute "cannot change the value of `#@attribute'" elsif @message "cannot change the value of attribute: #@message" else "cannot change the value of attribute" end end |