You should specify in the javadoc and in the function remarks that the default flag is 0 (and hence the default output format is MULTIPOLYGON).