RSS

Category Archives: jline

Command Line Input in Java

>

Today, someone introduced me to Spring Roo, which has quite some similarities with XINS at first glance. I really like the command line shell interface Roo has, featuring unbuffered text input, completion and fancy colors. I know it’s not even close to a rich IDE like NetBeans or Eclipse, but I love command line tools for their productivity and simpicity.

Looking at some documentation, the text-based shell interface is implemented using these technologies:

  • JLine – Library for handling console from Java, unbuffered.
  • JAnsi – Library for using ANSI escape sequences to format console output.
  • JNA – Windows-specific library for displaying colored output on Windows-systems.

Both libraries work on Windows, Mac OS X and Linux/UNIX-systems. Definitely worth considering in case you want to implement a console application in Java.

PS. Upon further inspection, Roo is very different from XINS, though. Roo is an aspect-oriented build-time code generator/manager that generates JSPs, Spring code, Java plumbing code (such as toString() methods), while XINS is an RPC-oriented component technology framework that also has (optional) runtime components (both client- and server-side, if you wish).

Advertisements
 
Leave a comment

Posted by on 28 December 2009 in jansi, java, jline, jna, roo, spring