“intelligently” parsing user input arguments

<>

This question already has an answer here:

Answers


Use Apache Common CLI library. It can parse options and arguments very well. http://commons.apache.org/proper/commons-cli/


There are numerous Java libraries "out there" that can help you with command line parsing; see Is there a good command line argument parser for Java? for examples.

However, parsing command arguments "intelligently" depends on where you are coming from:

  • If you want something that will parse command arguments according to a consistent syntax or meta-syntax, then some of those examples will surely do that.

  • If you want something that will magically understand what the user really means, then you are dreaming


Need Your Help

Versioning dependencies along with a project

git dojo playframework-2.0

I'm starting a project using Play Framework 2.0 and Dojo 1.8 and I'm going to use Git for version control. I wanted to know if it is a good practice to version Dojo files along with my project, sin...

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.