Examples of SubjectMatchType


Examples of org.opensaml.xacml.policy.SubjectMatchType

        super();
    }

    /** {@inheritDoc} */
    protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException {
        SubjectMatchType matchType = (SubjectMatchType) xmlObject;

        if (!DatatypeHelper.isEmpty(matchType.getMatchId())) {
            domElement.setAttribute(SubjectMatchType.MATCH_ID_ATTRIB_NAME, matchType.getMatchId());
        }
    }
View Full Code Here

Examples of org.opensaml.xacml.policy.SubjectMatchType

    }

    /** {@inheritDoc} */
    protected void processChildElement(XMLObject parentXMLObject, XMLObject childXMLObject)
            throws UnmarshallingException {
        SubjectMatchType matchType = (SubjectMatchType) parentXMLObject;
   
        if (childXMLObject instanceof AttributeValueType) {
            matchType.setAttributeValue((AttributeValueType) childXMLObject);
        } else if (childXMLObject.getElementQName().equals(
                AttributeDesignatorType.SUBJECT_ATTRIBUTE_DESIGNATOR_ELEMENT_NAME)) {
            matchType.setSubjectAttributeDesignator((AttributeDesignatorType) childXMLObject);
        } else if (childXMLObject instanceof AttributeSelectorType) {
            matchType.setAttributeSelector((AttributeSelectorType) childXMLObject);
        } else {
            super.processChildElement(parentXMLObject, childXMLObject);
        }
    }
View Full Code Here

Examples of org.opensaml.xacml.policy.SubjectMatchType

    }

    /** {@inheritDoc} */
    protected void processAttribute(XMLObject xmlObject, Attr attribute) throws UnmarshallingException {
        if (attribute.getLocalName().equals(SubjectMatchType.MATCH_ID_ATTRIB_NAME)) {
            SubjectMatchType matchType = (SubjectMatchType) xmlObject;
            matchType.setMatchId(DatatypeHelper.safeTrimOrNullString(attribute.getValue()));
        } else {
            super.processAttribute(xmlObject, attribute);
        }
    }
View Full Code Here

Examples of org.opensaml.xacml.policy.SubjectMatchType

        if (attribute == null) {
            return null;
        }

        SubjectMatchType subjectMatch = build();

        AttributeDesignatorType designator = AttributeDesignatorHelper.build(
                AttributeDesignatorType.SUBJECT_ATTRIBUTE_DESIGNATOR_ELEMENT_NAME, attribute);

       
        String attributeDataType =  (matchFunctionDatatype == null ?attribute.getDataType() : matchFunctionDatatype);
       
        AttributeValueType policyAttributeValue = PolicyAttributeValueHelper.build(attributeDataType,
                CtxAttributeTypeHelper.getFirstValue(attribute));

        subjectMatch.setSubjectAttributeDesignator(designator);
        subjectMatch.setAttributeValue(policyAttributeValue);
        subjectMatch.setMatchId(matchFunctionId);

        return subjectMatch;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.