7.16.2011

Component-based Development

I'm quite 'round quite a few strange concepts from time to time, but most of them are just candy. Candy for those project managers and wannabe software "designers" with emphasis on design for presentations and papers. Old bricks painted in new metallic colors but still providing a wooden core like always. Though... they use rather old woold not up-to-date but put their new labels on it. However! During all those lectures about component-based development, the lecturer didn't even mention what it actually in detail is - not even in a sidenode! What a pity that another one wanted use to write an assignment using it. I didn't care about until a few days ago and since I had a lengthy discussion with that lecturer, I noticed how actually much I have to do to actually call the project we're not really working on anymore. I really coded him something that's, on a binary level, exactly what he wanted. But you know what? He wants design. Yes, design. "Component design". As if there isn't more useful stuff on the planet. Components and it's related development "form" is only a new, fancy and object-oriented term for the good old dynamic libraries. Really, it's that simple. Everyone saying something else does either see it different from how I do (on a plain and direct binary level) or does again see only magic and fairy dust. However, those components have be reusable and generic. How funny. Millions of C programmers did that in the classic manner before. Now it's so different cause it's still the same but with more glitter and sparkling light effects.

Stepping aside from my usual rants about those marketed approaches, I had to "invent" some kind of component platform to fulfill the lecturers desire for more componenty "design"s. We are using Qt as our framework for database access and GUI control. Qt itself does not provide any component platform support, but you can load dynamic libraries and Qt plugins to your liking. At first I simply load two singletons, connected them with quite a lengthy main code and that was it. Too bad that wasn't a component to him. So what I'm doing currently is to double to amount of code and essentially insert it twice to give each component the same abilities like the other, only with some different operations... pathetic. He's so in his "omfg those components HAVE to be reusable any time!!1", that he simply forgets that it would be totally useless in our case to it the way he wants... but whatever, that's the source of marks I have right now... shouldn't screw it cause I know it better. All in all, the only interesting part about is coding the component platform itself. I made a really miscroscopic platform that works by user-based insertion of libraries and then accessing the singletons them using string identifiers. There's even support for component depencies and so on - I think this, along with some more "reusable" (oh how I hate this term when using it like that) component functions that be configured alone, by using Qt objects oder by guessing other component's settings should really be enough... I mean what does he aim at. I can code him whatever he wants in a few hour (the component server didn't took me more to finalize) in less time required to design his stupid components. The secret doesn't like behind time-wasting development but in knowledge and ability. They should rather teach their students how to think and design like a computer, translating reallife problems and questions into a computer language of their choice. Yes, that may sound quite generic, but this as well as knowledge about technology and methodology is where it really matters. Most students I know can create a JSP webpage but don't know enough about Java/Javascript and it's abuse to get the webpages performant or even complex enough in function. I still believe it's more fruitful in result to teach them how to make stuff good and not how to another stupid marketing gag. One could say that companies see it different. That they want to train them on their own but only having them able to operate tools - not more until some of them have good ideas or so. Sad world, sad world.

Somehow I thought about to release that kind of platform system to dynamically load and set interfaced libraries in C. I still have to create something like that for my programming language, so it's a good first practice to do so. Of course, it's Qt. And of course, C has to iterate it on it's own, with less feedback and comfort. But it's all in all more direct and make you able to see how few things it actually consists of. Simply loading libraries, not more! So easy, so simple, so nothing like stupid models or so. Components are for whimps, use dynamic libraries.

No comments: