annotate java/jdc/org_dyncall_DC.c @ 21:40a2c4198016

- working jdc (but with memleaks, currently) - added example
author cslag
date Wed, 30 Mar 2016 23:40:52 +0200
parents 77ca609422f1
children 4ee8d6aa7721
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
1 #include "org_dyncall_DC.h"
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
2 #include "dyncall.h"
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
3 #include "dynload.h"
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
4
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
5 jlong JNICALL Java_org_dyncall_DC_newCallVM(JNIEnv *pEnv, jclass clazz, jint size)
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
6 {
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
7 return (jlong)dcNewCallVM(size);
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
8 //@@@ free
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
9 }
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
10
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
11 jlong JNICALL Java_org_dyncall_DC_load(JNIEnv *pEnv, jclass clazz, jstring s)
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
12 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
13 jlong l = 0;
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
14 const char *sz = (*pEnv)->GetStringUTFChars(pEnv, s, NULL);
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
15 if(sz != NULL) {
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
16 l = (jlong)dlLoadLibrary(sz);
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
17 (*pEnv)->ReleaseStringUTFChars(pEnv, s, sz);
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
18 //@@@ free
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
19 }
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
20 return l;
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
21 }
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
22
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
23 jlong JNICALL Java_org_dyncall_DC_find(JNIEnv *pEnv, jclass clazz, jlong libhandle, jstring s)
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
24 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
25 jlong l = 0;
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
26 const char *sz = (*pEnv)->GetStringUTFChars(pEnv, s, NULL);
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
27 if(sz != NULL) {
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
28 l = (jlong)dlFindSymbol((DLLib*)libhandle, sz);
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
29 (*pEnv)->ReleaseStringUTFChars(pEnv, s, sz);
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
30 }
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
31 return l;
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
32 }
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
33
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
34 //jint JNICALL Java_org_dyncall_DC_symsCount(JNIEnv *pEnv, jclass clazz, jlong symshandle)
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
35 //{
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
36 // return dlSymsCount((DLSyms*)symshandle);
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
37 //}
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
38
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
39 //jstring JNICALL Java_org_dyncall_DC_symsName(JNIEnv *pEnv, jclass clazz, jlong symshandle, jint i)
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
40 //{
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
41 // return dlSymsName((DLSyms*)symshandle, i);
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
42 //}
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
43
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
44 void JNICALL Java_org_dyncall_DC_mode(JNIEnv *pEnv, jclass clazz, jlong vm, jint i)
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
45 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
46 dcMode((DCCallVM*)vm, i);//@@@test
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
47 }
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
48
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
49 void JNICALL Java_org_dyncall_DC_reset(JNIEnv *pEnv, jclass clazz, jlong vm)
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
50 {
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
51 dcReset((DCCallVM*)vm);
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
52 //@@@add cleanup code here for temporary memory held by jni
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
53 }
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
54
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
55 void JNICALL Java_org_dyncall_DC_argBool(JNIEnv *pEnv, jclass clazz, jlong vm, jboolean b)
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
56 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
57 dcArgBool((DCCallVM*)vm, b);//@@@test
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
58 }
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
59
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
60 void JNICALL Java_org_dyncall_DC_argChar(JNIEnv *pEnv, jclass clazz, jlong vm, jbyte b)
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
61 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
62 dcArgChar((DCCallVM*)vm, b);//@@@test
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
63 }
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
64
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
65 void JNICALL Java_org_dyncall_DC_argShort(JNIEnv *pEnv, jclass clazz, jlong vm, jshort s)
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
66 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
67 dcArgShort((DCCallVM*)vm, s);//@@@test
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
68 }
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
69
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
70 void JNICALL Java_org_dyncall_DC_argInt(JNIEnv *pEnv, jclass clazz, jlong vm, jint i)
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
71 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
72 dcArgInt((DCCallVM*)vm, i);//@@@test
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
73 }
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
74
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
75 void JNICALL Java_org_dyncall_DC_argLong(JNIEnv *pEnv, jclass clazz, jlong vm, jlong l)
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
76 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
77 dcArgLong((DCCallVM*)vm, l);//@@@test
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
78 }
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
79
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
80 void JNICALL Java_org_dyncall_DC_argLongLong(JNIEnv *pEnv, jclass clazz, jlong vm, jlong l)
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
81 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
82 dcArgLongLong((DCCallVM*)vm, l);//@@@test
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
83 }
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
84
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
85 void JNICALL Java_org_dyncall_DC_argFloat(JNIEnv *pEnv, jclass clazz, jlong vm, jfloat f)
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
86 {
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
87 dcArgFloat((DCCallVM*)vm, f);
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
88 }
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
89
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
90 void JNICALL Java_org_dyncall_DC_argDouble(JNIEnv *pEnv, jclass clazz, jlong vm, jdouble d)
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
91 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
92 dcArgDouble((DCCallVM*)vm, d);
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
93 }
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
94
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
95 void JNICALL Java_org_dyncall_DC_argPointer__JJ(JNIEnv *pEnv, jclass clazz, jlong vm, jlong l)
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
96 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
97 dcArgPointer((DCCallVM*)vm, (DCpointer)l);//@@@test
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
98 }
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
99
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
100 void JNICALL Java_org_dyncall_DC_argPointer__JLjava_lang_Object_2(JNIEnv *pEnv, jclass clazz, jlong vm, jobject o)
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
101 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
102 dcArgPointer((DCCallVM*)vm, (DCpointer)o);//@@@test
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
103 }
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
104
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
105 void JNICALL Java_org_dyncall_DC_argString(JNIEnv *pEnv, jclass clazz, jlong vm, jstring s)
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
106 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
107 const char *sz = (*pEnv)->GetStringUTFChars(pEnv, s, NULL);
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
108 if(sz != NULL) {
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
109 dcArgPointer((DCCallVM*)vm, (DCpointer)sz);
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
110 //(*pEnv)->ReleaseStringUTFChars(pEnv, s, sz);
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
111 //@@@ free this string when vm is destroyed, reset
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
112 }
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
113 }
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
114
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
115 void JNICALL Java_org_dyncall_DC_callVoid (JNIEnv *pEnv, jclass clazz, jlong vm, jlong target)
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
116 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
117 dcCallVoid((DCCallVM*)vm, (DCpointer)target);//@@@test
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
118 }
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
119
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
120 jboolean JNICALL Java_org_dyncall_DC_callBool(JNIEnv *pEnv, jclass clazz, jlong vm, jlong target)
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
121 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
122 return dcCallBool((DCCallVM*)vm, (DCpointer)target);//@@@test
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
123 }
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
124
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
125 jbyte JNICALL Java_org_dyncall_DC_callChar(JNIEnv *pEnv, jclass clazz, jlong vm, jlong target)
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
126 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
127 return dcCallChar((DCCallVM*)vm, (DCpointer)target);//@@@test
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
128 }
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
129
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
130 jshort JNICALL Java_org_dyncall_DC_callShort(JNIEnv *pEnv, jclass clazz, jlong vm, jlong target)
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
131 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
132 return dcCallShort((DCCallVM*)vm, (DCpointer)target);//@@@test
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
133 }
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
134
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
135 jint JNICALL Java_org_dyncall_DC_callInt(JNIEnv *pEnv, jclass clazz, jlong vm, jlong target)
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
136 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
137 return dcCallInt((DCCallVM*)vm, (DCpointer)target);//@@@test
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
138 }
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
139
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
140 jlong JNICALL Java_org_dyncall_DC_callLong(JNIEnv *pEnv, jclass clazz, jlong vm, jlong target)
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
141 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
142 return dcCallLong((DCCallVM*)vm, (DCpointer)target);//@@@test
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
143 }
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
144
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
145 jlong JNICALL Java_org_dyncall_DC_callLongLong(JNIEnv *pEnv, jclass clazz, jlong vm, jlong target)
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
146 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
147 return dcCallLongLong((DCCallVM*)vm, (DCpointer)target);//@@@test
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
148 }
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
149
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
150 jfloat JNICALL Java_org_dyncall_DC_callFloat(JNIEnv *pEnv, jclass clazz, jlong vm, jlong target)
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
151 {
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
152 return dcCallFloat((DCCallVM*)vm, (DCpointer)target);
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
153 }
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
154
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
155 jdouble JNICALL Java_org_dyncall_DC_callDouble(JNIEnv *pEnv, jclass clazz, jlong vm, jlong target)
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
156 {
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
157 return dcCallDouble((DCCallVM*)vm, (DCpointer)target);
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
158 }
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
159
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
160 jlong JNICALL Java_org_dyncall_DC_callPointer(JNIEnv *pEnv, jclass clazz, jlong vm, jlong target)
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
161 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
162 return (jlong)dcCallPointer((DCCallVM*)vm, (DCpointer)target);//@@@test
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
163 }
0
0cfcc391201f initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
164
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
165 jstring JNICALL Java_org_dyncall_DC_callString(JNIEnv *pEnv, jclass clazz, jlong vm, jlong target)
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
166 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
167 return (*pEnv)->NewStringUTF(pEnv, dcCallPointer((DCCallVM*)vm, (DCpointer)target));//@@@test
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
168 }
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
169
20
77ca609422f1 - first working build of new java binding
cslag
parents: 19
diff changeset
170 jint JNICALL Java_org_dyncall_DC_getError(JNIEnv *pEnv, jclass clazz, jlong vm)
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
171 {
21
40a2c4198016 - working jdc (but with memleaks, currently)
cslag
parents: 20
diff changeset
172 return dcGetError((DCCallVM*)vm);//@@@test
18
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
173 }
3bfef07b0cd9 - cleanup of non-working java binding, restart work, somewhat different interface
cslag
parents: 0
diff changeset
174