public void IncrementDepth(IniAttributesManager attributes) { if (depth.Count != 0 && settings.EnableDepthSectionNaming) { char delimeter = (char)settings.DefaultObjectDelimiter; attributes.sectionName = String.Format("{2}{1}{0}", attributes.sectionName, delimeter, depth.Reverse().Aggregate((i, j) => i + delimeter + j)); } }
public IniCollectionAttributesManager(IniAttributesManager attributes) : this(null, attributes) { }
public IniCollectionAttributesManager(MemberInfo member, IniAttributesManager attributes) { this.attributes = attributes; if (member != null) { this.arrayDelimiter = (IniArrayDelimiter)member.GetCustomAttributes(true).FirstOrDefault(x => x is IniArrayDelimiter); this.arrayField = (IniArrayField)member.GetCustomAttributes(true).FirstOrDefault(x => x is IniArrayField); this.arrayType = (IniArrayType)member.GetCustomAttributes(true).FirstOrDefault(x => x is IniArrayType); this.arrayMode = (arrayType == null) ? attributes.settings.DefaultArrayType : arrayType.type; } this.delimiter = (arrayDelimiter == null) ? (char)attributes.settings.DefaultArrayDelimiter : (char)arrayDelimiter.delimiter; }