internal IFieldMap <T> GetRowNumberMap <T> (FieldMapBuilder <T> builder) { if (string.IsNullOrEmpty(RowNumberField)) { return(default(IFieldMap <T>)); } return(builder.FirstOrDefault(f => string.Equals(f.Caption, RowNumberField))); }
/// <summary> /// 创建一个新的 <see cref="IFieldMap{T}"/>集合 /// </summary> /// <param name="caption">列标题</param> /// <param name="propertyAccesser">属性访问表达式</param> /// <typeparam name="TValue"></typeparam> /// <returns></returns> public static FieldMapBuilder <T> Create <TValue> (string caption, Expression <Func <T, TValue> > propertyAccesser) { var builder = new FieldMapBuilder <T> (); return(builder.Add(caption, propertyAccesser)); }
public ExcelFileParser(FieldMapBuilder <T> fieldMaps, ReadSettings settings) { this._fieldMaps = fieldMaps; this._settings = settings; this.ParseResult = new ParseResult(); }
public ExcelFileParser(FieldMapBuilder <T> fieldMaps) : this(fieldMaps, new ReadSettings()) { }