Well, it started life as an IoC Container ,but then we added this bit...
I hate planning. This comes from a long experience at all the problems that raise when you have faulty planning.
So, today I intended to have the class write an IoC container ,but somehow, still not sure how, we ended up building the trivial OR/M imp
Let me say first that this is sample code, written in the span of a few hours, off the cuff coding, etc. Not meant for production... It doesn't even have identity map or unit of work. But, it shows that it takes only a few hours to make a significant improvement in the way you work, if you are not already using the best tools out there.
And allow me to reiterate that this was written by me and the students in about two and a half hours only. I hope that this would take care of the "can't handle it" muttering.
Comments
SampleORM...a compelling replacement for NHibernate... :)
i wonder now that how castle project started actually
Maybe just a hello world sample?
It's too bad I'm across the big pond, I'd love to attend one of your classes.
I have a subject matter you can cover next: how to build a proxy (like DynamicProxy2) - perhaps a lazyload example :)
Steve,
You don't build a proxy generation. At least not if you value your time.
That is so not something that you can do in a class, the amount of effort vs. gain is tremendous.
I have no idea how Hammett has done it, twice.
Completely offtopic, but nonetheless...
I'm always extra cautious when it comes to "fake" e-mail addresses. I mean, if your sample code ever gets extended and live a life on its own, some Fishers at Iceland might get upset.
If you don't get it, just check http://www.yyy.com, to see where your mails would be going ;) That's why I usually choose for non-existing tld's, like .bar or .test
Please do more of this, it's great!
Use the .invalid TLD, it was specially reserved by IANA for example/test purposes
I thought Castle project was a part of the Apache long ago? I read it somewhere... maybe confusing with something else.
MarioL,
Castle uses the apache license, and the internal mechanics are taken from the apache processes, but it not an apache project.
Hammett, the founder, took part in several apache projects in the past.
Those are the connections that I am aware of
This looks like the orm I came up with 2 years ago - decorating objects with attributes to say which table and column they go into and using reflection to loop through it. Only mine is much less elegant, hideously ugly and unmaintainable. Oddly enough I abandoned it for NHibernate about 3 months ago.
Speaking of which, are you still working on the NHIbernate Linq extensions? MS changed a lot for orcas 2.
Ramen,
I'll resume working on it when I managed to get Beta2 working on my machine, or setup some sort VM for it.
Recommend another simple ORM to you. Very impressive, at least to me.
http://www.goeleven.com/blog/entryDetail.aspx?entry=89
Comment preview