diff --git a/CHANGES.current b/CHANGES.current index 1d09ab875..e6aebdb06 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,9 @@ See the RELEASENOTES file for a summary of changes in each release. Version 2.0.10 (in progress) ============================ +2013-01-29: William + [Java] Ensure 'javapackage' typemap is used as it stopped working from version 2.0.5. + 2013-01-28: William [Python] Apply patch SF #334 - Fix default value conversions "TRUE"->True, "FALSE"->False. diff --git a/Doc/Manual/Java.html b/Doc/Manual/Java.html index 8245d46eb..0024d602a 100644 --- a/Doc/Manual/Java.html +++ b/Doc/Manual/Java.html @@ -5662,7 +5662,7 @@ to make the method and constructor public:
The Java directors feature requires the "javadirectorin", "javadirectorout", "directorin" and the "directorout" typemaps in order to work properly. -The "javapackage" typemap is an optional typemap used to identify the Java package path for individual SWIG generated proxy classes. +The "javapackage" typemap is an optional typemap used to identify the Java package path for individual SWIG generated proxy classes used in director methods.
%typemap(directorin)
@@ -5803,6 +5803,7 @@ The target method is the method in the Java proxy class which overrides the virtThe "javapackage" typemap is optional; it serves to identify a class's Java package. This typemap should be used in conjunction with classes that are defined outside of the current SWIG interface file. +The typemap is only used if the type is used in a director method, that is, in a virtual method in a director class. For example:
@@ -5819,7 +5820,7 @@ For example: class Example { public: virtual ~Example(); - void ping(Foo *arg1, Bar *arg2); + virtual void ping(Foo *arg1, Bar *arg2); }; } @@ -5844,7 +5845,7 @@ The corrected interface file looks like: class Example { public: virtual ~Example(); - void ping(Foo *arg1, Bar *arg2); + virtual void ping(Foo *arg1, Bar *arg2); }; } diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index 987b6ddf6..2fb21eca8 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -3527,7 +3527,7 @@ public: String *pkg_path = Swig_typemap_lookup("javapackage", p, "", 0); SwigType *type = Getattr(p, "type"); - if (pkg_path || Len(pkg_path) == 0) + if (!pkg_path || Len(pkg_path) == 0) pkg_path = package_path; String *descriptor_out = Copy(descriptor_in);