Brandon,
I'm interested in using the decorator pattern to extend the role provider as you mentioned, do you have some shell example code along with the web.config settings? in VB.NET? For version 4.9 and higher.
I was reviewing your UPM Membership code samples in C# which are somewhat helpful, but I'm still a little unclear as to the syntax for creating the Decorator.
I am trying to determine if there is any value in creating the capability of a Role Hierarchy (IE RoleID, ParentRoleID satellite table) that would allow admins to define Roles in such that if a user is a member of a role, they are also a member of all child roles.
Since many modules allow functional control via roles, including specific capabilities within the module, I thought it would be nice to simplify the administration in the specific case of hierarchy requirements.
Example / Setup:
Role 1 is a parent to role 1.1 and role 1.2 as defined in a satellite table(managed separately).
User 1 is ONLY a member of Role 1 and User 2 is ONLY a member of Role 1.2
So lets simply put 3 document modules on a page (D1, D1.1, and D1.2) each of which is viewable by their respective "Role" assignment with same Parent/Child Level defined under their individual module settings.
Required Result is the following :
User 1 sees all (3) modules on the page, and User 2 sees only the Module D1.2.
My thought is to simply Decorate the RoleProvider ... Get UserRole... functions to return "true" if the user is in the selected role or any "child" roles. Obviously, If the function returns a comma separated list of "Role Names", all child role names would be returned as well (known issues with string length on this)
Your Thoughts?
Chuck