Make FileSystem abstract and remove query implementation