Determining on which system is program running

Discussion in 'Java' started by DeoXMAN, Apr 29, 2007.

  1. DeoXMAN

    DeoXMAN Guest

    Java is platform independent, but some task are platform dependent
    (for example shuttind down, as discussed in messages before). So is
    there a way to know on which platform program is runinng? whether it
    is windows, linux, or mac?
     
    DeoXMAN, Apr 29, 2007
    #1
    1. Advertisements

  2. DeoXMAN

    Daniel Dyer Guest

    On Sun, 29 Apr 2007 00:24:12 +0100, DeoXMAN <> wrote:

    > Java is platform independent, but some task are platform dependent
    > (for example shuttind down, as discussed in messages before). So is
    > there a way to know on which platform program is runinng? whether it
    > is windows, linux, or mac?


    <http://java.sun.com/javase/6/docs/api/java/lang/System.html#getProperties()>

    Dan.

    --
    Daniel Dyer
    https://watchmaker.dev.java.net - Evolutionary Algorithm Framework for Java
     
    Daniel Dyer, Apr 29, 2007
    #2
    1. Advertisements

  3. DeoXMAN

    Daniel Pitts Guest

    On Apr 28, 4:24 pm, DeoXMAN <> wrote:
    > Java is platform independent, but some task are platform dependent
    > (for example shuttind down, as discussed in messages before). So is
    > there a way to know on which platform program is runinng? whether it
    > is windows, linux, or mac?


    System.getProperties()
     
    Daniel Pitts, Apr 29, 2007
    #3
  4. DeoXMAN

    DeoXMAN Guest

    On Apr 29, 1:27 am, Daniel Pitts <> wrote:
    > On Apr 28, 4:24 pm, DeoXMAN <> wrote:
    >
    > > Java is platform independent, but some task are platform dependent
    > > (for example shuttind down, as discussed in messages before). So is
    > > there a way to know on which platform program is runinng? whether it
    > > is windows, linux, or mac?

    >
    > System.getProperties()


    thanks!
     
    DeoXMAN, Apr 29, 2007
    #4
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Achraf
    Replies:
    2
    Views:
    611
    Grumble
    Apr 28, 2004
  2. Replies:
    0
    Views:
    825
  3. Robert Rollins
    Replies:
    11
    Views:
    789
    red floyd
    Jul 11, 2007
  4. xz
    Replies:
    2
    Views:
    415
    Roedy Green
    Sep 6, 2007
  5. Mark Sullivan
    Replies:
    0
    Views:
    343
    Mark Sullivan
    Dec 21, 2007
  6. travel2light
    Replies:
    10
    Views:
    654
    Andrew Thompson
    Mar 10, 2008
  7. ruqiang826
    Replies:
    1
    Views:
    320
    Gerhard Häring
    Sep 11, 2008
  8. PerlFAQ Server
    Replies:
    0
    Views:
    208
    PerlFAQ Server
    Mar 7, 2011
Loading...