Permission resolvers for content pack resources (sensors, actions, action aliases, rules) use the same logic.
Permission resolvers for content pack resources (sensors, actions, action
aliases, rules) use the same logic.

Refactor common functionality in a base class and reduce duplicated code.

pixelrebel/st2,Plexxi/st2,armab/st2,punalpatel/st2,StackStorm/st2,alfasin/st2,tonybaloney/st2,dennybaa/st2,pixelrebel/st2,lakshmi-kannan/st2,emedvedev/st2,lakshmi-kannan/st2,tonybaloney/st2,nzlosh/st2,Plexxi/st2,tonybaloney/st2,StackStorm/st2,dennybaa/st2,StackStorm/st2,lakshmi-kannan/st2,Plexxi/st2,armab/st2,peak6/st2,StackStorm/st2,nzlosh/st2,emedvedev/st2,punalpatel/st2,dennybaa/st2,nzlosh/st2,alfasin/st2,nzlosh/st2,emedvedev/st2,pixelrebel/st2,peak6/st2,punalpatel/st2,alfasin/st2,peak6/st2,Plexxi/st2,armab/st2