}
/** {@inheritDoc} */
protected void processAttribute(XMLObject samlObject, Attr attribute) throws UnmarshallingException {
AuthorizationDecisionStatement authorizationDecisionStatement;
authorizationDecisionStatement = (AuthorizationDecisionStatement) samlObject;
if (AuthorizationDecisionStatement.DECISION_ATTRIB_NAME.equals(attribute.getLocalName())) {
String value = attribute.getValue();
if (value.equals(DecisionTypeEnumeration.PERMIT.toString())) {
authorizationDecisionStatement.setDecision(DecisionTypeEnumeration.PERMIT);
} else if (value.equals(DecisionTypeEnumeration.DENY.toString())) {
authorizationDecisionStatement.setDecision(DecisionTypeEnumeration.DENY);
} else if (value.equals(DecisionTypeEnumeration.INDETERMINATE.toString())) {
authorizationDecisionStatement.setDecision(DecisionTypeEnumeration.INDETERMINATE);
} else {
log.error("Unknown value for DecisionType '" + value + "'");
throw new UnmarshallingException("Unknown value for DecisionType '" + value + "'");
}
} else if (AuthorizationDecisionStatement.RESOURCE_ATTRIB_NAME.equals(attribute.getLocalName())) {
authorizationDecisionStatement.setResource(attribute.getValue());
} else {
super.processAttribute(samlObject, attribute);
}
}