Patrick Smacchia [MVP C#]

Sponsors

The Lounge

Advertisement

Images in this post missing? We recently lost them in a site migration. We're working to restore these as you read this. Should you need an image in an emergency, please contact us at imagehelp@codebetter.com
Number of Types in the .NET Framework

Brad Abrams just did a post on the Number of Types in the .NET Framework.

Here are the results I obtained with NDepend (slightly higher):

 

#assemblies:  119

#namespaces:  933 (here there are some duplication across assemblies, i.e the namespace System for example will be counted as 21  because it is defined in 21 assemblies)

#types:  39 509

#methods:  384 300

#fields:  240 070

#IL instructions:  8 562 828  (equivalent to around 1.7M lines of C# or VB.NET code, it took 6mn to analyze on a quad 64 bits 4GB machine)

SELECT METHODS WHERE NbILInstructions > 0:   341 842

SELECT TYPES WHERE IsPublic16 463

SELECT TYPES WHERE IsClass29 345

SELECT TYPES WHERE IsClass AND IsPublic12 324

SELECT TYPES WHERE IsStructure:   2 794

SELECT TYPES WHERE IsStructure AND IsPublic511

SELECT TYPES WHERE IsEnumeration4 506

SELECT TYPES WHERE IsEnumeration AND IsPublic1 838

SELECT TYPES WHERE IsDelegate1 312

SELECT TYPES WHERE IsDelegate AND IsPublic690

SELECT TYPES WHERE IsInterface2 864

SELECT TYPES WHERE IsInterface AND IsPublic1 790

 

SELECT TYPES WHERE IsClass AND IsAbstract1 813

 

SELECT TYPES WHERE IsClass AND IsAbstract AND IsPublic1 008

SELECT TYPES WHERE DeriveFrom "System.Exception"633  (DeriveFrom means derives directly and indirectly)

 

 

SELECT TYPES WHERE DeriveFrom "System.Attribute"728

SELECT METHODS WHERE IsPublic212 234

SELECT METHODS WHERE IsPublic AND IsStatic29 664

 

 

SELECT FIELDS WHERE !IsStatic103 349

 

SELECT FIELDS WHERE IsStatic AND !IsEnumValue AND !IsLiteral AND !IsGeneratedByCompiler 22 783

 


Here is a treemap view of the entire .NET framework, the size of the rectangle being proportional to the number of ILinstruction:

 

 

Here is a dependency matrix between the 119 assemblies of the .NET framework (click on it to get a bigger view). A blue cell means a dependency from the assembly in x-coordinate/absissa to the assembly in y-coordinate/ordinate.A red square means that there are some cycling dependencies between assemblies. The last row being full blue represent the fact that mscorlib is used by all other assemblies. In the same spirit, low-level assemblies are down in the matrix and are represented with a lots of blue cells (because they are heavily used). High level assemblies are upper in the matrix.

On the big matrix, the green square are symmetrical to blue square, in other words a IsUsing relation has a symmetrical IsUsedBy relation.

The weight printed on the blue cells is the number of members of the assembly used that are used by the assembly user.

The weight printed on the green cells is the number of members of the assembly user that are using something of the assembly used.

 

 


Posted 03-18-2008 2:29 PM by Patrick Smacchia

[Advertisement]

Comments

what? wrote re: Number of Types in the .NET Framework
on 03-18-2008 11:10 AM

pretty graphs... what do they mean?

Mark wrote re: Number of Types in the .NET Framework
on 03-18-2008 1:34 PM

That Silverlight and Mono are unlikely to catch on outside Windows.

Q wrote re: Number of Types in the .NET Framework
on 03-18-2008 1:40 PM

What is .Net? It is used in a real project?

Xigam wrote re: Number of Types in the .NET Framework
on 03-18-2008 3:04 PM

Mono is outside windows since it is an open source version of .NET for Linux. So it's practically 100% outside windows.

There is a version of Silverlight for Linux called Moonlight.. I'm unsure if Silverlight/Moonlight will catch on though.. we will see.

Krzysztof Cwalina wrote re: Number of Types in the .NET Framework
on 03-18-2008 3:39 PM

Patrick, are you including internal types or only public ones?

purrl.net |** urls that purr **| wrote This is one of the web's most interesting stories on Tue 18th Mar 2008
on 03-18-2008 4:04 PM

These are the web's most talked about URLs on Tue 18th Mar 2008. The current winner is ..

DirtyBirdNJ wrote re: Number of Types in the .NET Framework
on 03-18-2008 4:32 PM

What does this all mean? That the .NET framework is a giant bloated piece of crap... heck I knew that before I read this article. Pat put some pretty graphs that visually show you how much of a slow pig it all really is.

I'll take Adobe AIR/Flex over M$ .NET crap any day.

miles thompson wrote re: Number of Types in the .NET Framework
on 03-18-2008 5:05 PM

lots of ignorant comments in the above...

the dependency matrix above is actually really pretty impressive - the relatively small number of 'dark' squares (compared to many projects) and their tendency to cluster together indicates that the .net framework creators have been quite discipined in their creation and come up with quite an elegant design..

TheHinokiMan wrote re: Number of Types in the .NET Framework
on 03-18-2008 5:11 PM

@DirtyBirdNJ

Bloated??  I think a better term might be 'complete'.  You don't actually think that all of the APIs get compiled into each .Net app, do you?  .Net apps tend to be quite small in size.  Please don't criticize what you don't understand.

Oh, and go clean your cage.

Patrick Smacchia wrote re: Number of Types in the .NET Framework
on 03-18-2008 5:41 PM

> Patrick, are you including internal types or only public ones?

Krzysztof, I included all types, internal, nested and public.

Curtis, I have been forced to delete your comment. Feel free to repost it with normal vocabulary without being vulgare. And I don't see what Adobe AIR/Flex has to do in here? really?

Haha wrote re: Number of Types in the .NET Framework
on 03-18-2008 5:41 PM

What TheHinokMan said.

Do your homework.

manas mittal wrote re: Number of Types in the .NET Framework
on 03-18-2008 9:15 PM

hello. thanks for this useful visualization. now i realy can start "programming better", as you put it!

TimeBandit wrote re: Number of Types in the .NET Framework
on 03-18-2008 9:19 PM

"Net apps tend to be quite small in size"

Yes, if you put aside the fact that everyone of them require the right version of the .NET runtime environment. That is far from being small

TheHinokiMan wrote re: Number of Types in the .NET Framework
on 03-18-2008 9:54 PM

@TimeBandit

Not at all true.  .Net runtime updates are part of the normal Microsoft Updates, and they're not very large.  Please educate yourself before making public statements like this.  Pat's post just made it to the top of ./, so let's all be wary of the anti-MS trolls who are about to post religious commentary...  :-)

Vic wrote re: Number of Types in the .NET Framework
on 03-18-2008 10:02 PM

.NET Apps really are pretty small.  The framework pretty much comes shipped with the OS now.  I do develop in a corporate environment (which can be quite forgiving, of course) but seriously, when's the last time one had to ship a copy of the framework / runtime to get things to work?  It's pretty much a given now.

Microsoft .NET by the numbers : techamber wrote Microsoft .NET by the numbers : techamber
on 03-18-2008 10:19 PM

Pingback from  Microsoft .NET by the numbers : techamber

Older!=Wiser wrote re: Number of Types in the .NET Framework
on 03-18-2008 10:40 PM

@TheHinokiMan --

Yep, I just came over from Slashdot (I think that's what you referred to with "./"). I have what you may consider the unusual ability to admiire the .NET Framework for what it is while at the same time vehemently opposing the perverse and anti-competitive practices of the vendor that sells it. What sort of religious commentary does that make?

vonyc wrote re: Number of Types in the .NET Framework
on 03-18-2008 10:52 PM

Well the framework really is not that big, however installing it can take some time. The ubiquity of the framework is a different issue. Having developed cots solutions using .net, I will say that every application that requires .Net must include the runtime installation as part of the application or otherwise ensure it's there. Ubiquity has not really been achieved. To me .Net is the only viable option for general development of Windows software. MFC/ATL/WTL is a nightmare. Handle Unicode in windows c++ applications and just generally dealing with the C API windows provides is like walking on needles, just painful. So if I have an application where the primary demographic is Windows based users I use .Net. WIth the invention of mono, I ensure that my .Net code is platform independent enough to run on mono.

As far as the vast size of .net goes, this is not surprising and definitely leans towards complete. Complete may be a good or bad thing. Perl/PHP/Python/Java are not really complete. For instance I don't think Perl or PHP can parse an XML document out of the box. But thats because of a different approach. PHP has PEAR, Perl has CPAN and I guess I would say that Java has apache(xerces, xalan, tomcat, jakarta) at this point. But which one is better is hard to say. Every time I have to put together a cots application with usability requirements stating the install must be easy, it's a complete pain unless your using something native.

--

Damien Hogan

Sarphati wrote re: Number of Types in the .NET Framework
on 03-18-2008 11:18 PM

I can understand the confusion. I dislike Microsoft and their anti-competitive practices. I prefer open source. But, I am a .Net developer and I actually do like C#.

Does this make me confused?

On the framework comments... It is true that you must have the correct version of the framework installed. I don't think the frame work is that small either. However, have you every seen a Windows production server that did not have the the first 2 frameworks installed? It is standard practice when setting up a server. It becomes a non issue. It only becomes annoying when you want to run something locally on your computer.

J. Watrous wrote re: Number of Types in the .NET Framework
on 03-19-2008 12:00 AM

C# was really a Java implementation created by Fisher Price and sold to MSFT.

MSFT has a sure win with all the future toddlers cutting the teeth on C#; continuing vendor lock in vis a vie spoon feeding it's handy capable 'code assemblers' the sweetest no thought required developer tools.

Soon coding will be like assembling a burger at McDonald's - high school students will get an IDE that resembles that cash register with press the picture for the right function/Lib code combo  meal.

Not in the empty calories fast food crowd you probably got a degree in MIS.

Well I imagine  that coding C# for you is like having a degree in Architecture but with a preferred medium  of  bunch of lego blocks with preassembled buttresses  etc.

The thrill being Cloning other famous landmark designs but building them in lego.

You may say robust and mature with it's 384,300 blocks to play with, but I say dangerously simple.

Jon Limjap wrote re: Number of Types in the .NET Framework
on 03-19-2008 12:48 AM

Why is it that whenever someone writes about .NET's characteristics, some FOSS/LAMP/Java/Ruby/Perl/Python zealot comes in to start a pissing contest?

Derreck wrote re: Number of Types in the .NET Framework
on 03-19-2008 1:01 AM

They're jealous, that's why.

.Net is huge and sometimes seemingly unwieldly but it has done a good job encapsulating everything you need to write anything in a concise manner.  I give them props for that and that alone.

Richard wrote re: Number of Types in the .NET Framework
on 03-19-2008 1:04 AM

J. Watrous "C# was really a Java implementation created by Fisher Price and sold to MSFT"

Wow, have to say that this is the most brain dead, dumbass comment I've ever read.  Anders is a brillant language designer and if you EVER even studied language design in the slightest you'd have a basic clue as to why you are an idiot.

Here's your challenge; do something better or STFU!

dot net types » article » Thats The New Thing! wrote dot net types » article » Thats The New Thing!
on 03-19-2008 1:07 AM

Pingback from  dot net types » article » Thats The New Thing!

Espresso Fueled Agile Development wrote The .NET Framework is a bit on the big side.
on 03-19-2008 1:09 AM

As anyone who has ever tried to find docs on MSDN already knows, the .NET Framework is big. Real big.

turbo pascal rocked my world wrote re: Number of Types in the .NET Framework
on 03-19-2008 1:43 AM

Richard, you're absolutely right on J. Watrous...

Easy to talk a big game and spew typical anti-MS rhetoric.  Much harder to actually have the chops to do it.  

Is .NET big? Debatable.

Is .NET complete? Pretty much.

Do these graphs show that the framework designers are capable of taking a complex problem and designing it as elegantly as possible?  Without a doubt.

Let the trolls spew forth their nonsense.

They're still just trolls.

mike wrote re: Number of Types in the .NET Framework
on 03-19-2008 3:31 AM

.net quite simply, rocks!  I'll never go back to PHP.

MSDN Blog Postings » The .NET Framework is a bit on the big side. wrote MSDN Blog Postings » The .NET Framework is a bit on the big side.
on 03-19-2008 3:36 AM

Pingback from  MSDN Blog Postings  » The .NET Framework is a bit on the big side.

janus wrote re: Number of Types in the .NET Framework
on 03-19-2008 3:45 AM

Oh, I will still be using PHP. It has it's uses and I also still use it for commercial applications. Having said that I really like C# and .NET (having run Linux for 10 years on the Desktop).

James W wrote re: Number of Types in the .NET Framework
on 03-19-2008 3:51 AM

@J Watrous: Wow, Fisher Price is pretty good at language and framework design. Given at release C# fixed a lot of annoying issues with Java which the JCP took too long to resolve, and is now firmly ahead of the curve in terms of innovation. Framework performance also gives Java a run for its money.

Stilgar wrote re: Number of Types in the .NET Framework
on 03-19-2008 4:14 AM

Can someone explain what we are seeing in the graphs? I think I lack the knowledge to understand them.

BTW "programming in .NET is too easy and everyone can do it" is really stupid argument when you are trying to insult the technology. It actually shows how good it is. What is more it is not entirely true.

Michiel U wrote re: Number of Types in the .NET Framework
on 03-19-2008 4:40 AM

.Net beats Java in terms of speed and usability, that's for sure.

But really, the way the .Net environment is set up makes it a enormously uncontrollable mess. Basically, if you want to work with .Net, you have to do it the MS-way (using the .Net interface, even if it does not match your requirements) or you had better leave it.

Finding out the underlying structures that you need to override if you want to adjust behaviour is way too complex. Documentation at MSDN is available, but for three or four different versions of .Net that either not implement the same API or implement it differently. Developing for .Net is developing for a moving target: not pretty.

I pitted .Net, perl and PHP against each other in a web-development situation. It turns out PHP on Linux consistently performs better except where a compiler can excel in optimizing loops and such. Even on Windows, PHP performs almost as good as .Net and as far as I know, PHP performance has increased in IIS7.

.Net eats too much memory, takes too much resources to 'manage its code' and suffers from overly complex interfaces.

The only situation where I would recommend .Net, is if you were bound to a Windows platform running IIS and you had to develop a common code-base for several web-projects that also had to interface with specific features of the Windows platform system management. In all other cases: use a weakly-typed, interpreted platform for webdevelopment.

For non-webdevelopment, why take .Net? Take C++. MS has one of the best, if not the best, C++ compilers of the world and as you are tied into the Windows platform anyway, your binary environment is set already. The MS development environment is roughly the same. Plus C++ supports multiple inheritance. And it avoids the horribly complex GAC setup and stuff.

Java Zealot wrote re: Number of Types in the .NET Framework
on 03-19-2008 5:28 AM

Here is a message from Java zealot ;) : with all their merits and deficiencies Java and .Net are the 2

platforms to dominate the next 10 years of general purpose software development. C# is in may ways

better than Java the language - partly because it had the opportunity to learn from Java mistakes. .Net

is comparable to Java the platform. Not yet as mature but going there. .Net however has bleak prospects

on the server side because of its dependence on Windows. I would just NEVER venture to run a farm

of Windows servers. Even Linux is MUCH better than that and commercial UNIX-es are light years

ahead in stability, reliability, scalability, security, manageability. Desktop and server are inevitably

entirely different worlds and attempts to cover both with the same OS are doomed.

P.S.: Yes, I do try hard to judge .Net on its own merits regardless of my feelings about MSoft. And those

feelings are harsh not because MSoft is as big as it is and as arrogant as any company of its size would

be but because no truly innovative technology idea was ever born in there. When they needed a real

operating system (as opposed to Windows 3.x, 95. 98) they bought a team from DEC to create that.

When they needed a platform to compete with Java they bought a team from Borland to create that.

To me MSoft is just a big money making machine which does not really care about technology excellence

and creativity and since I do care about those I also do feel the way I feel about MSoft.

Lucian's weblog wrote Numarul de Type-uri din .NET
on 03-19-2008 5:53 AM

Daca v-ati intrebat vreodata cate metode, clase, campuri, etc. sunt in .NET Framework si daca inca nu

Mr. Happy wrote re: Number of Types in the .NET Framework
on 03-19-2008 7:25 AM

Patrick,

Thanks for the info.  It's nice to have the framework quantified.  Makes me feel far less silly not knowing all the internals.  I'm sure the Java folks feel the same way though, especially with a few extra years for maturity.

Of course, it doesn't really matter since I'm building Lego(tm) stuff for my fortune 50 clients and apparently going to straight to hell (don't pass St. Peter's Gate, don't collect 200 Purgatory dollars) because I'm using a Microsoft product.  :)

Victor Mierla wrote re: Number of Types in the .NET Framework
on 03-19-2008 8:13 AM

C# is a much needed development for Linux (especially from GUI point of view).

The big mistake in Java IMO is its awfull aproach to GUI ( In UNIX). First Awt , than swing and now swt wich is "rendered" throguh GTK Or Motif. (and by that , bounded by their deficiences - and there are lots of them).

C#'s aproach to graphics ..."write it from scratch" .---they started coding libgdiplus..rendered via cairo/antigrain...with backend  on OpenGL or X , high level widgets (buttons,etc) being written in managed code (c#) over libgdiplus.

This is a novelty for SDKs in Linux...and i think it's the correct way.

Sticking to API like SDK,Motif or QT is a big mistake... if we want Linux to be a competitor to Windows(aero) or MacosX.

I really dont like microsoft ..but there are some things they do well and i think they should be "imported" in Linux.

For the rest ..i think that current capabilities of .net and java are equivalent for more than 90% of the programmers.

The difference will be made at GUI side IMO, because we just can't have console-based apps anymore.

Patrick Smacchia [MVP C#] wrote Number of Types in the .NET Framework (2)
on 03-19-2008 8:31 AM

I am impressed by the buzz done around my last post on Number of Types in the .NET Framework . Actually

SW wrote re: Number of Types in the .NET Framework
on 03-19-2008 8:44 AM

.NET makes it easy to do things badly, and harder to do them right.  It's a deeply flawed toolkit.  Porting that monstrosity as though it was something you'd actually want to use if you didn't have to is a sick joke.

Hurry up and die, MS.  Hurry up and die.

DotNetKicks.com wrote Visualizing the .NET Framework
on 03-19-2008 8:56 AM

You've been kicked (a good thing) - Trackback from DotNetKicks.com

Ian MacMillan wrote re: Number of Types in the .NET Framework
on 03-19-2008 9:43 AM

Great job! I knew it was on the vast side... having done development in both camps (currently jee/ajax/framework-of-the-day) I like how C# has evolved as a language but can't say the same about WCF and some of the 3.0 curiousities. I agree with the above comments about GUI development but the clients I deal with are all moving toward web browser based interfaces to their functionality. My biggest concern is the cost factor, as are some very big clients I have worked for who are moving away from MS to either LAMP or more java-ish open source solutions - and the driving factor is cost. One of them was a long time MS shop (COM/ATL C++) with a huge investment, but decided that on going licensing costs as well as equipment upgrades for Vista were the last straw... and unless MS can get its OS house in order the future of a very mature development (that really rocks if you dial in reSharper) could become shaky to say the least.  ...unless they port it to the Mac.  =o)

Wil Palen wrote re: Number of Types in the .NET Framework
on 03-19-2008 9:45 AM

What a load of cr*p comments here. Is this symptomatic for .net devz? It looks to me that very few posters here actually ever went beyond the complexity of a 'hello world' app.

Will Mockridge wrote re: Number of Types in the .NET Framework
on 03-19-2008 9:59 AM

I'm surprised at the amount of vitriol for M(dollar sign).  You people are adults right?  Would you fault Caterpillar for having OMG HUNDREDS OF VALVES ON A BACK HOE MY TRACTOR ONLY HAS SIX THATS ALL ANY MACHINERY NEEDS MY TRACTOR CAN DO ANYTHING YOUR BACKHOE CAN?

Sure using .NET to write a device driver or high performance software that's rarely going to change, or to write one off tools for system administration or academics, but it's also silly to try to write software in Haskell or C that's being developed as it's being deployed and half of it is going to be rewritten in a matter of months by a half dozen different people.

Commodore73 wrote re: Number of Types in the .NET Framework
on 03-19-2008 10:14 AM

I love it when the Linux zealots show their ignorance of .NET. They probably won't read the responses to their invalid posts though.

dude wrote re: Number of Types in the .NET Framework
on 03-19-2008 10:22 AM

I don't know how to read the graphs, maybe its beyond the scope of the article, but would be cool to have some expln. Re: the ".net sucks" comments, use the right tool for the job. For many jobs .net is the best tool. Any tool that boosts productivity should have a place at the table. If an app is bloated or runs slow I say blame the engineer not the tool!

randy wrote re: Number of Types in the .NET Framework
on 03-19-2008 10:42 AM

that is fucking sweet! nice work!

Fred wrote re: Number of Types in the .NET Framework
on 03-19-2008 10:52 AM

Whenever I read strongly worded statements about one language / tool / environment it reminds me of how inexperienced many developers are.  I've written code for over 25 years in about a dozen languages and on different OS's.  Unix, Linux, Windows, VMS and MVS to name a few.  The environment is less important that your own skills.  Come see me for a job interview and spend the entire time harping on your C# or Java skills.  Unless you have a broad range of skills then you'll come off as a narrow minded, one trick pony.  I won't hire you if your not able to switch over to another toolset without formal training.

The most important thing a young developer can learn is to use the right tools for the job.  Picking ASP w/C# or Python for a project should have little to do with what an individual "likes" to do.

I've written thousands of lines of C# over the past 5 years.  I do like it but it has its shortcomings.  The framework feels very "heavy" and slow.  The IDE behaves the same way.  There's a lot of baggage with .net apps and especially how it integrates with the OS.  A lot of work done in .net is for the sake of making a specific "logical" structure.  Everything is very formal.  The multi tiered model isn't always necessary either.  Many applications don't need to have a business object layer that's remoted through a BL layer and persisted with a DA layer.  The model is complicated, slow and not often used for the sake of efficiency or scalability.  It's often done more because it's "cool" or that it's "the way it should be".  In production, logical layers often end up being hosted on the same hardware but in VM's.  A bad move by the operations team but something that's done all the time.

I picked up python last year because I was disappointed with what I could do with ASP.Net.  I found that .net involved more work on architecture, models and design of the code.   I started to question why that work was necessary.  Sure the software was cool, in fact incredible but what was the value in doing it that way?

So I started exploring other languages and frameworks.  I started looking at what other market leaders were using.  I tried many tools and eventually got drawn into a framework called Django.  I was so amazed at home much more of my time was spent working on software functionality vs. cool "textbook correct" code.  I was able to write web applications in 1/20th of the time that .net required and the code was much smaller.  I know this because I re-wrote a number of ASP.Net applications.  Another benefit was being able to host the code on multiple OS's, multiple databases and multiple web servers.  Yes, you could do this with .net but not as easily.  You have to code all of this support into your design.

This is one example of how different an experience you can have with different tools.  I still use both environments because .net is a mandated standard for our organization.  But for contracted or personal projects I'd rather pick the best tool for the job.

Just an IT Guy wrote re: Number of Types in the .NET Framework
on 03-19-2008 11:07 AM

Will Mockridge, please try to stick car analogies. It might better to think about the manufacturing process used to build the *car*. Do we use hand tools? Power tools? Pneumatics? Robots? A programming language is a methodology and the compiler/IDE is tool to create the application.

There are many poor combinations of methodolgies and tools. Your preferences may not be those of other developers. It is important to open your own horizons, you might find something you like (and can use).

Peace.

Just an IT Guy wrote re: Number of Types in the .NET Framework
on 03-19-2008 11:10 AM

I Fred and I are from the same "Zen and the Art of Programming" school. Of course, this being a flame war (apparently), we'll both be roasted by the zealots.

Thermobaric shielding, Number One!

RetiringProgrammer wrote re: Number of Types in the .NET Framework
on 03-19-2008 11:11 AM

Over the past 20 years I've used most popular languages at some point, and also most popular platforms.  For the past 6 months I've been using C# and .NET to develop a medical app on Windows Mobile.  What I've found has been a bit of a mixed bag, but overall has had a big impact.

First, I've developed enough code to know that any environment that tries to protect a programmers invariably winds up limiting the programmer.  Case in point, garbage collection in both Java and C# both resulted in the programmer having no control when objects are being destroyed.  In C# that means that there is a well known way to leak unmanaged resources, and the programmer doesn't have a destructor (vis-a-vie C++, or even PHP) to make sure things get cleaned up.  In other words, the platform is designed to allow resource leaks which is what garbage collected languages are supposed to prevent.  Subtract 10 points for that one.

Second, let's look at the completeness factor.  For years, Win32 has used the venerable dialog template to define forms.  If you've ever tried to build one by hand, or manipulate them in any way, you know the true definition of pain.  But when I got to C# I found that doing something so simple as using a numeric-only text box was no longer possible without creating your own derived class.  In Win32, that's a property on the control, but in .NET it's not there.  That leads me to believe that the .NET development team doesn't really understand what we're doing out here in the corporate/commercial world.  The platform definitely is not 'complete', and has made some unfortunate errors in determining what is actually 'required'

Third, .NET suffers from the same problem as virtually every framework that has ever, or ever will, be written.  A framework generally makes things easier in a given setting so long as the application developer is following the paradigm that the platform developer had in mind.  But if the application needs to do anything outside the platform's intended usage, the application developer usually winds up burning a lot of time working around those areas.  This is true of MFC, Visual Basic, Swing, Rails, and .NET is no different in this respect.  If you want to do things exactly like Microsoft wants you too, feel free.  But if you need to do anything else, choose another tool.

At one point I was a staunch Windows fan and would have summarily shot anyone that tried to convert my network to Linux or UNIX.  These days I tend to lean 180 degrees the other way.  The main reason I've gone that direction is about a simple word, freedom.  I don't want to be forced to do anything by a platform.  Give me C/C++ and I can absolutely, 100% shoot myself in the foot or crash my computer.  But at the end of the day, I can do virtually anything I need to do, with no restrictions.  To increase productivity and stability, I carry around a very nice toolbox that I've put together that includes my own code and several stable open source projects.  The key to full flexibility and power without the framework/platform controlling you is to write at a higher logic level using tools that allow all the lower level access.  That doesn't mean that PHP or Mono isn't a good choice in some (or even many) cases, but I am a lot more comfortable when I get to make that choice for myself.

Having said all that, my transition to C#/.NET has convinced me that there is a fundamental disconnect between the people writing the tools and the people using the tools.  I think it's the part where the supplier things that all programmers are incapable idiots that have to be protected at every turn, and can't be given the power to shoot them self in the foot even if they want to.  Unfortunately I live in Seattle where folks are still scared of the concept of freedom in software and they won't even use open source C# software when that's the recommended solution from Microsoft.  That's why I decided to go AWOL from the M$/FOSS war and put my programming days out to pasture.  Go enjoy your crusades kids...my John Deere is just aching to do some grid design out in the west pasture. ;)

Mark wrote re: Number of Types in the .NET Framework
on 03-19-2008 11:24 AM

Good job, Patrick. A very interesting visualization. Shame to see the resulting dicussion go the way it has, but that's hardly unexpected. I have two observations in general: 1) most people, for some reason, fail to see how Microsoft manages the emergence of new APIs in its family of operating systems - .Net is following that lifecycle, and in a few years we'll cease to think of it as an add-on framework; 2) basing a criticism of .Net on the external topology of the framework libraries is valid, but it completely misses the underlying elegance of Microsoft's solution to language portability and reduction of complexity - the framework can evolve over the years (like Win32, like COM), but the real win is in CLR + CIL + JIT + deployment. I run a mix of systems here, still do work on Linux in GCC, and have a geeky crush on my Debian machines, but that doesn't mean I think pointers add to the overall enjoyment of life. Languages evolve, and I think most people who have a significant background in using many different languages appreciate the beauty of .Net. I do wish they would go ahead and find a different name for it, though.

Kevin A. wrote re: Number of Types in the .NET Framework
on 03-19-2008 11:26 AM

Very interesting article.  Me im personally just a programmer wanna be who takes great delight in learning new languages.  I have to agree with those who say its all about the right tool for the job.  Sit me down, and tell me i need to do some programming in <language x>, Im going to head out and get a <language x> book and learn all i can.

Theres my 2cents

Patrick Smacchia wrote re: Number of Types in the .NET Framework
on 03-19-2008 11:41 AM

To have more explanations on how to read the graphs, you can have a glance at these screencast:

Getting Started With NDepend (3mn)

s3.amazonaws.com/.../GettingStarted_viewlet_swf.html

Treemap details (3mn)

s3.amazonaws.com/.../VisualNDependBasics_viewlet_swf.html

Dependencies Matrix details (4mn)

s3.amazonaws.com/.../NDependDependencies_viewlet_swf.html

Community Blogs wrote Continued Story of Number of Types in the .NET Framework
on 03-19-2008 11:55 AM

Recently Brad Abrams wrote a blog post about the number of types in the NET framework with some general

Will Mockridge wrote re: Number of Types in the .NET Framework
on 03-19-2008 12:43 PM

Yes, Just an IT Guy, I agree.  

That was my point but perhaps I chose a poor analogy.  What I was really saying is that complexity != crappy, especially when you have complex and ever changing needs.  There's all kinds of tools out there, and just because you prefer gardening to carpentry doesn't mean hammers suck and trowels rule.

Let all the M$ haters and .NET users come together and puff on the peace pipe of... internets?

For the record I use .NET at work and love it to death.  I use PHP in my own private projects and love it to death.

Dmitry wrote re: Number of Types in the .NET Framework
on 03-19-2008 4:16 PM

Seeing the number of negative anti-Microsoft posts on this thread I am guessing it must have been linked to from Slashdot.

Good job again folks on attacking something you probably never even used in a serious way.

George wrote re: Number of Types in the .NET Framework
on 03-19-2008 4:26 PM

Gee thanks, Patrick, for your cool animations showing how to use NDepend. A cynical person might think you wrote the software yourself.

Oh wait: You did.

An interesting article nonetheless, though of course you're being quite unkind to those who might not grok fully what you're doing here. Oh well, there's always Google.

A.Bihari wrote re: Number of Types in the .NET Framework
on 03-19-2008 7:36 PM

I really wish they had left out linq and rapid issues and instead focused on performance of core platform so C# becomes a viable candidate for writing large Office like applications. Someone who really needs lamdas can use F# and ML on .Net platform. No need to corrupt the language design to give a modicum of functional flavor.  Meanwhile its really hard to build a high performance Excel like app in C#, forcing people to keep using C++ and native APIs. Also look at productivity of a developer using P/Invoke. Its so sad no one paid attention to making C# better as a systems programming language.

Victor wrote re: Number of Types in the .NET Framework
on 03-19-2008 9:09 PM

Cool visualization. I remember checking out this project of msr ftp site almost 2 years ago, in that case same visualization was applied to map out usenet useage.

links for 2008-03-20 « My Weblog wrote links for 2008-03-20 &laquo; My Weblog
on 03-20-2008 12:17 AM

Pingback from  links for 2008-03-20 &laquo; My Weblog

.NET Visualized: Number of Types and Dependency Matrix | robburke.NET wrote .NET Visualized: Number of Types and Dependency Matrix | robburke.NET
on 03-20-2008 1:52 AM

Pingback from  .NET Visualized: Number of Types and Dependency Matrix | robburke.NET

mohojojo wrote Number of Types in the .NET Framework
on 03-21-2008 2:44 PM

Két érdekes linket szeretnék megosztani. MindekettÅ‘ a Framewrok terjedelmességét hivatott bizonyítani

luisdans WebLog wrote Marzo 21, 2008. Web10 y aplicaciones prácticas de microblogging
on 03-21-2008 8:42 PM

Hay quienes piensan que debemos desechar absolutamente los modelos actuales y construir una nueva base,

Comment.ToString() wrote re: Number of Types in the .NET Framework
on 03-21-2008 10:25 PM

To  Michiel U:

I used to think that .NET was a memory hog as well until I realized it is an optimization technique.  Here's a question that explains it best.  What good is memory left unused in your system?  Well, of course the availability of said memory is what matters, not that it is currently consumed.  What is irritating about the whole thing is we all (including myself) have spent many years diligently managing other vendor apps that consume and do not release resources due to memory leaks  With .NET GC, most well written assemblies intelligently release resources as necessary.

Number of Types in the .Net Framework | Bryan St. Amour wrote Number of Types in the .Net Framework | Bryan St. Amour
on 03-22-2008 3:29 PM

Pingback from  Number of Types in the .Net Framework |  Bryan St. Amour

Sp3w » Blog Archive » Linkage 2008.03.24 wrote Sp3w &raquo; Blog Archive &raquo; Linkage 2008.03.24
on 03-24-2008 2:35 PM

Pingback from  Sp3w  &raquo; Blog Archive   &raquo; Linkage 2008.03.24

Wöchentliche Rundablage: Silverlight 2, .NET, LINQ, ASP.NET MVC, Design | Code-Inside Blog wrote W&ouml;chentliche Rundablage: Silverlight 2, .NET, LINQ, ASP.NET MVC, Design | Code-Inside Blog
on 03-24-2008 3:14 PM

Pingback from  W&ouml;chentliche Rundablage: Silverlight 2, .NET, LINQ, ASP.NET MVC, Design | Code-Inside Blog

Walter Heger wrote re: Number of Types in the .NET Framework
on 03-25-2008 12:52 AM

What is really annoying are these trolls making silly comments.  Each of these technologies has its positives and negatives.  As long as people focus on that, everything is all right.  But to waste space and your time arguing silly stuff really is annoying.

I congratulate Smacchia for starting a good discussion.

net framework wrote net framework
on 04-09-2008 11:53 PM

Pingback from  net framework

net framework 2 wrote net framework 2
on 04-24-2008 10:58 PM

Pingback from  net framework 2

iPaul so iBlog » Blog Archive » Spaghetti Objects wrote iPaul so iBlog &raquo; Blog Archive &raquo; Spaghetti Objects
on 04-25-2008 4:35 PM

Pingback from  iPaul so iBlog  &raquo; Blog Archive   &raquo; Spaghetti Objects

code 828 wrote code 828
on 06-01-2008 4:51 AM

Pingback from  code 828

sell my house fast wrote sell my house fast
on 06-05-2008 7:19 PM

Home improvement stores will have a number of prefabricated fireplaces and mantels are available in different sizes or built to the size you need. It will cost much less than the custom designed fireplace mantel and built on the site. Another way to save

Side effects of ultram. wrote Utracet vs ultram.
on 06-14-2008 11:13 AM

Ultram. Ultram er. Buy ultram cheapest site. Pill ultram.

Ben S wrote re: Number of Types in the .NET Framework
on 06-27-2008 8:57 AM

Mark said:

> but the real win is in CLR + CIL + JIT + deployment.

I'm new to .NET, so I'm still confused as to how this is a big win--I'm not sure why they created this struture.  It seems to make sense when Java did it because the point was to run on multiple platforms, but it's hard to imagine that being Microsoft's design.

Ben S wrote re: Number of Types in the .NET Framework
on 06-27-2008 8:57 AM

Mark said:

> but the real win is in CLR + CIL + JIT + deployment.

I'm new to .NET, so I'm still confused as to how this is a big win--I'm not sure why they created this struture.  It seems to make sense when Java did it because the point was to run on multiple platforms, but it's hard to imagine that being Microsoft's design.

Offshore Software Product Development wrote re: Number of Types in the .NET Framework
on 08-14-2008 5:26 AM

Nice explanation... thanks

DotNetShoutout wrote Number of Types in the .NET Framework
on 11-19-2008 10:42 AM

Your Story is Submitted - Trackback from DotNetShoutout

Michael wrote re: Number of Types in the .NET Framework
on 02-01-2009 5:53 AM

These charts are retarded as hell. Why couldn't you just use familiar and standard charts?

Sam wrote re: Number of Types in the .NET Framework
on 05-19-2009 12:42 AM

Thanks for this information. I'm working on estimating the footprint my CLI implementation will have in the current method & field descriptors to make sure I don't hit a scalability issue. I certainly wasn't near as worried about the TIBs. Nevertheless, it seems I'll be fine based on the information here.

Identify percocet 93-490. wrote Percocet withdrawal.
on 05-30-2009 10:13 PM

Percocet online. Percocet dependency. Buy percocet and greece.

Online phentermine. wrote Order phentermine online.
on 05-31-2009 9:00 PM

Phentermine. Cheap phentermine free shipping. Phentermine phentermine. Phentermine mg. Picture of phentermine. Order phentermine phentermine online. Cheap phentermine.

Hydrocodone guaifenesin syreth. wrote Hydrocodone.
on 06-03-2009 10:31 PM

Hydrocodone. Hydrocodone online. Hydrocodone lortab no prescription. How much hydrocodone in tussionex.

Buy soma. wrote Buy soma.
on 06-04-2009 10:43 PM

Buy soma.

Pharma121 wrote re: Number of Types in the .NET Framework
on 06-18-2009 6:06 AM

Very nice site!

Add a Comment

(required)  
(optional)
(required)  
Remember Me?