Visualizing the .NET Framework
eldavojohn writes "If you're a Web developer, you should check out a quick post about the number of types, methods, & fields in the .NET framework. This was done using NDepend. The numbers are quite large — e.g. 39,509 types. The blogger went on to generate tree maps and a dependency matrix."
[b.belong('us') for b in bases if b.owner() == 'you']
.NET and Java are both prime examples of object-oriented programming gone stupid. Their class libraries have become so utterly huge that it becomes damn near impossible for an individual developer to suitably grasp anything more than a small portion of them.
.NET or Java. It's easy to get lost in whether we need a FileInputStream, or whether we should wrap a FileInputReader in a TextInputBuffer, and so forth. Give me fopen() any day.
.NET standard class libraries. Meanwhile, the POSIX API offers just as much flexibility, but is far easier to work with. Not to mention that programs using it are far more efficient.
Although they supposedly give more flexibility, something as essential as reading from and writing to a file becomes a hassle with
OO was supposed to solve the problems of writing applications in languages like C, Pascal and Fortran. All it has done is brought in a new level of complexity that results in monstrosities like the Java and
.NET really is an amazing framework on which to build software. It just needs more OS support and I would use it for programming other than what I do for a living. All those types are there, but they will not be loaded in to memory unless your software needs them.
That's what I first thought of for visualizing .NET.
The goggles, etc.
Hail Eris, full of mischief...
E pluribus sanguinem
It doesn't suck because it's made by MS or ripped off from something. It sucks because the documentation is piss-poor. And there isn't a single working (i.e. cut-and-paste) example for a single API (someone told me they break them on purpose so that newbies don't cut-paste themselves into security holes without understanding exactly how the thing works, but hell!)
I noticed the same thing when Apple released their Cocoa framework (with over half of help pages saying "TODO: descrition, example"). Some Quicktime documentation is still that way today!
How anyone expects the undocumented API stuff to be useful is beyond me.
Obama likes poor people so much, he wants to make more of them.
Before you impugn Microsoft with your short-sided emotional appeals against the sheer number of classes, use a hint of logic and realize that since MS copied Java shamelessly and ruthlessly (improving on some debacles in the Java classes, such as the crap IO classes that had to be redone from scratch), you'd be blasting Java, KDE, Python, and most any other class library as well.
.NET class library beats them all easily. It is obvious that the designers did their homework and stole from each library what worked well, while dropping what didn't. If they were smart they'd take Java's excellent concurrency constructs such as the BlockingQueue and put them in (they may already have, I don't program much in .NET lately). Most of my beefs with the class library are the fact that it is huge (footprint size), and I don't agree with some of the modeling. But that is minor.
Look, in a class library that purports to help most everyone, there's going to be an awful lot of code. Class library implies that classes are used to organize the abstractions provided by the library. Proper OO design favors designing more types with smaller number of features rather than God-objects that do many things. Fine-grained objects are simpler to unit test and are much easier to reuse. The downside is the propagation of types and the verbosity level of the code generally goes up. But that is a fair trade-off in my opinion, since the most important work on the code happens in the maintenance phase, when someone else can come along and at least get a vague idea of what is going on.
I've used the class libraries in Java, KDE, MFC, and Python, and the
There's a reason Miguel wanted to make this happen on Linux. It is close to making programming fun again, instead of squinting at hyper-abbreviated function names like sprintf and mucking around with idiotic string representations such as C's.
Hallelujah, brother!
What bugs the snot out of me is that a lot of that stuff is documented really well, but only on developers' blogs. What the hell kind of insulting documentation non-strategy is that? And of course, there's no cross-referencing between msdn and "the blogosphere." So you get to churn away at a search engine until you find a blog entry that's kind of addressing what you want to know.
That said, I do like a lot of stuff about C#. Delegates, for example rank high on that list. And C# 3.5 offers some pretty cool new stuff as well. I likey the lambda expressions, inferred typing, and LINQ.
But the documentation does make me cry at night, sometimes. Sometimes.
If you're a Web developer, you should ignore .NET and use something much less bloated.
There, fixed that for you.
It's better to vote for what you want and not get it than to vote for what you don't want and get it.
- E. Debs
The comparison to the human genome is interesting. The genome contains about 3 billion base pairs and 30,000 coding genes. As best I can see, .NET is quite a bit bigger: The closest thing to a gene is a method (an object that can be used, or not used, and which does something). The genome has 30,000 and .NET has 384,000. So even if it takes 10 methods to do what one gene does, they are equivalent.
.NET has 8,000,000 instructions. Given the roughness of the comparison, this is pretty close.
.NET :))
It takes 3 base pairs to code for a single protein, perhaps the closest we can come to an instruction. Each gene has an average of 3,000 base pairs, equivalent to 1,000 instructions. So we are looking at 30,000 genes x 1,000 instructions/gene or about 30,000,000 instructions in the genome.
The point here is that we are creating programs that are roughly equal in complexity to the human genome. If we were better programers, then perhaps we'd have come up with intelligent design.
Finally, it's worth noting that the functions are unknown for over 50% of discovered genes. It may be about the same for
The biggest plus to working in Java is that the documentation Sun provide is comprehensive (and once you figure your way around it) easy to access.
Microsoft is getting better but, for a framework that's quite clearly a java rip-off, they could have ripped its documentation style too.
I don't know which is worse - the thought that you're making this comment without having read any of the extensive, working examples on the msdn site; or that you did read them and somehow still feel this way. .Net has plenty of flaws, but lack of documentation ain't one of 'em.
Let me get this straight.
.NET lacks "internal logic" and "simplicity" after pointing to the article. Never mind that the article merely only reported statistics about the .NET framework instead of asserting that it, does, in fact, support your arguments. So this claim remains baseless, unless you're trying to say lots of types somehow means it lacks internal logic and simplicity. We are waiting for your keen insight on this point.
.NET that runs on non-MS platforms and is compatible at the bytecode level. What sort of examination have you done on the source code of it to determine that it has "simplicity" and "internal logic?" How does it meet those goals, yet have the same external API of .NET? How does it not suffer from "bloatedness" if it has at least as many publically available classes as .NET?
1. You argue that
2. Another user questions your assumption rather innocently.
3. You imply that they did not read the article (which is rather hilarious considering the previous point) and then, to add the icing to the cake, indicate you'd much rather work on Mono. Mono is a version of
We await your answers, mighty Naughty Bob.
This reminds me of an old joke:
Q: A Marketing executive and an RIAA lawyer jump off the top of a 50 story building. Who hits the ground first?
A: Who the hell cares?
laura, not a fan of .NET
Did you bother clicking the link to "Mono?" It links to this URL:
http://en.wikipedia.org/wiki/Infectious_mononucleosis
Wonder what the public key field is for?
I have mod points, but this deserves about 10 of them so I reply in solidarity. .net programming work. It's ironic that their worst enemy is essential to working with their system.
The msdn docs are not enough, there are too many useless empty API pages. If it weren't for Google I couldn't do any
Often the most useful documentation and samples are scattered over a zillion forums (all requiring logins!), newsgroups, blogs, 3rd party books, etc.
This has always been the case with microsoft development libraries, but it's getting worse because early on (internet time) it was mostly just usenet.
I hate to say it, but whether "Naughty Bob" is normally a troll or not, I suspect he is correct.
MS has yet to show the type of design innovation that foregoes bloated code. Instead, when something doesnt work, or wasnt planned out correctly, they just add a bunch more stuff, then a bunch more, then a bunch more... then pat themselves on the back for the "innovation" which they equate with the number of things added.
Writing an extensible framework - and then extensions (or example extensions) would have been smarter, smaller, faster, and easier for true developers to implement.
The "Everything - including the kitchen sink" attitude does not work well in the computer world - the fact that their programs and apps are getting far more bloated, barely gain additional functionality (regardless of their claims) and getting far more resource hungry (while not adding significant functionality) is a perfect example - and one I think they are following with .Net
To me, it looks more like they are trying to prove that they can compete with, and surpass, all their .Net competition by sheer number of "features"/"capabilities" - which does not make it better. Their .Net framework already scaled horrendously to many types of implementations (like the Service/Customer tracking unit CompUSA used to use - as any of you who worked in Tech or Business Sales can attest to - from fond memories of running a rather simple report, going out for coffee and a quick breakfast, coming back, and still having 10 minutes to wait (of a total 30-40 minutes) - nor were the data sets that big, or the front end complex).
I'm far happier with using ________________ (pick almost anything else used in the non-Windows world), and far happier extending base classes and functions, over using pre-written bloatware versions.
But then again, besides the competition aspect, I think they are also trying to woo companies that can hire even less expensive "developers" since sooooooooooo many more things have been added making development a matter of point and click (and requiring even less actual development skills)... it seems more like a two prong attack against their competition.
Great, that's fine... nothing wrong with that - if it's not at the sacrifice of security, performance, and interoperability. But of course, it does sacrifice all of those... and really doesnt seem to do much at all.
So many of the new methods and classes are all stuff that the originals should have allowed the extensibility for to begin with. And so many should be variants on the same method (SOM anyone? Compare the SOM/DSOM design to just the first few lines listed in the article).
...so tell me again, how is "Naughty Bob's" post flamebait? No one who has responded to him has yet said why.
Feel free to mod this anything you want... doing so wont change reality.
StarTrekPhase2 - The Five Year Mission Continues!
I realize that you're one of those "Anything but Microsoft at any cost" people, but I have some news for you.
.NET isn't really any worse than when I was dealing with it in C, C++, or any other language that I've used.
1) You don't have to memorize what is in every namespace in *any* language. You just have to have a good enough overview of them to know where to look effectively for something you need. Spending all of your time trying to memorize everything in libraries is a waste of time and usually only done by undergads who think that they know it all.
2) These are just toys to keep you occupied
I hate to break it to you, but there is a great deal of business that is done on Microsoft software. There are a number of reasons for that (admittedly, not all of them are good reasons). One of them is that MS has done something Linux and the others haven't - they make software that makes it fairly simple for most businesses and people to do 80% of what they need to easily. In addition, needs which are not met by MS itself, and a number of needs which are, are covered by various 3rd parties.
As for "toys to keep you occupied", I'm one heck of a lot more productive using C# in Visual Studio for most of the things that I have to do than I was using C or C++ in xemacs. C and C++ are fine tools for doing things closer to the metal. Most applications don't need that.
In addition, dealing with deprecation in
You need to learn to use the right tools for the job. Instead, you want to bash tools on an idealogical basis. It's a sign that you really need to grow up.
Everything I need to know I learned by killing smart people and eating their brains.
FWIW, he does have something of a point. Microsoft cycles its platforms at an incredible rate that just is not natural for the industry. As soon as one gets used to the existing API, Microsoft deprecates it and creates a new one. What's the advantage of the new one over the old one? In many cases, no one knows.
.NET 1.x incompatible with 2.0? No idea. All I know is that Microsoft does these things. Evidence suggests that Microsoft does it intentionally to lock out competitors. (source: Barbarians Led by Bill Gates) If that's true, then it certainly doesn't cast Microsoft in a good light.
.NET is NOT their primary goal.)
Why did Microsoft rearrange the VBA API from Access 97 to Access 2000? Heck if I know. Why did Microsoft make IIS extensions written in
That being said, you are also correct in saying that C# is a superior desktop development platform. If you're developing for Windows, I don't see any real reason not to use it. It's a fairly decent platform with tons of modern features. The only time it's really inappropriate is when your program needs to be cross platform. In which case Java might be the best choice despite the inherent difficulty in developing a good GUI in Swing. (Or SWT if you prefer. Don't even think about using Mono. Trust me, it's bad juju. Even the Mono devs will tell you that compatibility with
Javascript + Nintendo DSi = DSiCade
The most common .Net developer mistake now is that people don't bother finding the function they need -- instead they just reinvent it and waste everyone's time when maintaining that code later. The problem with 30,000+ items is that there's no good way to teach people where to look for something that's already in there. If it were organized in such a way that one could easily not reinvent the wheel, then it would be an awesome language. Without that, though, it becomes yet another way for people to create crappy date parsers.
stuff |