Browse Source

Set empty String by default aka when null.

JNI-88
Hussein Kasem 7 years ago
parent
commit
6972cc12fc
  1. 22
      src/gen_java_Message.ysl2

22
src/gen_java_Message.ysl2

@ -163,7 +163,27 @@ tstylesheet {
||
}
when "$itype != $type"
||
private native «$itype» _get«$name»();
private native void _set«$name»(«$itype» value);
public «$type» get«$name»() {
«$itype» res = _get«$name»();
if(res != null)
return AbstractEngine.toUTF16(res);
else
return null;
}
public void set«$name»(«$type» value) {
if(value != null)
_set«$name»(AbstractEngine.toUTF8(value));
else
_set«$name»(new byte[0]);
}
||
when "$itype != $type"
||
private native «$itype» _get«$name»();

Loading…
Cancel
Save