Enable passing of parameters to the java snippets.
Guard against null, should always be snippet etc but never know.
Merge pull request #1229 from fmoloney/ParameteriseJavaSnippets

Enable passing of parameters to the java snippets.