public ITableFactory BuildTableFactory() { ITableCommandRunner tablerunner = new TableCommandRunner(this.wrapper); IQueryProvider provider = new MapinfoQueryProvider(this.wrapper); ITableFactory tableFactory = new TableFactory(tablerunner, provider); return(tableFactory); }
public static string ToQueryString <T>(this IQueryable <T> source) { if (source.Provider is MapinfoQueryProvider) { MapinfoQueryProvider provider = source.Provider as MapinfoQueryProvider; return(provider.GetQueryString(source.Expression)); } else { throw new ArgumentOutOfRangeException("Source provider is not a Mapinfo Query Provider"); } }