2013-02-06 31 views
0

如何獲取C++ DLL中的方法中的輸出參數?JNA - DLL中的輸出參數

public class MyClass { 

    public int error = 0; 

    public String MyMethod(){ 
     String str = null; 

     error = error(str); 

     if (error == 0){ 
      return str; 
     } 
     else 
      return null; 
    } 

    public native int error(String outputparam); 

    static { 
     Native.register("MyDLL"); 
    } 
} 
+0

本機聲明是什麼樣的? – technomage

回答