Jansi is a java library for generating and interpreting ANSI escape sequences.
https://fusesource.github.io/jansi/