elementAsString = ((PolicySetTypeString) value).getPolicySetString();
} else {
XMLObject xmlObject = (XMLObject) value;
Element element = XMLObjectHelper.marshall(xmlObject);
if (attributes != null) {
for (int i = 0; i < attributes.getLength(); i++) {
element.setAttributeNS(attributes.getURI(i), attributes.getQName(i), attributes
.getValue(i));
}
}
elementAsString = XMLObjectHelper.toString(element);
xmlObject.releaseChildrenDOM(true);
xmlObject.releaseDOM();
}
String element;
int index = elementAsString.indexOf("?>");
if (index != -1) {