Slashdot Mirror


Java vs .NET

CHaN_316 writes "Yahoo is running a story called 'Is Java Finished?' It provides a brief overview of the strengths and weaknesses of J2EE and contrasts them with .NET. Classic arguments are brought up like Java being great for portability while .NET ties you down to Microsoft products, etc. It's interesting that they bring up the Java Community Process, and how it is a rather slow moving procedure that is causing Java to become stagnant."

49 of 686 comments (clear)

  1. Java's not exactly pining for the fields just now by Mr.+Darl+McBride · · Score: 5, Insightful
    The Software Development Times ran an article which mentioned many of the perceived advantages of .NET, and Kuro5hin ran a story which did just the opposite. :)

    Dot Net doesn't look like a developer panacea just yet. If Sun keeps the enhancements coming and works to bring the development environment up to Visual Studio's standards (Yes, VS has its problems, but it has a lot of unique tools, like compile-and-continue, which save hours!), Java may well survive.

    Dot Net is also anything but small. It's possible to create ROMmable Java applications in just a couple megs of flash memory. On the other hand, there's no such thing as embedded dot Net just yet. And if they continue with the execution model they've currently got, any piece of code is going to net a ROM many times larger than what's possible with Java. Either way, I'll want $699 for my fp, beeyotch.

  2. Java vs. .Net by Anonymous Coward · · Score: 5, Insightful

    The ".Net only works on Microsoft" is more than just a classic arguement. In fact, I think it's the most important factor to take into account.

    If I want to make some simple embedded device, if I have to option to use Java instead of having to license Windows CE for my product, why would I ever choose MS over Java? .Net will never take off. After all, it hasn't during the 3 years its been out.

    1. Re:Java vs. .Net by bladernr · · Score: 5, Interesting
      I wouldn't say that .Net will never take off. Microsoft has access to senior executives in large corporations; I know that shouldn't make a difference, but it does. I am consulting at a major communications company now, and I just got a call from a VP an hour ago saying "Take a look at Microsoft for the stuff you are doing." It seems MS paid him a visit, and they are pitching lots of .Net/XP stuff against our existing HP SuperDome environments.

      Think of this another way: What if .Net was designed by a single person in their garage, would it get the attention it does? Of course not. Dot Net is a real threat to Java simply because it comes from Microsoft (a mega-corp with plenty of access).

      You may not like it (I know I don't), but that is the nature of things.

      --
      Sarcasm and hyperbole are the final refuges for weak minds
    2. Re:Java vs. .Net by jimfrost · · Score: 4, Interesting
      After all, it hasn't during the 3 years its been out.

      Technically .NET wasn't released until a year ago last spring. It's only been out about 18 months. Last fall it was clear that people using .NET were very early adopters, but uptake seems very strong.

      To be honest, Java on embedded devices doesn't seem like that big a win to me at the moment, no matter how many cellphones they're trying to ship with it. Most Java in use is on the server side. And that is a big differentiator between Java and .NET: Java runs on pretty much any hardware you care to throw at it, which means you can scale your server from that itty-bitty Pentium box up to the biggest stuff Sun sells. With Windows you've got midrange Intel boxes and ... midrange Intel boxes. Little per-box scalability, and that means that large systems are going to be a pain to manage - particularly given how hard it is to manage Windows servers in bulk.

      I can see .NET being useful for small servers that need to be put together quickly and cheaply; VS.NET is great for that. But it's not really there yet for big systems, both in terms of framework maturity and OS scalability and stability.

      Mostly I think we'll see .NET be used in building GUI applications in the near term. Let there be no mistake, it is phenomenal at that.

      --
      jim frost
      jimf@frostbytes.com
    3. Re:Java vs. .Net by JustAnotherReader · · Score: 4, Insightful
      The cross platform ability of Java is more than just marketing hype. I work for a large California Bank and our on-line banking software is written using Java servlets, Java Server Pages, and Enterprise Java Beans. We connect to an Oracle database via JDBC. As you can see we're very Java-centric

      The thing that really helps us is that we can develop code using WSAD (WebSphere Studio) on our Windows 2000 boxes on our desktop. We then deploy to a development sandbox made up of several Linux boxes (Same code, no recompile). Once we test it there we port it to our Development Test box which runs on IBM's AIX operating system (as do the test, stress test, and production servers).

      Could we pass our code around to multiple machines with 3 different operating systems using .NET? No way. Could we toss a WebSphere server on a cheap Linux box and have a test bed up and running in an afternoon? Absolutly, Could we do the same thing with a Windows 2000 server? Not if we want to expect the same level of performance (both speed and stability) out of the same hardware. And that doesn't begin to worry about the licensing cost of building that quick and dirty test bed with Linux and Java as opposed to Windows 2000 and .NET

      Nope, it's a bit too early to start reporting that Java is dead and .NET is the murderer. I think that in 5 more years I'll still be writing Java code and .NET will be sitting in a cardboard box of formerly used software in the closet along side COM, DCOM, and Active X.

  3. random thought of the day by carpe_noctem · · Score: 4, Funny

    Java vs .NET

    Hrm, reminds me of when two fat ugly chicks in my high school started a cat fight in the hallway.

    --
    "Quoting famous computer scientists out of context is the root of all evil (or at least most of it) in programming." - K
  4. Lies, statistics, and analysts by Sanity · · Score: 5, Insightful
    This John Rymer guy, around whom this entire article is based, is talking out of his arse. When will journalists learn that if you want to know something about software engineering, ask a software engineer? Only PHBs, clueless journalists, and other analysts listen to analysts.
    Java and .NET take vastly different approaches to development, said John Rymer, a vice president with Forrester Research. Java's philosophy of development is to expose low-level system interfaces to give developers greater control. Microsoft simplifies the development process; the developer has less control -- but the tools are easier to use.
    If anything, the opposite is true - the Java API is certainly higher-level when it comes to GUI stuff, and everything else is pretty analogous between the Java and .NET APIs.
    "Before, Microsoft was basically shut out of these projects," Rymer said. .NETs ease of use and lower licensing costs also will be a draw.
    Lower licensing costs than free? I would love to see that.

    Having worked with both Java and .NET, I would say that things like C#'s foreach statement make for easier and cleaner code, but Java 1.5 will leapfrog C# when it introduces generics along with its own version of foreach, and other timesaving features. Java's big failing, IMHO, is Swing. It is too big and too clunky, Java is crying out for a stripped down GUI library that is part of the API spec that will be as easy to work wit

    1. Re:Lies, statistics, and analysts by eap · · Score: 4, Insightful

      Analysts are nothing more than journalists whom other journalists call for information. It is somehow believed that if one reads enough of the complimentary trade magazines that every IT profesional gets, one somehow becomes an expert.

      I have noticed Slashdot seems to be posting a lot of these clueless journalist articles lately. I don't seek advice about my car from English majors, so why should I listen to them about computers? Let's have more articles from sources qualified to speak on their subjects.

    2. Re:Lies, statistics, and analysts by alext · · Score: 4, Insightful

      Because it's not championed by one megacorp, but by a whole array of commercial and non-commercial interests, including IBM, BEA, Nokia among a cast of thousands?

      If you feel this represents the same kind of vendor lock-in as Dotnet then your commercial antennae are in need of adjustment.

  5. Red Queen race by iangoldby · · Score: 5, Interesting

    causing Java to become stagnant

    Why would we not want a language to be stagnant? I wonder how much time is wasted just trying to keep up with changes to languages and development environments?

  6. Dotnet == Java by Nick+of+NSTime · · Score: 4, Funny

    Begun, the Clone() war has.

  7. An important thing to point out: by cygnus · · Score: 4, Insightful
    Java != J2EE. there are lots of great ways to write a Web application without using EJBs, for example, or writing a single line of JSP. check out the variety of projects at The Apache Jakarta Project for some examples.

    .NET vs. J2EE might be a more valid comparison than .NET vs. Java.

    --
    Just raise the taxes on crack.
  8. The prophet sayeth by Hayzeus · · Score: 4, Funny

    Whilst Java and .NET struggle for supremacy, APL shall return from the tomb of history triumphant once more. And there shall be much wailing and gnashing of teeth among the Javites and the unwashed .NET.ITES, but they will all perish as the light of a new Golden Age dawns, and the thousand year reign of APL begins anew.

  9. Come on ... by OMG · · Score: 5, Insightful

    .NET ? Blowing J2EE out of the water ?
    Are you serious ? Then:

    Where is the appserver that runs .NET ?

    Can you cluster that appserver like J2EE-appservers ?

  10. Stagnant? How about stable and secure. by greg_barton · · Score: 4, Insightful

    From the article:
    The slowness of the JCP holds up the creation of additional standards and services, he pointed out. In addition, standards proposals aimed at portability -- Java's strong suit -- are also stagnant.... "In the meantime, people want faster, easier development."

    Golly, I like slow, careful, and secure development of my enterprise backbone software. People may want faster inclusion of features, but they need stability and security.

    The latest flashy feature doesn't do shit if your enterprise backbone is crashing or being hacked into oblivion.

  11. Industry Newspeak by Stiletto · · Score: 5, Insightful


    You would think that a language or API that doesn't change every day would be praised with words such as "standardized" "stable" and "established".

    But in Bizarro World (where we all are apparently living), we criticize it as "stagnant" and "slow moving".

    Compare with the OpenGL/Direct3D discussions.

    Carpenters don't buy from hammer companies that change their hammers every "release".

    1. Re:Industry Newspeak by stratjakt · · Score: 5, Interesting

      Carpenters don't buy from hammer companies that change their hammers every "release".

      Sure they do, there's been a lot of innovation going into hammers lately. They release new versions of hammers constantly, and other woodworking tools - to many oldtimers dismay, who will swear up and down the hand plane they used in 1952 was an order of magnitude better than todays.

      Stanleys Anti-vibe series of hammers, for instance, they have whats basically a tuning fork built into the handle. The fork vibrates and takes the energy away from your hand. Spend a day ramming nails in with a wooden handled hammer, then a day with one of the newer models, and you definately feel the difference.

      They're also constantly adjusting the weights and balances, tweaking the shape and makeup of the heads/claws.

      Go look at the tool section at home depot and get an idea about hammers.

      --
      I don't need no instructions to know how to rock!!!!
  12. Is $TECHNOLOGY dead? by cubicledrone · · Score: 5, Insightful

    Any article that asks that question is automatically crap. Period. End of discussion.

    --
    Business isn't willing to pay for products, innovation and careers, so we get brands, mortgage commercials and layoffs.
  13. J2EE by cloudless.net · · Score: 4, Funny

    J2EE is written in all caps too.

    1. Re:J2EE by Cramer · · Score: 5, Funny

      The same wayyou capitalize '.'

  14. Java is dying, news at 11 by FeloniousPunk · · Score: 4, Interesting

    Sounds like more MS FUD to me. So how many times has Java been declared dead/ dying now?
    Where I work (for a DoD agency) we are developing J2EE solutions with open source tools in part to get away from vendor lock in, something that MS is particularly bad with. Once MS ratchets up the lock in with the introduction of DRM in Office file formats, I think MS solutions as a whole are going to become less attractive, and this will be a strong disincentive to adopt .NET.

    --
    I know this because Tyler knows this.
  15. Answer by r_j_prahad · · Score: 4, Funny

    Is Java finished?

    Of course it is... and this late in the day it's time to switch over to beer anyway.

  16. Re:Direction for Java by Irishman · · Score: 4, Informative
    Here are some links for Java Generics:
  17. What about Java on other platforms..... by smd4985 · · Score: 4, Interesting

    such as cell phones (J2ME) and Linux? From what I understand MS has no presence on cell phones (and there are a lot more cell phones than desktops) and they'll do their best to avoid needing to have a presence on Linux (i.e. bribe a down-and-out company to try and take out Linux in the courts).

    I think Sun has done a great job promoting Java on a variety of platforms, so I think McNealy isn't concerned about .NOT.

    --
    smd4985
  18. Re:VS sucks by dasmegabyte · · Score: 4, Interesting

    What the fuck are you smoking?

    There are some good Java IDEs, no doubt, but none of them can touch Visual Studio for, well, any single thing you could possibly want to do with an IDE. From designing interfaces, to writing code, to generating code, to debugging code, to remote debugging, it's just awesome and completely customizable.

    Maybe you just picked it up, said "Oh Microsoft, must be junk." You were wrong to do so; it's way better than VS 6. Maybe you saw the animated docking and said "Too pretty, must be junk." You're wrong again...that's the first thing I take out, but by and large it's not a whistles and bells IDE. Maybe you saw all the icons and thought, "Too visual, must be junk." You'd be wrong...everything you want to do in Studio.Net can be done without ever touching the designer, and in fact I don't have a single icon bar turned on in my IDE.

    Compared to Sun's IDE, the awesome in its own right open source Netbeans, VS is much faster for compilation, has more accurate and immediate response from controls and object generation is more reliable. The tools are for the most part simpler while at the same time being more complete. They are easier to use and you can mess with the generated code without destroying the associated resources (for the most part). VS.NET doesn't have as robust a feature set as some Java IDEs, but it's got plenty and it all works.

    --
    Hey freaks: now you're ju
  19. Re:Is Java finished? by egomaniac · · Score: 4, Informative

    I know you're trolling but, How is java related open sourced? I can not get the javac.exe source code.

    Please follow along carefully:

    1) Go to http://java.sun.com.
    2) Click the button labelled "J2SE - Core Java Software". It's the big blue button in the middle.
    3) On the next page, click "Source Licensing". It's in the links on the left-hand side of the page.
    4) On the Source Licensing page, click "Download".
    5) Follow the directions to download the entire J2SDK source code.

    Now, what was that about the source code not being available?

    --
    ZFS: because love is never having to say fsck
  20. Re:It's obvious by molarmass192 · · Score: 4, Interesting

    Sun's not a monopoly and don't make it sound like MS gave the entire .NET framework to the ECMA. Nope, just the C# langauge and the CLI, this would be like Sun turning over javac and java to the ECMA but keeping a grip on anything beyond Java primitives, it's a bullshit token PR jesture. The JCP is a far more public process for directing Java than anything we'll ever see from MS for .NET.

    --

    Good people do not need laws to tell them to act responsibly, while bad people will find a way around the laws-Plato
  21. Isn't that pining for the fjords? Anyway... by podperson · · Score: 5, Funny

    ...the best comment from Kuro5hin was that the only thing he likes about .NET is that VB's backwards compatibility is broken so maybe folks will learn a real language...

    1. Re:Isn't that pining for the fjords? Anyway... by ADRA · · Score: 4, Interesting

      Just to clearify, I am a low level hacker with C on the brains. I am not a bread and butter VB guy. If I wanted to make a quick and dirty GUI though, I could use VB 6 because my company owns it but more importantly, there was no complexity at all. Almost half the things I did were in the realm setting property X to value Y. Simple, quick, done.

      VB is not as much a programming language that became a GUI, but a prototyping tool that became a programming language. The move to VB.NET has taken away all the language simplicity making it a fully fledged language, but made it difficult enough to negate its benefits over other products that fall within its same niche. I do my quick and dirty GUI's in Jbuilder now. If I have to use a fully fledged language, I would rather use a portable one.

      --
      Bye!
  22. Not up to the developers... by throbbingbrain.com · · Score: 4, Insightful
    Dot Net doesn't look like a developer panacea just yet.

    It's not up to developers. Regardless of developer preferences or platform capabilities, when the right sales people talk to the right managers, the .NET decision rolls downhill.
    1. Re:Not up to the developers... by AstroDrabb · · Score: 4, Interesting

      This isn't always true. I am a developer for a fortune 500 company and we just finished a huge Java vs .Net comparison. The company brought in a lot of outside opinions and had us devlopers give opinions as well. Of course an MS rep was there telling the tall tales to all the PHB's of how .Net would make us 10x more productive and save us millions (just like the commercials), though the figures did not include all upgrade costs for Win2003 Server and WinXP cost. When it was all said and done, just about everyone picked Java, except for the MS rep and a few VB/ASP only type guys who don't have the technical ability to program much more then a few asp pages. It all came down to Java is proven to be stable and secure. MS and their technologies have not and especially .Net. We also have many mission critical apps that just cannot be trusted on an MS platform so they run mostly on Solaris and now some Linux boxen are popping up. Java gives us the ability to choose the right tool for the right job. .Net would have locked us in to just MS and severly limited choices. Once we as developers got that point across to the PHB's, they were able to see the light.

      --
      If Tyranny and Oppression come to this land,
      it will be in the guise of fighting a foreign enemy. -James Madison
  23. Interview with Anders Hejlsberg by hackrobat · · Score: 5, Interesting
    Earlier this week, artima.com published an interview with Anders Hejlsberg, lead architect of the C# programming language. Hejlsberg, interviewed by Bruce Eckel and Bill Venners, talks about the C# design process, the trouble with checked exceptions, and his idea of simplexity .

    C# is one programming language I've stayed away from--and for no particular reason. I had picked up the C# specification [PDF] in 2000, but never really got down to the canonical "hello world" program. Today in 2003, as I look back, I guess I haven't missed much.

    Let's go back to August 2000 and revisit Hejlsberg's famous O'Reilly interview by Josh Osborn.

    Why are there no enums in Java, for example? I mean, what's the rationale for cutting those?

    And Java has enums now, just like they come in C#.

    one of our key design goals was to make the C# language component-oriented

    I think this was really nice, and fitted in well with Microsoft's COM framework. I remember COM enthusiasts mentioning how every C# object would automatically be a COM object, thereby eliminating all that old school drudgery.

    C# is the first language to incorporate XML comment tags that can be used by the compiler to generate readable documentation directly from source code.

    Python and Java have docstrings (or javadoc) as part of the language.

    Developers are building software components these days. They're not building monolithic applications or monolithic class libraries.

    Developers are building all sorts of stuff, and not just "components". I think that statement is overrated.

    Boxing allows the value of any value type to be converted to an object, while unboxing allows the value of an object to be converted to a simple value type.

    Thanks, now Java has it too!

    Unsafe code allows you to write inline C code with pointers, to do unsafe casts, and to pin down memory so it won't accidentally be garbage-collected. [...] The real difference is that it's still running within the managed space. The methods you write still have descriptive tables that tell you which objects are live, so you don't have to go across a marshalling boundary whenever you go into this code. Otherwise, when you go out to undescriptive, unmanaged code (like through the Java Native Interface, for example), you have to set a watermark or erect a barrier on the stack.

    Honestly, I didn't understand the stuff about "unsafe code", the implementation of IL, and the implementation of generics. Just for comparison sake, Python also has a scheme for inlining C and C++ code.

    Let's face it, some people like to program in COBOL, some people like to program in Basic, some like C++, and some will like C#, I hope. But we're not trying to tell you to forget everything you ever did.

    I've raised this point to Java bigots on several occasions. It's just too difficult (and sometimes impossible) to interface Java with other languages. (In this context,

  24. Re:Shoehorn by Fnord · · Score: 5, Interesting

    I'll agree with client side stuff, but I've been in a situation in the past where we developed a server size web app (in J2EE) on a single nt4 server (purely for ease of access). Then when we went gold, capacity grew and it moved to a cluster of linux servers. Then when the business picked up and capacity grew in large amounts we moved to a couple Sun E6500s. .NET wouldn't have allowed us to migrate like this.

  25. Re:Mono? by DunbarTheInept · · Score: 4, Insightful

    ...those who are dealing with business realities and not philosophical preferences.

    I'm sick of that oft-repeated lie. BOTH the alleged "realists" and the "idealists" are actually realists. The difference is how far ahead they are looking. If you only care about the next year or so, you don't mind supporting only Microsoft. If you care about 10 years down the road, you do. BOTH camps are being realists, but they don't have the same goals in mind. One just wants to finish his current project, while the other will sacrifice current comfort to help ensure that there's still more than one computer company 10 years down the road.

    --

    Don't label something "offtopic" unless you know the topic well enough to tell what's on topic.

  26. Web Applications Suck by Greyfox · · Score: 4, Insightful
    There. I said it. Web applications suck. Having to kludge all your state tracking and code around toolkits to deal with all the quirky browsers that are available sucks. Having to use poorly written VB crapplets sucks. They're piling all this crap on top of a protocol that was never intended for applications to try to make it all work, and it all just sucks. It sucks in the Microsoft world and it sucks in the Sun/Java world.

    The question shouldn't be "Should I be develping this on .net or J2EE?" It should be "Should I be developing this on the web at all?"

    --

    I'm trying to teach myself to set people on fire with my mind... Is it hot in here?

  27. Re:Java's not exactly pining for the fields just n by AKAImBatman · · Score: 4, Insightful

    Except that assembly and C++ are not binary compatible across multiple embedded devices. Take cell phones for example Your choices are:

    1. Port and compile a version of your program for every cell phone in existence (quite a few platforms).

    2. Write a Java MIDP application that works on all MIDP enabled phones.

    Hmm.... which to choose, which to choose...

  28. Re:VS sucks by alext · · Score: 5, Insightful

    As someone has mysteriously marked the parent as "interesting" it might be worthwhile to provoke a genuinely interesting debate below it so that readers are not too disappointed.

    The parent insists that no Java IDE "can touch" VS for "any single thing you could possibly want to do", but a moment later admits that "VS.NET doesn't have as robust a feature set as some Java IDEs".

    Features like refactoring, perhaps, as found on the free Eclipse IDE, or the modestly priced IDEA?

    Or, looking a bit further afield, we could ask how one might develop a complete workflow system in VS, as you can in WebLogic Workshop?

    My clients do these things all the time, but VS has a long way to go to offer a competitive alternative to the Java tools available now.

  29. Re:VS sucks by dasmegabyte · · Score: 4, Insightful

    This is stupid. I make money writing software that is for sale. Openness does NOT sell software to our clients. Good software, and fair prices, sell software. Openness would actually be a major setback to writing good software.

    Why? Because we would need to massively increase our testing staff, to test on a good number of different machines to ensure compatibility. Because we would have to train them. Because even among VIRTUAL machines, and systems that obey standards or even run the same exact code, there are differences which can easily become dealbreakers.

    As an example: we designed our application from the ground up to allow the use of multiple database systems. Heavy abstraction, only SQL-97 compatible statements, no system specific datatypes, etc. We closely followed standards to ensure compatibility. Still, when it came time to test the first database, it didn't work. The compatibility layer was never fully implemented by the new server, as a result of a feud with the first server. We had to rework the database layer completely, and it set us back at least three months.

    If we had just said "fuck agility," and designed for one system (and rigidly sold THAT system) we would have saved a lot of time and money -- enough money to discount our software for those people who needed to invest in the more costly database. We could have spent that time making great new features. That's what matters to our clients, none of whom have ever not will ever use Linux or any machine not running an x86 chip. There's too much investment in legacy software requiring archaic things like DOS, floppy diskettes, and daisy wheel parellel port printers.

    Openness and portability are at best liberal afterthoughts, and are by no means "the most important things" outside of your junior year Operating Systems class. What matters is cost effectiveness. If your market is not already locked in to wintel, then by all means use Java, chances are you'll recoup the extra testing effort with your first big mainframe sale. Ours was so locked. Writing in Java would have been a foolish waste of effort.

    --
    Hey freaks: now you're ju
  30. The "Dotnet standard" bait-and-switch by alext · · Score: 4, Informative

    You've got your runtimes mixed up.

    The Dotnet runtime consists of approximately 1200 classes, including Windows Forms, ASP.NET etc.

    The CLR/CLI standard only covers core language-related classes - approx 120 in all.

    Dotnet is therefore mostly proprietary and there is no spec. to implement. Mono is having to reverse-engineer, with dubious consequences.

  31. Slow cumbersome process by blueforce · · Score: 4, Informative

    Java versus .NET is becoming a ubiquitous topic. It's been the subject of debate since .NET beta 1. Microsoft and Sun both have "independent" studies conducted to prove that their platform (J2EE/.NET) is better and both have convincing arguments. There is no perfect language or platform to solve every programming problem - sometimes it's C++, sometimes it's Python, sometimes it's something else - it really depends on the problem.


    It's no secret that one reason Microsoft created C# is to compete directly with Java. It's pure ignorance to say that C# is proprietary and that you're locked-in to Windows. C# and the CLI (.NET) is an approved ECMA standard. This is something SUN was unwilling to do with Java. For this reason, in a sense, Java remains far more proprietary than C#. It's too early in C#'s life to say that it won't be ported to other platforms - look at Mono. There is a lot of FUD being disseminated about "Microsof is going to sue Ximian, et al. for Mono" blah,blah,blah. That's not going to happen. Microsoft has already released the source code to the CLI with one intention of "People developing their own CLI implementations will find the Shared Source CLI an indispensable guide and adjunct to the ECMA standards.". So, for the argument that C# and the CLI are proprietary and one is bound to Windows is just plain ridiculous.

    Syntactically, C# and Java are extremely similar. They both derive from C++. Structurally, they are very similar as well. They are both OO languages, everything is a class, etc. Side-by-side they look very similar. There are numerous small details which make C# "friendlier" than Java, ie. C# has no requirement that the file be named after the class. However, C# has a lot of other advantages over Java. C# can make use of pointers. Java has no option on parameter passing - Objects are passed by reference, value types are passed by value. While C# has the same limit on objects, you are able to use pointers and it also supports boxing. C# supports operator overloading as well. On the merits of the languages alone, C# is stronger than Java. It should be expected since it was developed from scratch nearly 7 years after Java arrived.

    As far as performance, Java leaves a lot to be desired. I won't belabor this issue. If you'd like a demonstration of the difference between the run-time execution of .NET vs Java, pick your favorite VM and run Forte, then run Visual Studio .NET (it's written in C#) and decide for yourself. Java run-time performance alone is enough to dissuade some developers.

    Java does come as close to a RAD language as can be. Java applications can be developed quickly with far fewer bugs and errors as a comparable C/C++ application with the benefit of garbage collection as well. For this Java gets an "A". It greatly simplifies the process of rapidly developing database and other applications.

    Is Java going away? Hardly. But like it or not, C# and the CLI are here to stay as well. It's only a matter of time before the CLI is ported to other platforms and environments just like the JVM.



    --
    If you do what you always did, you get what you always got.
    1. Re:Slow cumbersome process by Cederic · · Score: 4, Insightful


      >> However, C# has a lot of other advantages over Java. C# can make use of pointers. Java has no option on parameter passing - Objects are passed by reference, value types are passed by value. While C# has the same limit on objects, you are able to use pointers and it also supports boxing. C# supports operator overloading as well

      You mention three advantages there:
      - pointer support
      - boxing
      - operator overloading

      I'm sorry, but in the average commercial environment, churning out business logic to meet changing business requirements under tight deadlines, two of those three are very very bad.

      Boxing is good. That's probably why it's in Java 1.5. I'd have liked to see it in 1.1, but that's another discussion.

      Pointer handling: I've written code doing direct memory access via pointers. I've also written code in Java (and thus not had access to pointers). The Java code has been at least as easy to write, had far fewer bugs (invalid pointers? memory leaks? not in my code), and (most importantly) been immeasurably easier to maintain. You might have been programming for 20 years and never have a problem with pointers; most developers have been programming for 2-3 years, don't have a sodding clue about pointers, and will and do screw it up. Quite frankly, pointers are evil and unnecessary and if I do use C# in the future (as is likely) I'll be insisting on coding guidelines that preclude their use.

      As for operator overloading: It's one of those things that makes C++ code so bloody impossible to maintain. Bit of code read x += y. Except it's doing a binary concatenation, or advancing the pointer reference, or updating Z instead. Because some idiot has overridden +=.

      I appreciate that there are situations where operator overloading is useful, even some where it's sensible. Unfortunately, going back to the average developer: They don't know when to use these things, and even if they do, they often don't know how.

      I love Java not because I'm a crap programmer (although I wont deny that) but because it makes my life much much easier. I can write code quicker, more efficiently, and more robustly. I can maintain code extremely easily, as the 'gotchas' that exist in many languages just aren't there in Java. And my boss loves the fact that he's getting new functionality so much quicker, because the whole team isn't spending their lives debugging a complex overloaded operator that's invalidated a pointer.

      I'm not saying C# is a bad language. I am saying that operator overloading and direct memory access (through pointers) is unnecessary and evil in the average corporate development environment. And that's the target environment for .Net.

      ~Cederic

  32. Java vs. .NET by dist_morph · · Score: 5, Informative
    I would like to point out that there are now several solutions that allow the integration of Java into .NET, so it does not have to be an either/or decision. I have run into many shops that love using Java on the server side and also love using truly native GUIs on the Windows desktops. Using the right tools, you can easily do that.

    My favorite tool for the integration is JuggerNET, which transparently starts up a JVM in the CLR process and the developer simply codes against generated .NET classes. I am affiliated with Codemesh, so I'm somewhat biased (take a look at Stu Halloway's great website for alternatives) but working with both platforms for a living, I just can't get excited about controversial this or that is dying statements. Both platforms have their strong and their weak points.

    I love the platform portability of Java, but I think Java is too closed in terns of language integration. Doing JNI by hand is an abomination, and most people at Sun admit it.

    I love the language portability of .NET (it's not perfect, but then, neither is Java's platform portability) but I hate the exception model.

    So, there you have it. Neither will kill each other, they will just coexist uncomfortably until they both get replaced with something new.

  33. Re:Shoehorn by DunbarTheInept · · Score: 4, Insightful


    And if for some reason we want a different platform (which we don't and won't), we'll have to recompile. Oh, the horror.

    And that's why we have so many .Net applications for Unix and Mac....Oh, wait.
    "just recompile" is a great solution IF you didn't use a development model that locks you in. I use "just recompile" all the time on C and C++ programs.

    --

    Don't label something "offtopic" unless you know the topic well enough to tell what's on topic.

  34. Re:VS sucks by dasmegabyte · · Score: 4, Informative

    Um, define bloated.

    The .NET 2003 IDE takes up 17 meg of disc space. With 20 projects open, and debugging it's eating 80 meg of memory. It uses 0 processor time in idle mode, less than 1% when typing, less than 20% when searching with regular expressions. It doesn't peg the CPU when compiling. Starting it up, and reading all of my files, takes 20 seconds. Starting a brand new project takes 3 or 4.

    On this same machine, NetBeans takes over 70 meg of space, 180 meg of memory for only 10 classes, pegs the cpu if you stare at it hard enough, and it just slow as hell. Starting it can take close to a minute.

    Please don't compare Studio 6, a piece of crap, and VB3, which is so old that it shits doilies, with a modern on-demand IDE liek Studio.NET. When I did Java, I used to use textpad for the bredth of my typing and editing because the IDE was so slow. Now I do it all in Studio. It's just better.

    --
    Hey freaks: now you're ju
  35. Re:Java's not exactly pining for the fields just n by aagha · · Score: 5, Informative

    #1) Java was NOT originally developed for embedded systems.

    I think you might be mistaken here.

    Before the language was called 'Java', it was called 'Oak'. It was a language for building embedded applications on smart consumer electronics. However, Oak was way ahead of its time in terms of product targeting.

  36. The Other Variable: Linux by Enthrash · · Score: 4, Informative

    I fear nobody has mentioned the simple yet profound fact that will drive many towards .NET & Java/J2EE. It's Linux! It's free, it's stable, it's secure (relative to MS OS's). Put it together with Apache Open Source products such as Tomcat & Apache httpd, or JBoss if you are into EJBs and you can't go wrong.

    I feel that the technical debate between .NET and Java/J2EE more irrelevant than most will admit. They are both very well designed development languages, and can accomplish most projects in a similar amount of time, with similar numbers of developers.

    Just one problem, most businesses wish to make $$$, and if you haven't noticed the tech sector barely able to keep it's head above water right now. Thus, all things equal I'd bet most businesses will probably opt for a Java (or J2EE)/Linux solution as the overall price can't be beat, and you don't have to waste you development time creating valueless libraries that others must have had to create already. Not to say .NET add-in dev libraries aren't available, they just aren't provided in an FREE manner as frequently as they are in the Java world.

    Anyhow, my 2 cents.

  37. Re:VS sucks by mrtrumbe · · Score: 5, Insightful
    How in the blue heck do regions make refactoring unnecessary? Do you know what refactoring is??

    Let's say I have a class in package A and I want to move it to package B (in dotNet parlance, packages are namespaces). In dotNet, I'd have to personally touch every piece of code accessing that class and redo the import statements (dotNet: using statements) to reflect the change. Same goes for method name changes, public member changes, method signatures (parameter order, adding parameters, etc.), etc.

    Also, the good refactoring IDEs provide a lot of extras like generation of getters/setters (dotNet: properties) (also referred to as encapsulation), extracting interfaces and/or superclasses, replace inheritance with delegation, replace constructor with factory method, make method static, etc., etc., etc.

    Note that most of the above refactorings not only change the class in question, but also all accessing classes and methods. This sometimes means you can make a significant change to a heavily used method or class and do NO WORK to the rest of you classes.

    If you are interested in the power of IDE refactoring, check out the IDEA refactoring page. Here is a screenshot of the refactoring menu.

    In short, refactoring is REALLY powerful and very, very useful. If you are saying otherwise, you probably haven't used it. Also, it should be noted that several companies are making refactoring plug-ins for Visual Studio. Obviously SOME people don't think that Visual Studio's features render refactoring "unnecessary" or a "waste of time." Myself included. (I'm a Java junky programming in a dotNet environment.)

    Taft

  38. Re:VS sucks by alext · · Score: 4, Insightful

    Hmmm... a few pages above there's a post consisting of the two phrases "You are an idiot" and "There is no IDE that comes even close to Visual Studio.NET" that's now Insightful.

    And now here I'm obliged to repeat someone's useful response (that wasn't modded up) to an ignorant assertion (that was).

    The practice of refactoring is well-established and reflects changes to the naming or structuring of the code that have occurred since it was created, so your comments about the initial organization of code are irrelevant. Apparently your beloved VS.Net is likely to offer some refactoring capability in a future release, which acknowleges the importance of this feature but puts it approximately 2.5 years behind Eclipse and IDEA.

    A workflow system consists of process definitions with process steps that involve conventional programming, therefore if I'm developing a workflow system, I'm also doing conventional programming. An IDE allows me to deal with these aspects in one environment (hence "Integrated"), just as VS.NET allows me to develop GUI layouts and conventional programming in one environment. (Or are you suggesting that the GUI designer in VS should be a separate system?)

    I fail to see the relevance of standalone diagramming tools in this context since their purpose is to produce diagrams (for people) rather than code (for computers) - something you are free to do regardless of your IDE. However, since you bring up the subject, I should point out that in Workshop the workflow diagrams ARE integrated and correspond exactly (via 2-way update) with the visible program code. Again, such features are light-years ahead of anything in VS.

  39. Re:VS sucks by CommandNotFound · · Score: 4, Insightful

    I'm confused. You first deride my comment, and then you appear to agree with it.

    My point is that by only looking at a language's version-1.0-time-to-market qualities, tradeoffs must be made. In the case of VB, the tradeoff is that VB is a closely guarded language by a single vendor, rather than the classical academically defined languages like C, C++, Fortran, etc. If Visual C++ goes away, there are other vendors who produce C++ compilers. If Microsoft stops producing VB compilers, there is no one to turn to. Since VB.Net is the next version of VB, and it requires a practical rewrite for large applications, then the previous language known as VB is dead, for all practical purposes. Few to no new applications will be written with the old language.

    I don't care how bad your applications are written, odds are your mananagement would not rewrite the applications unless they were forced to by outside forces, because, as you said, the paying customers don't care about languages, they just want feature Y in product Z and they want it now. In this case, the outside force is the vendor who has essentially stopped advancing the compiler for the langauge your apps are written with, and you don't have another VB vendor to turn to.

    And as far as developers enjoying the rewrite; beware of what you wish for. We are going through the same thing, and it has been almost two years of pain, beauracracy, and political wrangling. The Second System effect can easily take hold, since people are so afraid of making the mistakes of the old system that they overthink and over-engineer the new system until it collapses under its own weight.