> In your opinion, which is the best way to implement the query object
> pattern:
>
> 1) by using IQueryable/IQueryable<T>
> 2) by using ICriteria/DetachedCriteria
> 3) custom classes
>
> What I mean is, assuming that we have an object that stores query
> parameters (page size, page index, filters, etc) that goes all the way
> to the presentation layer, which is the better option for doing so, so
> that it is possible to enhance the original query?

As soon as you need to cross a process boundary - from an application
server to a client, or from webserver to browser - anything that
depends on IQueryable or ICriteria is going to have associated
"baggage" that becomes a liability.

Having a custom class gives you a lot more control over how this plays
out. There are a myriad of patterns you *could* follow - in your
shoes, I'd start with the "Specification" pattern and branch out if
that didn't work for me.

Just my 2c.
Bevan.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"nhusers" 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/nhusers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to