@Secures
@Secured({ })
@SuppressWarnings("UnusedDeclaration")
public boolean doSecuredCheck(InvocationContext invocationContext) throws Exception
{
Secured secured = null;
List<Annotation> annotatedTypeMetadata = extractMetadata(invocationContext);
for (Annotation annotation : annotatedTypeMetadata)
{
if (Secured.class.isAssignableFrom(annotation.annotationType()))
{
secured = (Secured) annotation;
}
else if (voterContext instanceof EditableAccessDecisionVoterContext)
{
((EditableAccessDecisionVoterContext) voterContext)
.addMetaData(annotation.annotationType().getName(), annotation);
}
}
if (secured != null)
{
Class<? extends AccessDecisionVoter>[] voterClasses = secured.value();
invokeVoters(invocationContext, Arrays.asList(voterClasses));
}
//needed by @SecurityBindingType