Package org.meeuw.json
Class Formatter
- java.lang.Object
-
- org.meeuw.json.AbstractJsonReader
-
- org.meeuw.json.Formatter
-
- All Implemented Interfaces:
Closeable,AutoCloseable
public class Formatter extends AbstractJsonReader
Pretty prints the json-stream. Depends entirely on jackson.- Author:
- Michiel Meeuwissen
-
-
Constructor Summary
Constructors Constructor Description Formatter(OutputStream out)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidhandleToken(ParseEvent event)static voidmain(String[] argv)protected voidready()-
Methods inherited from class org.meeuw.json.AbstractJsonReader
close, read, read
-
-
-
-
Constructor Detail
-
Formatter
public Formatter(OutputStream out) throws IOException
- Throws:
IOException
-
-
Method Detail
-
handleToken
protected void handleToken(ParseEvent event) throws IOException
- Specified by:
handleTokenin classAbstractJsonReader- Throws:
IOException
-
ready
protected void ready() throws IOException- Overrides:
readyin classAbstractJsonReader- Throws:
IOException
-
main
public static void main(String[] argv) throws IOException, org.apache.commons.cli.ParseException
- Throws:
IOExceptionorg.apache.commons.cli.ParseException
-
-