Hi
I usually timestamp everything that I persist into the database with
DateTime, I use two properties named Created and Modified.
After going though various solutions I still haven't come up with
something really I like.
1.
override every Save,Update, Create method and add something like
created = DateTime.Now; (should only be set when created)
modified = DateTime.Now;
2.
using the protected override bool BeforeSave(IDictionary state){}
wich only seems to be called in some cases (haven't figures out what)
3.
I have also looked at the Timestamp/Version attribute, but it doesn't
seem to let me control when it should be used (eg. on save, update,
create)
Have I missed something? or do I really have to go with number 1,
since that one seems to give me the most control.
best regards,
Mark
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Castle Project Users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/castle-project-users?hl=en
-~----------~----~----~----~------~----~------~--~---