Looks better to me, not difficult to understand. It'd increase
symmetry if we were to add a getPermissionResolver() to
PermissionResolverAware interface.

Kalle


On Thu, Jul 12, 2012 at 7:39 AM, Les Hazlewood <[email protected]> wrote:
> Per Kalle's comments in the issue, it does sound a bit weird to do this.
>
> However, I could see how this could be used, i.e. OO Delegation (call
> the IniRealm, it delegates to its internal resolver).
>
> I wonder if there might be a better way?  Because it is not common for
> Realms to implement this interface directly (and instead delegate to a
> resolver component), it feels like an 'implementation detail' to do
> this.  That is, the end-user has to know that the Realm implements
> this interface when it is quite common that Realms do not do this.
>
> Maybe it can be a bit more explicit and conform to the behavior of any
> AuthorizingRealm?  For example:
>
> myRealm.rolePermissionResolver = $iniRealm.rolePermissionResolver
>
> I'm not sure if this is better - it's just an idea for discussion.
>
> Thoughts?
>
> --
> Les Hazlewood | @lhazlewood
> CTO, Stormpath | http://stormpath.com | @goStormpath | 888.391.5282
> Stormpath wins GigaOM Structure Launchpad Award! http://bit.ly/MvZkMk
>
>
> On Wed, Jul 11, 2012 at 12:31 PM, Jared Bunting
> <[email protected]> wrote:
>> I just wanted to get a quick sentiment on this:
>>
>> https://issues.apache.org/jira/browse/SHIRO-371
>>
>> It seems useful to me (and was prompted by a question on Stack Overflow)
>> but it does add a public interface to a fairly central piece of the core
>> library.  Are there any objections?
>>
>> Thanks,
>> Jared

Reply via email to