* @param synapseConfig Current Synapse configuration
* @throws Exception on file I/O error
*/
public void serializeSynapseXML(SynapseConfiguration synapseConfig) throws Exception {
OMFactory fac = OMAbstractFactory.getOMFactory();
OMElement definitions = fac.createOMElement("definitions",
XMLConfigConstants.SYNAPSE_OMNAMESPACE);
if (synapseConfig.getRegistry() != null && !Boolean.valueOf(synapseConfig.getProperty(
MultiXMLConfigurationBuilder.SEPARATE_REGISTRY_DEFINITION))) {
RegistrySerializer.serializeRegistry(definitions, synapseConfig.getRegistry());