コード例 #1
0
        public void GetFileInfosLimitCount()
        {
            var files = FileLinq.GetFileInfosLimited(Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments), 10);

            Assert.IsTrue(files.Count() == 10);
        }
コード例 #2
0
 public static IEnumerable <Mp3Info> GetMp3InfoLimitedWhere(string path, Func <Mp3Info, bool> predicate, int limit = 0) =>
 FileLinq.GetFileInfosLimited(path, limit, Mp3Filter)
 .Select(fileInfo => new Mp3Info(fileInfo))
 .Where(predicate);
コード例 #3
0
        public void GetFileInfosAny()
        {
            var files = FileLinq.GetFileInfosLimited(Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments));

            Assert.IsTrue(files.Any());
        }
コード例 #4
0
 public static IEnumerable <Mp3Info> GetMp3InfoLimited(string path, int limit = 0) =>
 FileLinq.GetFileInfosLimited(path, limit, Mp3Filter)
 .Select(fileInfo => new Mp3Info(fileInfo));