/** * see if a group or parent or ancestor folder has an attribute. this can run securely. * * @param attributeFlagName * @param checkSecurity * @return true if group or stem has attribute */ public boolean hasAttributeOrAncestorHasAttribute( final String attributeFlagName, final boolean checkSecurity) { final AttributeAssignable owner = this.getAttributeAssignable(); if (checkSecurity) { Subject subjectMakingCall = GrouperSession.staticGrouperSession().getSubject(); return hasAttributeOrAncestorHasAttributeHelper( owner, null, attributeFlagName, subjectMakingCall); } return (Boolean) GrouperSession.internal_callbackRootGrouperSession( new GrouperSessionHandler() { public Object callback(GrouperSession grouperSession) throws GrouperSessionException { return hasAttributeOrAncestorHasAttributeHelper( owner, null, attributeFlagName, grouperSession.getSubject()); } }); }