Package com.api.jsonata4java.testerui
Class TesterUI
- java.lang.Object
-
- com.api.jsonata4java.testerui.TesterUI
-
public class TesterUI extends Object
A Swing UI app to test JSONata4Java interactively similar to the original JSONata Exerciser (see https://try.jsonata.org).- Author:
- Martin Bluemel
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedTesterUI()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected StringjsonToXml(String json)voidloadInput(Path path)voidloadJsonata(Path path)static voidmain(String[] args)protected static StringreadFile(Path filePath)voidsetBackgroundInput(Color color)voidsetBackgroundJsonata(Color color)voidsetBackgroundOutput(Color color)voidsetFont(Font font)protected StringxmlToJson(String xml)
-
-
-
Constructor Detail
-
TesterUI
protected TesterUI() throws IOException- Throws:
IOException
-
-
Method Detail
-
readFile
protected static String readFile(Path filePath) throws IOException
- Throws:
IOException
-
jsonToXml
protected String jsonToXml(String json) throws IOException
- Throws:
IOException
-
xmlToJson
protected String xmlToJson(String xml) throws IOException
- Throws:
IOException
-
main
public static void main(String[] args)
-
loadInput
public void loadInput(Path path)
-
loadJsonata
public void loadJsonata(Path path)
-
setBackgroundInput
public void setBackgroundInput(Color color)
-
setBackgroundJsonata
public void setBackgroundJsonata(Color color)
-
setBackgroundOutput
public void setBackgroundOutput(Color color)
-
setFont
public void setFont(Font font)
-
-