Geeks With Blogs

News My Blog has been MOVED to

Michael Freidgeim's OLD Blog My Blog has been MOVED to February 2013 Entries
EntLIb editor corrupts config files
I've tried to use Microsoft Enterprise Library(EntLIb) editor, as it was suggested in but after changes all comments in config files were removed. Always consider to move any Enterprise Library configurations to a separate file before editing ......

Posted On Saturday, February 16, 2013 3:45 PM

Static methods not always bad for testability
Some time ago I've posted a few links about What is testable code?Reading the links someone can feel that any static methods are bad for testability. However it is a wrong impression- static methods without external dependencies are good for testing. http://programmers.stackexc... is nothing wrong with static methods and they are easy to test (so long as they don't change any static data). For ......

Posted On Saturday, February 16, 2013 3:24 PM

Using PostSharp.Toolkit.Diagnostics, when not all developers have Pro licenses.
We have only couple of developers who are using PostSharp.Toolkit.Diagnostics and having PostSharp Pro license .However ther are much more developers , who are building our solution, but do not required Toolkit.Diagnostics XmlMulticast features, that are referred in %ProjName%.psproj file.As a workaround I've suggested to to replace locally psproj file with dummy, that doesn't have XmlMulticast(PostSharp feature that available only in Pro edition).If a developer doesn't have PostSharp Pro license, ......

Posted On Saturday, February 16, 2013 2:57 PM

VAB ValidationResults Extensions
We've started to actively used Microsoft Enterprise Library Validation Enterprise Block ( VAB) and I was surprised , that a few commonly used operations are not supplied(or I haven't found them) out of the box.See two extensions, that make use of VAB simplerpublic static class ValidationResultsExtensions { public static string CombinedMessage( this ValidationResults results) { string errorMessage = ( from res in results select String.Format(" {0}:{1} ", res.Key, res.Message)).ToDelimitedSt... ";"); ......

Posted On Saturday, February 16, 2013 2:46 PM

Using CollectionNotEmptyValidator
We recently started to use Microsoft Enterprise Library Validation Enterprise Block (VAB) to check interfaces between modules. One of the properties to validate is array of values, that should be not empty, and shoul include one of expected values. I found CollectionNotEmptyValidator at that allows to validate the property to satisfy part of requirements. The class ......

Posted On Saturday, February 16, 2013 2:35 PM

Copyright © Michael Freidgeim | Powered by: