java.exe MyClass flavour=strawberry
set flavour=strawberry java.exe MyClass %flavour%
System property flavour with value "strawberry "" will be accessible via System.getProperty(flavour"); Make sure you put the -D before your classname or else you will find -Dflavour=strawberry appearing at arg[0] instead. Contrary to rumour, this feature is also available in Java version 1.6 or later. Make sure you use an upper case
set flavour=strawberry java.exe -Dflavour=%flavour% MyClass
|
|
available on the web at: |
http://mindprod.com/jgloss/getenv.html |
optional Replicator mirror
|
J:\mindprod\jgloss\getenv.html | |
![]() |
Please email your
feedback for publication,
letters to the editor, errors, omissions, typos, formatting errors, ambiguities, unclear
wording, broken/redirected link reports, suggestions to improve this page or comments to
Roedy Green :
| |
| Blog | Canadian
Mind
Products
IP:[65.110.21.43] Your face IP:[54.234.67.55] |
|
| Feedback | You are visitor number 17,384. | |