Building Great Windows 7 Apps
posted by Davbis93(17) 1 year, 9 months ago +1
Wow!! It looks so easy! all you have to do is copy/paste hundreds of lines of code, prepared earlier!
Reply
How to Expose Your Collections Safely
posted by Davbis93(17) 4 years, 1 month ago 0
I exposed my collection in an unsafe manner once. Ended up spending a night in the slammer :(
Implementing Generic Caching
posted by Davbis93(17) 4 years ago 0
Hi, Regarding your suggestion of using a static property - I completely agree, and have updated the code sample accordingly. Also, regarding the HttpContext dependency, I originally had a singleton implementation, which I removed from this post for the sake of brevity, however you've inspired me to put this back in, as some may find it useful. simonech, Given the example you suggested, if using this, you'd be forced to cache the "whole newspaper" and use something like: SafeCache<Newspaper>.Object.Categories(2). However, I think it might be possible to have a different version of this, which is parameterized generically, by having: public SafeCache<Type, Parameter> { public Type GetObject(Parameter param) { //Get and cache including param.ToString() somehow in the cache-key } } I'm sure there's probably a more flexible way of doing this. Thanks for your ideas, Dave
TFS Sucks, here is a list why
posted by Davbis93(17) 2 years, 8 months ago 0
I dissagree with some of your points. Identical Files - I'm not sure what you're talking about: A file won't get cehcked-in if it doesn't contain any changes. Code reviews/update - You can easily achieve this, by right-clickinmg in a code-window, and going source-control/annotate. Project file modification - This would be a complete pain in SVN too (I'm pretty sure) - you could always have two project files - one for each server. (this would need maintaining, in the case of changes to the solution structure) Everything needs to be in the solution - Wrong. You can add add-hoc files from source control explorer, by clicking the "add files" button. I've used both SVN and TFS quite extensivly - and find that in general, TFS & VS are wonderful tools - although not without their faults. I find during day-to day usage of SNV - that my source-tree breaks for no-reason all the time. I get "unresolved conflicts" for no reason at all. It constantly tell me to "clean up" - and then the "clean up" crashes my computer. Both products are imperfect - but at least Microsoft doesen't release updates every 10 minutes, like Tortoise do.