6 namespace org { namespace ldk { namespace structs {
10 * A string that displays only printable characters, replacing control characters with
11 * [`core::char::REPLACEMENT_CHARACTER`].
13 public class PrintableString : CommonBase {
14 internal PrintableString(object _dummy, long ptr) : base(ptr) { }
16 if (ptr != 0) { bindings.PrintableString_free(ptr); }
19 public string get_a() {
20 long ret = bindings.PrintableString_get_a(this.ptr);
22 if (ret >= 0 && ret <= 4096) { return null; }
23 string ret_conv = InternalUtils.decodeString(ret);
27 public void set_a(string val) {
28 bindings.PrintableString_set_a(this.ptr, InternalUtils.encodeString(val));
34 * Constructs a new PrintableString given each field
36 public static PrintableString of(string a_arg) {
37 long ret = bindings.PrintableString_new(InternalUtils.encodeString(a_arg));
39 if (ret >= 0 && ret <= 4096) { return null; }
40 org.ldk.structs.PrintableString ret_hu_conv = null; if (ret < 0 || ret > 4096) { ret_hu_conv = new org.ldk.structs.PrintableString(null, ret); }
41 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
46 * Get the string representation of a PrintableString object
48 public string to_str() {
49 long ret = bindings.PrintableString_to_str(this.ptr);
51 if (ret >= 0 && ret <= 4096) { return null; }
52 string ret_conv = InternalUtils.decodeString(ret);