jni4net Changelog

What's new in jni4net 0.8.6

Sep 27, 2011
  • fixed permission demand for sandboxed environments (Robocode)
  • improved proxygen can't find class reporting
  • improved the way we are looking for jni4net.j-xxx-.jar while installed in GAC
  • fixed - build script problems

New in jni4net 0.8.5 (Aug 18, 2011)

  • fixed - support for indexer properties
  • fixed - Change of current directory during init may disrupt other code running in parallel
  • fixed - DirectByteBuffer doesn't work with Java 7
  • fixed - Potential field name clash due to increasing numbering strategy of field names

New in jni4net 0.8.4 (Aug 18, 2011)

  • added JNIEnv.DetachCurrentThread()
  • fixed Bridge.setClrVersion() to static
  • added ability to load proxies into specified classLoader

New in jni4net 0.8.3 (Aug 18, 2011)

  • improved error logging during init from Java
  • added support for IBM JRE
  • added BridgeSetup.IgnoreJavaHome which will try detect/find proper JAVA_HOME based on the platform
  • added drools sample
  • added java.util.Date

New in jni4net 0.8.2 (Aug 18, 2011)

  • upgraded nMaven, NUnit, made build 32bit only
  • throwing exceptions for missing proxy classes
  • fixed - C# string[]{null} -> JVM -> null reference exception

New in jni4net 0.8.1 (Aug 18, 2011)

  • patch for CLR detection from Leonid Bogdanov
  • Fixed Memory leak of CLR instances wrapped to JVM, while calling from CLR

New in jni4net 0.8 (Aug 18, 2011)

  • added support for CLR v 4.0. v40 is now default if it could be found
  • added BridgeSetup.AddJVMOption(string)

New in jni4net 0.7.1 (Aug 18, 2011)

  • added ParPrimC2J(IntPtr)
  • Reading Java home location from the Windows registry
  • BridgeSetup extended with JavaHome, and improved JavaHome auto detection
  • fixed missing assembly version for jni4net.n.*.dll

New in jni4net 0.7 (Aug 18, 2011)

  • .NET events and delegates are supported by proxygen and runtime. From Java side they could be invoked with Invoke() method which has proper signature. Delegates could be also implemented on Java side, by usual anonymous class and passed back to CLR. So Java could subscribe to .NET events.
  • this.button1.addClick(new system.EventHandler(){
  • public void Invoke(system.Object sender, system.EventArgs e){
  • button1.setText("Clicked");
  • });
  • Full code is in winforms sample, which is part of binaries.
  • Other changes:
  • solved problem with spaces in path to dll/jar
  • assembly loading now uses java.io.File or assembly name (breaking change)
  • static class is no longer found by name, attribute parameter added (breaking change)

New in jni4net 0.6 (Aug 18, 2011)

  • Implemented out and ref parameter from C#
  • DateTime.TryParse has second parameter 'out'. This is how to use it from Java:
  • Out dt=new Out();
  • if (DateTime.TryParse("2009-08-28",dt)){
  • System.out.println(dt.getValue());
  • Improved proxygen to not generate virtual method overrides
  • Eliminated lot of warnings in generated code
  • Strongly typed JNI references (this is breaking change, please regenerate your proxies)
  • Sun specific DirectBufferCleaner, which holds the reference to pinned buffer
  • Native methods unregistration when appdomain unloads
  • Switched off signed .jar, because it prevents other people generating (unsigned) proxies into same packages. For example java.util_
  • Possibility to specify alternate classloader
  • Declarative security for running in partially trusted environments
  • JVM exceptions are serializable for CLR binary serialization

New in jni4net 0.5 (Aug 18, 2011)

  • Simplified proxygen to wrap all classes in DLL or JAR file from command-line, without time spent on config file. It as well provides very simplistic build.cmd. I will write another article about proxygen soon, till then look at new samples.
  • Ported java.nio.ByteBuffer to .NET, so you could share same byte array in both VMs. You are able to use BinaryWriter in .NET as well, but same byte order and interface is more convenient.
  • There are new Adapt.Enumeration and Adapt.Disposable methods on CLR side. They are convenience adapters from corresponding Java interfaces.
  • foreach (var prop in Adapt.Enumeration(javaSystemProperties.keys()))
  • cnt++;
  • using (var fis = Adapt.Disposable(new FileInputStream(classPath)))
  • using (var zis = Adapt.Disposable(new ZipInputStream(fis.Real)))
  • ZipEntry entry = zis.Real.getNextEntry();
  • while (entry!=null)
  • string name = entry.getName();
  • entry = zis.Real.getNextEntry();
  • Improved proxygen code generator
  • Few minor bugfixes
  • New troubleshooter page