public int Read(FileLink root, TableName tname, DataSet ds) { var file = root.PathCombine(tname.DatabaseName.Name, tname.ShortName); file = string.Format("{0}.{1}", file, EXT); var link = FileLink.CreateLink(file, tname.Provider.UserId, tname.Provider.Password); if (!link.Exists) throw new InvalidDataException($"table {tname.FormalName} data file \"{file}\" not exist"); link.ReadXml(ds); if (ds.Tables.Count > 0) return ds.Tables[0].Rows.Count; else return -1; }