100: def change_to_s(current_value, newvalue)
101: begin
102: if current_value == :absent
103: return "defined '#{name}' as '#{should_to_s(newvalue)}'"
104: elsif newvalue == :absent or newvalue == [:absent]
105: return "undefined '#{name}' from '#{is_to_s(current_value)}'"
106: else
107: return "#{name} changed '#{is_to_s(current_value)}' to '#{should_to_s(newvalue)}'"
108: end
109: rescue Puppet::Error, Puppet::DevError
110: raise
111: rescue => detail
112: puts detail.backtrace if Puppet[:trace]
113: raise Puppet::DevError, "Could not convert change '#{name}' to string: #{detail}"
114: end
115: end