Correct special variables in 'directorargout' typemap. This change will break any 'directorargout' typemaps you may have written. Please change: to and to \n Also fix the named 'directorargout' DIRECTOROUT typemaps for these languages which didn't previously compile and add in , etc expansion.\n [C#, Go, Java, D] Add support for the 'directorargout' typemap.\n [Java] Add (char *STRING, size_t LENGTH) director typemaps.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12877 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
67993c8786
commit
468ca084fc
18 changed files with 249 additions and 96 deletions
|
|
@ -1307,6 +1307,13 @@ SWIG_PROXY_CONSTRUCTOR(true, true, SWIGTYPE)
|
|||
%typemap(argout) (char *STRING, size_t LENGTH) {
|
||||
JCALL3(ReleaseByteArrayElements, jenv, $input, (jbyte *)$1, 0);
|
||||
}
|
||||
%typemap(directorin, descriptor="[B") (char *STRING, size_t LENGTH) {
|
||||
jbyteArray jb = (jenv)->NewByteArray($2);
|
||||
(jenv)->SetByteArrayRegion(jb, 0, $2, (jbyte *)$1);
|
||||
$input = jb;
|
||||
}
|
||||
%typemap(directorargout) (char *STRING, size_t LENGTH)
|
||||
%{(jenv)->GetByteArrayRegion($input, 0, $2, (jbyte *)$1); %}
|
||||
%apply (char *STRING, size_t LENGTH) { (char *STRING, int LENGTH) }
|
||||
|
||||
/* java keywords */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue