Using complex Java types from JavaScript

Signed-off-by: Thomas Pasch <thomas.pasch@gmx.de>