Pass a Python dict to a Java map possibly with JSON?
You could pass it as JSON, and parse the info out of the JSON in Java.
If the data is more simple, you could make every other String in Java's String[] args parameter represent a key or value, and then have your code loop through those and add them to a map.
I am calling a Java file within Python code. Currently, I am passing it several parameters which Java sees in its String[] args array. I would prefer to pass just one parameter that is a Python dictionary (dict) which Java can understand and make into a map. I know I will probably have to pass the python dictionary as a string.
How can I do this? Should I use JSON?