public static IEnumerable <GridFolderView> SearchFolders(FolderTree source, string keyword, SortBy criterion) { var list = source.GetAllTrees().Where(i => IsTargetFolder(i, keyword)).Select(tree => new GridFolderView(tree)); return(SortFolders(list, keyword, criterion)); }