internal SLFilter Clone() { SLFilter f = new SLFilter(); f.Val = this.Val; return f; }
internal void FromFilters(Filters fs) { this.SetAllNull(); if (fs.Blank != null && fs.Blank.Value) this.Blank = fs.Blank.Value; if (fs.CalendarType != null) this.CalendarType = fs.CalendarType.Value; if (fs.HasChildren) { SLFilter f; SLDateGroupItem dgi; using (OpenXmlReader oxr = OpenXmlReader.Create(fs)) { while (oxr.Read()) { if (oxr.ElementType == typeof(Filter)) { f = new SLFilter(); f.FromFilter((Filter)oxr.LoadCurrentElement()); this.Filters.Add(f); } else if (oxr.ElementType == typeof(DateGroupItem)) { dgi = new SLDateGroupItem(); dgi.FromDateGroupItem((DateGroupItem)oxr.LoadCurrentElement()); this.DateGroupItems.Add(dgi); } } } } }
internal SLFilter Clone() { SLFilter f = new SLFilter(); f.Val = this.Val; return(f); }
internal void FromFilters(Filters fs) { this.SetAllNull(); if (fs.Blank != null && fs.Blank.Value) { this.Blank = fs.Blank.Value; } if (fs.CalendarType != null) { this.CalendarType = fs.CalendarType.Value; } if (fs.HasChildren) { SLFilter f; SLDateGroupItem dgi; using (OpenXmlReader oxr = OpenXmlReader.Create(fs)) { while (oxr.Read()) { if (oxr.ElementType == typeof(Filter)) { f = new SLFilter(); f.FromFilter((Filter)oxr.LoadCurrentElement()); this.Filters.Add(f); } else if (oxr.ElementType == typeof(DateGroupItem)) { dgi = new SLDateGroupItem(); dgi.FromDateGroupItem((DateGroupItem)oxr.LoadCurrentElement()); this.DateGroupItems.Add(dgi); } } } } }