private void PrefixLevel(DataDictionary dict, string prefix, Level l) { PrefixDictObjectName(dict, prefix, l); l.IDs.Items.ForEach(i => PrefixItem(dict, prefix, i)); l.Records.ForEach(r => PrefixRecord(dict, prefix, r)); }
private string LoadLevel() { int newLevelNum = _level == null ? 1 : _level.LevelNum + 1; _level = new Level(_dictionary,newLevelNum); string line; while( ( line = ReadTrimmedLine() ) != null && !IsHeader(line) ) { string argument,value; ParseLine(line,out argument,out value); if( AssignSharedComponents(_level,argument,value) ) { } else throw new DataDictionaryReaderException(line); } _dictionary.AddLevel(_level); return line; }
public Record(Level level) { _parent = level; _items = new List<Item>(); _occurrenceLabels = new List<string>(); Required = true; MaxOccs = 1; Length = 0; RecordType = ""; }
public void AddLevel(Level level) { _levels.Add(level); }
private void SaveLevel(Level level) { _tw.WriteLine(); _tw.WriteLine(DataDictionaryElements.DICT_LEVEL); SaveSharedComponents(level); _tw.WriteLine(); _tw.WriteLine(DataDictionaryElements.DICT_IDITEMS); foreach( Item item in level.IDs.Items ) SaveItem(item); foreach( Record record in level.Records ) SaveRecord(record); }