Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 17 of 17

Thread: Java platform independent? Looks like a myth.

  1. #1
    Banned
    Join Date
    Aug 2012
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Java platform independent? Looks like a myth.

    Guys, I'm doing research on a Java and as this is a research paper I'm trying to be as objective as possible. From my own experience with Java I know that source code which is of some reasonable size will not successfully run on different platforms. It will run on the platform it was written on, but on the other/s will crash.
    Any thoughts?


  2. #2
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    18,604
    Thanks
    45
    Thanked 1,956 Times in 1,930 Posts

    Default Re: Java platform independent? Looks like a myth.

    It's possible to write java code that is platform specific.
    I don't see how Source code size is relevant. Can you explain what you mean or have observed?
    Last edited by Norm; August 11th, 2012 at 11:30 AM.
    If you don't understand my answer, don't ignore it, ask a question.

  3. #3
    Banned
    Join Date
    Aug 2012
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: Java platform independent? Looks like a myth.

    Quote Originally Posted by Norm View Post
    I don't see how Source code size is not relevant.
    If Java were platform independent than any program size would be independent, does it make sense? They (Oracle) do not advertise Java as platform independent up to x number of lines of code. Oracle says that Java is platform independent, I, and if you read articles on the net you'll see, that there are many other developers who admit that platform independency in Java is purely hyped and doesn't have any confirmation in real world.

  4. #4
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    18,604
    Thanks
    45
    Thanked 1,956 Times in 1,930 Posts

    Default Re: Java platform independent? Looks like a myth.

    Can you explain how program size effects platform independence?
    If you don't understand my answer, don't ignore it, ask a question.

  5. #5
    Super Moderator helloworld922's Avatar
    Join Date
    Jun 2009
    Posts
    2,896
    Thanks
    23
    Thanked 619 Times in 561 Posts
    Blog Entries
    18

    Default Re: Java platform independent? Looks like a myth.

    Platform independent doesn't mean you can run every Java program on multiple platform. Rather it means that there exists at least one Java program which when compiled can run on multiple platforms without re-compiling or any other kind of modification to the program.

    Any platform which does not meet this requirement would be considered non-Java compatible, which does not necessarily mean Java is not platform independent.
    Last edited by helloworld922; August 11th, 2012 at 11:49 AM.

  6. #6
    Junior Member
    Join Date
    Aug 2012
    Posts
    13
    Thanks
    0
    Thanked 7 Times in 4 Posts

    Default Re: Java platform independent? Looks like a myth.

    Java is known for its portability. I wouldn't consider it a hype.

  7. #7
    Super Moderator copeg's Avatar
    Join Date
    Oct 2009
    Location
    US
    Posts
    5,099
    Thanks
    169
    Thanked 779 Times in 725 Posts
    Blog Entries
    5

    Default Re: Java platform independent? Looks like a myth.

    I have written and tested dozens of programs in java, from command line to full blow enterprise applications, and the only cases of platform dependence were programmed dependencies. If you are having problems, then you are much better off asking a question to try and solve the problem, or quoting the sources of these articles you mention to validate your claim
    Last edited by copeg; August 11th, 2012 at 12:11 PM.

  8. #8
    Super Moderator pbrockway2's Avatar
    Join Date
    Jan 2012
    Posts
    939
    Thanks
    6
    Thanked 202 Times in 178 Posts

    Default Re: Java platform independent? Looks like a myth.

    Quote Originally Posted by ask View Post
    Guys, I'm doing research on a Java and as this is a research paper I'm trying to be as objective as possible. From my own experience with Java I know that source code which is of some reasonable size will not successfully run on different platforms. It will run on the platform it was written on, but on the other/s will crash.
    Any thoughts?
    My own 2c is that WORA is an invention of the Marketing department. It's not that it's a lie: the lawyers are too clever for that! But "anywhere" (=="platform independent") has to be interpreted as "anywhere that a runtime has been implemented". And the whole thing begins to sound a little like an impressive seeming tautology.

    The other side of this slightly tinny coin is the extent to which Java can (or can't) naturally access the capabilities of every platform. It's a little unsatisfying to be told that even mediocre support for a platform's console is "platform dependent" while knowing that Swing aims at providing a platform independent GUI. How can that be? Someone should tell the marketeers that the "I" in GUI is for interface: it's the same da@mn platform.

    (Moreover there is the logical point that different platforms are capable of doing different things. So a language that could fully utilitise each is bound to fail on some.)

    -----

    It's not my intention to dis Java. But if you are aiming at objectivity you might want to ask (and answer) objective questions. (and avoid "crashing" etc).

    What platforms have a Java runtime implemented on them?

    What capabilities of these platforms are supported, or not, by Java?

    What other (actual or being developed) languages aim separating the source code from the platform via compiling to byte code or by some other mechanism? And how do they fare relative to Java?

    What other languages take advantage of Java's runtime? And are they better or worse (to be given suitably objective definitions) than Java?

    What penalties, if any, does Java pay for compilation to byte code that can act as a cross platform lingua franca?

  9. #9
    Banned
    Join Date
    Aug 2012
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: Java platform independent? Looks like a myth.

    Quote Originally Posted by helloworld922 View Post
    Platform independent doesn't mean you can run every Java program on multiple platform.
    No, you are wrong. It means exactly that. If someone claims that Java is a platform independent it means Java, not some, perhaps one program written in Java. And I know from my own experience that Java is not platform independent.

  10. #10
    Banned
    Join Date
    Aug 2012
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: Java platform independent? Looks like a myth.

    Quote Originally Posted by helloworld922 View Post

    Any platform which does not meet this requirement would be considered non-Java compatible, which does not necessarily mean Java is not platform independent.
    I didn't know that platform supposed to be Java compatible, are we still talking about Java language?

  11. #11
    Banned
    Join Date
    Aug 2012
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: Java platform independent? Looks like a myth.

    Quote Originally Posted by Norm View Post
    Can you explain how program size effects platform independence?
    I've nowhere stated that program size effects platform independence.

  12. #12
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    18,604
    Thanks
    45
    Thanked 1,956 Times in 1,930 Posts

    Default Re: Java platform independent? Looks like a myth.

    source code which is of some reasonable size will not successfully run on different platforms.
    I must have misunderstood why you mentioned size here. I was wondering why you mentioned it.

    Did you mean: non-trivial? HelloWorld being a trivial program.
    If you don't understand my answer, don't ignore it, ask a question.

  13. #13
    Super Moderator pbrockway2's Avatar
    Join Date
    Jan 2012
    Posts
    939
    Thanks
    6
    Thanked 202 Times in 178 Posts

    Default Re: Java platform independent? Looks like a myth.

    Quote Originally Posted by ask View Post
    I've nowhere stated that program size effects platform independence.
    Then "I know that source code which is of some reasonable size will not..." might have been misleading.

  14. #14
    Banned
    Join Date
    Aug 2012
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: Java platform independent? Looks like a myth.

    Quote Originally Posted by copeg View Post
    I have written and tested dozens of programs in java, from command line to full blow enterprise applications
    Wow, in times where not only whole teams are working on "full blown" (there is 'n' at the end) applications but there are different teams for different areas, like design, implementation, testing just to name those most common, you yourself actually did the entire work yourself, and not on one application but on dozens. Wow!

    Son, seriously, either you don't know what full blown means, or your psychiatrist is lying to you and you need to look for different one. Feel really sorry for you.

  15. #15
    Super Moderator pbrockway2's Avatar
    Join Date
    Jan 2012
    Posts
    939
    Thanks
    6
    Thanked 202 Times in 178 Posts

    Default Re: Java platform independent? Looks like a myth.

    @ask: Your original post talked of objectivity and of a research paper. I don't know the standards expected by your peer reviewers, but your attitude here suggests you might not either.

    "Feel really sorry for you" and psychiatrist reference are uncalled for. AR
    Last edited by pbrockway2; August 11th, 2012 at 05:25 PM.

  16. #16
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    18,604
    Thanks
    45
    Thanked 1,956 Times in 1,930 Posts

    Default Re: Java platform independent? Looks like a myth.

    Sounds more like the OP is blowing his own horn instead of doing research.
    If you don't understand my answer, don't ignore it, ask a question.

  17. #17
    Super Moderator copeg's Avatar
    Join Date
    Oct 2009
    Location
    US
    Posts
    5,099
    Thanks
    169
    Thanked 779 Times in 725 Posts
    Blog Entries
    5

    Default Re: Java platform independent? Looks like a myth.

    Quote Originally Posted by ask View Post
    Wow, in times where not only whole teams are working on "full blown" (there is 'n' at the end) applications but there are different teams for different areas, like design, implementation, testing just to name those most common, you yourself actually did the entire work yourself, and not on one application but on dozens. Wow!

    Son, seriously, either you don't know what full blown means, or your psychiatrist is lying to you and you need to look for different one. Feel really sorry for you.

    Perhaps I should be looking for another psychiatrist, and better yet take a class in spelling. That aside, it is clearly becoming obvious you are not looking for objective opinions, but are trying to get a rise out of people. In other words, it is becoming apparent from your posts and those who have reported your posts, that you don't value the opinions of others. In other words, you are a troll. You have posted things which can be considered insults directed at other members of this forum. Thread locked
    Last edited by copeg; August 11th, 2012 at 06:07 PM.

Similar Threads

  1. Why java is platform independent(Video)
    By jessie143143 in forum The Cafe
    Replies: 5
    Last Post: April 28th, 2012, 01:59 AM
  2. Replies: 0
    Last Post: October 6th, 2011, 04:17 PM
  3. run java class file from independent of OS
    By starsoheil in forum Java Theory & Questions
    Replies: 6
    Last Post: March 16th, 2010, 08:05 AM
  4. How to execute a Java program independent of Netbeans.
    By ShaunB in forum Java Theory & Questions
    Replies: 4
    Last Post: January 19th, 2010, 05:23 AM
  5. cross platform architecture in Java/J2ee
    By softwarebuzz in forum Web Frameworks
    Replies: 1
    Last Post: January 9th, 2010, 01:43 PM

Tags for this Thread