CString.fromString constructor

CString.fromString(
  1. String s
)

Allocates a buffer containing the UTF-8 representation of s, plus a null terminator.

Implementation

CString.fromString(String s) : _data = _stringToBytes(s);