public inbox for java@gcc.gnu.org
 help / color / mirror / Atom feed
* Reading command line parameters in gcj compiled exe
@ 2009-01-23 16:50 Jary Grove
  2009-01-23 16:54 ` Andrew Haley
  0 siblings, 1 reply; 3+ messages in thread
From: Jary Grove @ 2009-01-23 16:50 UTC (permalink / raw)
  To: java

I have natively compiled an application using gcj compiler, how can I pass/read the command line parameters in the main java class?

For example my command line with parameters is  tools.exe param1 param2

Thanks
Jary


---------------------------------------------------------------------------------------
Active Directory Browser: http://www.ldapsoft..com/adtool.html





^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Reading command line parameters in gcj compiled exe
  2009-01-23 16:50 Reading command line parameters in gcj compiled exe Jary Grove
@ 2009-01-23 16:54 ` Andrew Haley
  2009-01-23 17:15   ` Jary Grove
  0 siblings, 1 reply; 3+ messages in thread
From: Andrew Haley @ 2009-01-23 16:54 UTC (permalink / raw)
  To: Jary Grove; +Cc: java

Jary Grove wrote:
> I have natively compiled an application using gcj compiler, how can I pass/read the command line parameters in the main java class?
> 
> For example my command line with parameters is  tools.exe param1 param2

It's the same as usual; you have a method in your main class that
takes the args:

  public static void main(String[] args)

Andrew.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Reading command line parameters in gcj compiled exe
  2009-01-23 16:54 ` Andrew Haley
@ 2009-01-23 17:15   ` Jary Grove
  0 siblings, 0 replies; 3+ messages in thread
From: Jary Grove @ 2009-01-23 17:15 UTC (permalink / raw)
  To: java

Thanks Andrew. 

It worked!

Jary




---------------------------------------------------------------------------------------
Active Directory Browser: http://www.ldapsoft.com/adtool.html



----- Original Message ----
> From: Andrew Haley <aph@redhat.com>
> To: Jary Grove <jarygrove@yahoo.com>
> Cc: java@gcc.gnu.org
> Sent: Friday, January 23, 2009 10:54:13 AM
> Subject: Re: Reading command line parameters in gcj compiled exe
> 
> Jary Grove wrote:
> > I have natively compiled an application using gcj compiler, how can I 
> pass/read the command line parameters in the main java class?
> > 
> > For example my command line with parameters is  tools.exe param1 param2
> 
> It's the same as usual; you have a method in your main class that
> takes the args:
> 
>   public static void main(String[] args)
> 
> Andrew.





^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2009-01-23 17:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-01-23 16:50 Reading command line parameters in gcj compiled exe Jary Grove
2009-01-23 16:54 ` Andrew Haley
2009-01-23 17:15   ` Jary Grove

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).