Browse by Tags

Tagged Content List
  • Blog Post: Creating a Data Service Provider – Part 9 – Un-typed

    Background info: This post builds on Parts 1 thru 8 which teach you how to create a typed Data Service Provider. But now the part we’ve all been waiting for- an un-typed DSP – which is what I expect most real world DSP implementations will be based on. What do we mean by Un-typed? An un-typed DSP is...
  • Blog Post: Tip 55 - How to extend an IQueryable by wrapping it.

    Over the last couple of years I’ve found myself in lots of situations where I’ve wanted to get ‘under the hood’ and see what is happening inside an IQueryable, but I haven’t had an easy solution, at least until now. Getting down and dirty like this is interesting because it means you can: Log...
  • Blog Post: Tip 54 – How to improve performance using Statement Expressions

    Background: While writing the update post in my Data Service Provider series I ended up writing this block of reflection code to copy properties values from one object to another: foreach (var prop in resourceType .Properties .Where(p => (p.Kind & ResourcePropertyKind.Key) != ResourcePropertyKind...
  • Blog Post: Tip 36 – How to Construct by Query

    While writing my tips series and writing EF controllers for MVC I found that I regularly wanted to create and attach a stub entity . Unfortunately it isn’t quite that simple, you have to make sure the entity isn’t already attached first, otherwise you’ll see some nasty exceptions. To avoid these exceptions...
  • Blog Post: Tip 35 – How to write OfTypeOnly<TEntity>()

    If you write a LINQ to Entities query like this: var results = from c in ctx.Vehicles.OfType<Car>() select c; It will bring back, Cars and any type that derives from Car, like say SportCar or SUV. If you just want Cars and you don’t want derived types like SportCars or SUVs in LINQ to...
  • Blog Post: Composable Services

    Dru Sellers just used a term I haven’t heard before, Composable Services . For me it the very timely term, because it succinctly describes a whole lot of Astronaut Architect dreaming I’ve been doing for the last 2 years. I recently started twittering as adjames *, and I’ve noticed, the stream of consciousness...
  • Blog Post: Maybe there is more

    Michel Perfetti , has taken my little Maybe thingie and gone a lot further , by using expression tree re-writting he has made it possible to express this: string code = licensePlate.Maybe(lp => lp.Car) .Maybe(c => c.Owner) .Maybe(o => o.Address) .Maybe(a => a.PostCode); which is...
Page 1 of 1 (7 items)