bool LoadConfiguration(XmlDocument document)
{
bool result = true;
XmlNodeList allSections = document.HasChildNodes ? (document.FirstChild.HasChildNodes ? document.FirstChild.ChildNodes : null) : null;
if(allSections != null)
{
foreach(XmlNode section in allSections)
{
if(result)
{
ReadBooleanSection(section, "PreloadAssemblies", ref result, ref _preloadAssemblies);
if(String.Equals(section.Name, "GCManager", StringComparison.OrdinalIgnoreCase))
{
if(!ProcessGcManager(section))
{
result = false;
}
}
if(String.Equals(section.Name, "AssemblyReferenceGroup", StringComparison.OrdinalIgnoreCase))
{
if(!ProcessAssemblyReferenceGroup(section))
{
result = false;
}
}
else if(String.Equals(section.Name, "WorkflowGroup", StringComparison.OrdinalIgnoreCase))
{
if(!ProcessWorkflowGroup(section))
{
result = false;
}
}
}
}
}
return result;
}