/** * Marshall an attribute name and value to a DOM Element. This is particularly useful for attributes whose names * appear in namespace-qualified form. * * @param attributeName the attribute name in QName form * @param attributeValues the attribute values * @param domElement the target element to which to marshall * @param isIDAttribute flag indicating whether the attribute being marshalled should be handled as an ID-typed * attribute */ public static void marshallAttribute(QName attributeName, List<String> attributeValues, Element domElement, boolean isIDAttribute) { marshallAttribute(attributeName, DatatypeHelper.listToStringValue(attributeValues, " "), domElement, isIDAttribute); }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException { SecurityTokenReference str = (SecurityTokenReference) xmlObject; if (!DatatypeHelper.isEmpty(str.getWSUId())) { XMLHelper.marshallAttribute(SecurityTokenReference.WSU_ID_ATTR_NAME, str.getWSUId(), domElement, true); } List<String> usages = str.getWSSEUsages(); if (usages != null && ! usages.isEmpty()) { XMLHelper.marshallAttribute(SecurityTokenReference.WSSE_USAGE_ATTR_NAME, usages, domElement, false); } XMLHelper.marshallAttributeMap(str.getUnknownAttributes(), domElement); }
/** * Marshall an attribute name and value to a DOM Element. This is particularly useful for attributes whose names * appear in namespace-qualified form. * * @param attributeName the attribute name in QName form * @param attributeValues the attribute values * @param domElement the target element to which to marshall * @param isIDAttribute flag indicating whether the attribute being marshalled should be handled as an ID-typed * attribute */ public static void marshallAttribute(QName attributeName, List<String> attributeValues, Element domElement, boolean isIDAttribute) { marshallAttribute(attributeName, DatatypeHelper.listToStringValue(attributeValues, " "), domElement, isIDAttribute); }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException { Timestamp timestamp = (Timestamp) xmlObject; if (!DatatypeHelper.isEmpty(timestamp.getWSUId())) { XMLHelper.marshallAttribute(Timestamp.WSU_ID_ATTR_NAME, timestamp.getWSUId(), domElement, true); } XMLHelper.marshallAttributeMap(timestamp.getUnknownAttributes(), domElement); }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException { RelayState relayState = (RelayState) xmlObject; if (relayState.isSOAP11MustUnderstandXSBoolean() != null) { XMLHelper.marshallAttribute(RelayState.SOAP11_MUST_UNDERSTAND_ATTR_NAME, relayState.isSOAP11MustUnderstandXSBoolean().toString(), domElement, false); } if (relayState.getSOAP11Actor() != null) { XMLHelper.marshallAttribute(RelayState.SOAP11_ACTOR_ATTR_NAME, relayState.getSOAP11Actor(), domElement, false); } }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException { AttributedString attributedString = (AttributedString) xmlObject; if (!DatatypeHelper.isEmpty(attributedString.getWSUId())) { XMLHelper.marshallAttribute(AttributedString.WSU_ID_ATTR_NAME, attributedString.getWSUId(), domElement, true); } XMLHelper.marshallAttributeMap(attributedString.getUnknownAttributes(), domElement); }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException { RequestAuthenticated ra = (RequestAuthenticated) xmlObject; if (ra.isSOAP11MustUnderstandXSBoolean() != null) { XMLHelper.marshallAttribute(RequestAuthenticated.SOAP11_MUST_UNDERSTAND_ATTR_NAME, ra.isSOAP11MustUnderstandXSBoolean().toString(), domElement, false); } if (ra.getSOAP11Actor() != null) { XMLHelper.marshallAttribute(RequestAuthenticated.SOAP11_ACTOR_ATTR_NAME, ra.getSOAP11Actor(), domElement, false); } }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException { UsernameToken usernameToken = (UsernameToken) xmlObject; if (!DatatypeHelper.isEmpty(usernameToken.getWSUId())) { XMLHelper.marshallAttribute(UsernameToken.WSU_ID_ATTR_NAME, usernameToken.getWSUId(), domElement, true); } XMLHelper.marshallAttributeMap(usernameToken.getUnknownAttributes(), domElement); }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject samlObject, Element domElement) throws MarshallingException { GeneratedKey key = (GeneratedKey) samlObject; if (key.isSOAP11MustUnderstandXSBoolean() != null) { XMLHelper.marshallAttribute(GeneratedKey.SOAP11_MUST_UNDERSTAND_ATTR_NAME, key.isSOAP11MustUnderstandXSBoolean().toString(), domElement, false); } if (key.getSOAP11Actor() != null) { XMLHelper.marshallAttribute(GeneratedKey.SOAP11_ACTOR_ATTR_NAME, key.getSOAP11Actor(), domElement, false); } } }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException { AttributedURI attributedURI = (AttributedURI) xmlObject; if (!DatatypeHelper.isEmpty(attributedURI.getWSUId())) { XMLHelper.marshallAttribute(AttributedURI.WSU_ID_ATTR_NAME, attributedURI.getWSUId(), domElement, true); } XMLHelper.marshallAttributeMap(attributedURI.getUnknownAttributes(), domElement); }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException { ChannelBindings cb = (ChannelBindings) xmlObject; if (cb.getType() != null) { domElement.setAttributeNS(null, ChannelBindings.TYPE_ATTRIB_NAME, cb.getType()); } if (cb.isSOAP11MustUnderstandXSBoolean() != null) { XMLHelper.marshallAttribute(ChannelBindings.SOAP11_MUST_UNDERSTAND_ATTR_NAME, cb.isSOAP11MustUnderstandXSBoolean().toString(), domElement, false); } if (cb.getSOAP11Actor() != null) { XMLHelper.marshallAttribute(ChannelBindings.SOAP11_ACTOR_ATTR_NAME, cb.getSOAP11Actor(), domElement, false); } }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException { AttributedDateTime dateTime = (AttributedDateTime) xmlObject; if (!DatatypeHelper.isEmpty(dateTime.getWSUId())) { XMLHelper.marshallAttribute(AttributedDateTime.WSU_ID_ATTR_NAME, dateTime.getWSUId(), domElement, true); } XMLHelper.marshallAttributeMap(dateTime.getUnknownAttributes(), domElement); }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException { Response response = (Response) xmlObject; if (response.getAssertionConsumerServiceURL() != null) { domElement.setAttributeNS(null, Response.ASSERTION_CONSUMER_SERVICE_URL_ATTRIB_NAME, response.getAssertionConsumerServiceURL()); } if (response.isSOAP11MustUnderstandXSBoolean() != null) { XMLHelper.marshallAttribute(Response.SOAP11_MUST_UNDERSTAND_ATTR_NAME, response.isSOAP11MustUnderstandXSBoolean().toString(), domElement, false); } if (response.getSOAP11Actor() != null) { XMLHelper.marshallAttribute(Response.SOAP11_ACTOR_ATTR_NAME, response.getSOAP11Actor(), domElement, false); } }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException { Policy policy = (Policy) xmlObject; if (policy.getName() != null) { domElement.setAttributeNS(null, Policy.NAME_ATTRIB_NAME, policy.getName()); } if (policy.getWSUId() != null) { XMLHelper.marshallAttribute(IdBearing.WSU_ID_ATTR_NAME, policy.getWSUId(), domElement, true); } XMLHelper.marshallAttributeMap(policy.getUnknownAttributes(), domElement); }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject samlObject, Element domElement) throws MarshallingException { SubjectConfirmation sc = (SubjectConfirmation) samlObject; if (sc.isSOAP11MustUnderstandXSBoolean() != null) { XMLHelper.marshallAttribute(SubjectConfirmation.SOAP11_MUST_UNDERSTAND_ATTR_NAME, sc.isSOAP11MustUnderstandXSBoolean().toString(), domElement, false); } if (sc.getSOAP11Actor() != null) { XMLHelper.marshallAttribute(SubjectConfirmation.SOAP11_ACTOR_ATTR_NAME, sc.getSOAP11Actor(), domElement, false); } if (sc.getMethod() != null) { domElement.setAttributeNS(null, SubjectConfirmation.METHOD_ATTRIB_NAME, sc.getMethod()); } } }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject samlObject, Element domElement) throws MarshallingException { SessionKey key = (SessionKey) samlObject; if (key.isSOAP11MustUnderstandXSBoolean() != null) { XMLHelper.marshallAttribute(SessionKey.SOAP11_MUST_UNDERSTAND_ATTR_NAME, key.isSOAP11MustUnderstandXSBoolean().toString(), domElement, false); } if (key.getSOAP11Actor() != null) { XMLHelper.marshallAttribute(SessionKey.SOAP11_ACTOR_ATTR_NAME, key.getSOAP11Actor(), domElement, false); } if (key.getAlgorithm() != null) { domElement.setAttributeNS(null, SessionKey.ALGORITHM_ATTRIB_NAME, key.getAlgorithm()); } } }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException { Response response = (Response) xmlObject; if (response.getRefToMessageID() != null) { domElement.setAttributeNS(null, Response.REF_TO_MESSAGE_ID_ATTRIB_NAME, response.getRefToMessageID()); } if (response.isSOAP11MustUnderstandXSBoolean() != null) { XMLHelper.marshallAttribute(Response.SOAP11_MUST_UNDERSTAND_ATTR_NAME, response.isSOAP11MustUnderstandXSBoolean().toString(), domElement, false); } if (response.getSOAP11Actor() != null) { XMLHelper.marshallAttribute(Response.SOAP11_ACTOR_ATTR_NAME, response.getSOAP11Actor(), domElement, false); } } }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException { SignatureConfirmation sc = (SignatureConfirmation) xmlObject; if (!DatatypeHelper.isEmpty(sc.getWSUId())) { XMLHelper.marshallAttribute(SignatureConfirmation.WSU_ID_ATTR_NAME, sc.getWSUId(), domElement, true); } if (!DatatypeHelper.isEmpty(sc.getValue())) { domElement.setAttributeNS(null, SignatureConfirmation.VALUE_ATTRIB_NAME, sc.getValue()); } }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException { Request request = (Request) xmlObject; if (request.getProviderName() != null) { domElement.setAttributeNS(null, Request.PROVIDER_NAME_ATTRIB_NAME, request.getProviderName()); } if (request.isPassiveXSBoolean() != null) { domElement.setAttributeNS(null, Request.IS_PASSIVE_NAME_ATTRIB_NAME, request.isPassiveXSBoolean().toString()); } if (request.isSOAP11MustUnderstandXSBoolean() != null) { XMLHelper.marshallAttribute(Request.SOAP11_MUST_UNDERSTAND_ATTR_NAME, request.isSOAP11MustUnderstandXSBoolean().toString(), domElement, false); } if (request.getSOAP11Actor() != null) { XMLHelper.marshallAttribute(Request.SOAP11_ACTOR_ATTR_NAME, request.getSOAP11Actor(), domElement, false); } }
/** {@inheritDoc} */ protected void marshallAttributes(XMLObject xmlObject, Element domElement) throws MarshallingException { Request request = (Request) xmlObject; if (request.getResponseConsumerURL() != null) { domElement.setAttributeNS(null, Request.RESPONSE_CONSUMER_URL_ATTRIB_NAME, request.getResponseConsumerURL()); } if (request.getService() != null) { domElement.setAttributeNS(null, Request.SERVICE_ATTRIB_NAME, request.getService()); } if (request.getMessageID() != null) { domElement.setAttributeNS(null, Request.MESSAGE_ID_ATTRIB_NAME, request.getMessageID()); } if (request.isSOAP11MustUnderstandXSBoolean() != null) { XMLHelper.marshallAttribute(Request.SOAP11_MUST_UNDERSTAND_ATTR_NAME, request.isSOAP11MustUnderstandXSBoolean().toString(), domElement, false); } if (request.getSOAP11Actor() != null) { XMLHelper.marshallAttribute(Request.SOAP11_ACTOR_ATTR_NAME, request.getSOAP11Actor(), domElement, false); } } }