Parsing Java command line arguments when jar file and main class are specified -


my java execution run follows:

java -cp jar mainclass arga argb argc 

what arga correspond to? args[1] or args[4] ? thank you.

if main method defined as:

public static void main(string[] args) { 

then arga in args[0].

see oracle's command-line arguments tutorial example program.


Comments

Popular posts from this blog

apache - setting document root in antoher partition on ubuntu -

cytoscape.js - How to add nodes to Dagre layout with Cytoscape -

Process 'command 'F:\android-sdk\build-tools\21.1.2\aapt.exe'' finished with non-zero exit value 1 -