marshalRecord.namespaceDeclarations(nr);
if (descriptor != null && !isNil) {
treeObjectBuilder.addXsiTypeAndClassIndicatorIfRequired(marshalRecord, descriptor, null, descriptor.getDefaultRootElementField(), root, object, isXMLRoot, true);
treeObjectBuilder.marshalAttributes(marshalRecord, object, session);
}
marshalRecord.closeStartElement();
}
if (treeObjectBuilder != null && !isNil) {