private string GetUpdatedSectionGroupDeclarationXml(FactoryRecord factoryRecord, ConfigurationSectionGroup configSectionGroup) {
StringBuilder sb = new StringBuilder();
sb.Append('<');
sb.Append(KEYWORD_SECTIONGROUP);
sb.Append(' ');
AppendAttribute(sb, KEYWORD_SECTIONGROUP_NAME, configSectionGroup.Name);
AppendAttribute(sb, KEYWORD_SECTIONGROUP_TYPE, (configSectionGroup.Type != null) ? configSectionGroup.Type : factoryRecord.FactoryTypeName);
sb.Append('>');
return sb.ToString();
}