/// <summary> /// Handles a level. /// </summary> /// <param name="dc">User data category name</param> /// <param name="group">concept|language|term</param> private void HandleGrp(string dc, string group) { if (group != "concept" && group != "language" && group != "term") { throw (new InvalidLevelException()); } TemplateSet ts; //Handle data category with split contents and picklists if (mappingDict.HasPicklist(dc) && mappingDict.HasSplitContents(dc)) { ts = CreateTemplateSet(dc, true); (List <ValueGroup> vgs, List <Teasp> teasps) = HandleSplitContents(dc, true); ts.AddValueGroups(vgs); ts.AddSpecialTeasps(teasps); } //Handle single tbx datcat with picklists else if (mappingDict.HasPicklist(dc) && !mappingDict.HasSplitContents(dc)) { string tbx_dc = GetTBXdc(dc); ts = CreateTemplateSet(dc, tbx_dc); } //Handle data category with split contents (no picklists) else if (!mappingDict.HasPicklist(dc) && mappingDict.HasSplitContents(dc)) { ts = CreateTemplateSet(dc, true); (List <ValueGroup> vgs, List <Teasp> teasps) = HandleSplitContents(dc); ts.AddValueGroups(vgs); ts.AddSpecialTeasps(teasps); } //Handle all simple cases: no multiple tbx datcats, no picklists else { ts = CreateTemplateSet(dc); } fullMapping.CatMap[group].Add(dc, ts); }