Jesper Steen Møller <> (jespersm)

r845153, r844968, r844922, r844862

r844862 | dlr | 2003-02-07 21:59:00 +0000 (Fri, 07 Feb 2003)

Work towards usable SWIG/Java bindings.  Jesper says that this gives
us hash conversion and a usable `svn st` command.

Patch by: Jesper Steen Møller <>

* subversion/bindings/swig/apr.i
* subversion/bindings/swig/svn_client.i
* subversion/bindings/swig/svn_string.i
* subversion/bindings/swig/svn_types.i
* subversion/bindings/swig/util.i
  Typemaps for Java and JNI.

* subversion/bindings/swig/swigutil_java.h
  (SWIG_NewPointerObj): Removed function.  Jesper indicates its not
  (svn_swig_java_add_to_map): Adds all the elements from a hash to an
    existing java.util.Map
  (svn_swig_java_notify_func): A notify function that executes a Java
    method on an object which is passed in via the baton argument.
  (svn_swig_java_get_commit_log_func): Thunked commit log fetcher.
  (svn_swig_java_log_message_receiver): Log messages are returned in

* subversion/bindings/swig/swigutil_java.c
  (make_pointer): Now returns a java.lang.Long as a jobject.
  (make_ob_pool, make_ob_window): Removed functions.
  (convert_hash): converter_func argument now itself takes a JNIEnv *.
  (svn_swig_java_add_to_map): No longer static.  Now takes a JNIEnv *.
    Implementation heavily modified.
  (convert_to_swigtype): Now implemented using make_pointer().
  (convert_svn_string_t): Now implemented using JNI's NewStringUTF().
  (svn_swig_java_prophash_to_dict): Now implemented using JNI's
  (svn_swig_java_array_to_list): Improved impl.
  (make_baton): Notes new global references to editor and baton.
  (svn_swig_java_notify_func, svn_swig_java_get_commit_log_func,
   svn_swig_java_log_message_receiver): New stub functions.

r844922 | dlr | 2003-02-11 23:57:26 +0000 (Tue, 11 Feb 2003)

* subversion/bindings/swig/apr.i:
  Correct the apr_hash_t typemaps.

Patch by: Jesper Steen Møller <>

r844968 | dlr | 2003-02-14 03:53:51 +0000 (Fri, 14 Feb 2003)

Patch by: Jesper Steen Møller <>

* subversion/bindings/swig/svn_types.i
  (const char*MAY_BE_NULL): Added Java specific code for which maps a null
  String input to a NULL const char* pointer. It's not doing anything
  different than the standard typemap for const char*. This took out a
  SWIG warning.

  (javaptrconstructormodifiers): Changed the constructor for Java type
  wrapper modifiers to public instead of protected.

  (const char *PTR, apr_size_t LEN): Added a Java mapping accepting byte[]
  (possibly null)

* subversion/bindings/swig/svn_fs.i
  (entries_p,changed_paths_p): Marked two specific "apr_hash_t **" typemaps
  to be Python specific since they were using t_output_helper.
  Until we figure out even more about how to deal with hashes in Java,
  they were only adding to the confusion by being general. Right now,
  all hash type control is done in the Java realm.

* subversion/bindings/swig/util.i
  (getCPtr): Removed the extra getCPtr typemap for Java, since it would
  get picked up in apr.i anyway.

  (struct getdate_time *now): Made typemap for Python specific.

r845153 | jespersm | 2003-02-25 00:51:19 +0000 (Tue, 25 Feb 2003)

* subversion/bindings/swig/apr.i
  (apr_hash_t**) Removed typemap for (java, out) since that is used only
  for struct members.
  (apr_array_header_t**) Ditto. This was was causing a compile error since
  SWIG had put a $input into a .c file.

* subversion/bindings/swig/svn_types.i
  (apr_pool_t *pool): Used a better cast that won't generate warnings on
  GCC. Now the compile of Java SWIG is down to one (SWIG) warning..