Friday, 9 August 2013

Filtering data based on user - Class design pattern

Filtering data based on user - Class design pattern

I have a web service that publishes data that results from a LINQ query.
I am looking for advice on how to design a Class/Interface structure where
the query filter depends on the user that is logged in.
I can do this the old fashioned way simply by using IFTHEN spaghetti code,
or using a dictionary map, but neither of these methods seem optimal.
I was thinking about custom attributes, but maybe I just need a proper
design pattern instead.
Thanks!

No comments:

Post a Comment