lib/qpid_proton/data.rb in qpid_proton-0.5 vs lib/qpid_proton/data.rb in qpid_proton-0.6

- old
+ new

@@ -109,9 +109,17 @@ proc { Cproton.pn_data_free(data) if @free } end + def to_s + tmp = Cproton.pn_string("") + Cproton.pn_inspect(@data, tmp) + result = Cproton.pn_string_get(tmp) + Cproton.pn_free(tmp) + return result + end + # Clears the object. def clear Cproton.pn_data_clear(@data) end