Change string variable depending on its content

I’m not very conversant in Java, so I need some help with syntax and possibly which node would be best to use.

At the beginning of my workflow I have a Single Selection Configuration that defines a string variable called ‘PlateFormat’. It’s possible values are ‘96w’, ‘384w’, and 1536w’. At the end of my workflow I need to write a csv file with a header that needs to incorporate information based on this ‘PlateFormat’ variable. But instead of the strings above, the variable content needs to be changed as follows depending on the content (in sort-of pseudo code):

CASE PlateFormat OF

96w: replace “96w” with “# PlateFormat\t 8\t 12”

384w: replace “384w” with# PlateFormat\t 16\t 24

1536w: replace “1536w” with # PlateFormat\t 32\t 48

ENDCASE

There are probably many ways to go about it, and I had some partial success using the String Manipulation (Variable) node using this syntax:

replace($${SPlateFormat}$$, “96w”, “# PlateFormat\t 8\t 12”)

But adding other lines for the remaining two cases leads to an error (maybe not too surprisingly). I assume, the Java Edit Variable node is probably most appropriate here, but I read somewhere that case statements with variables are not allowed in Java. So, does this have to be accomplished with nested if-then statements? In either case, I don’t know the proper syntax to implement this and would appreciate some help.