jinterface: implement support for maps

The API and implementation are simplistic, like for lists and tuples,
using arrays and without any connection to java.util.Map.