digitalmars.D.learn - listdir alternative
im trying to recursively read large folders but it seems listdir fails to get all file list. out of 2,000 files i only get 11 files. is there any other portable solution, since im writing a program which suppose to run on windows and linux.
Jan 06 2009
Reply to James,im trying to recursively read large folders but it seems listdir fails to get all file list. out of 2,000 files i only get 11 files. is there any other portable solution, since im writing a program which suppose to run on windows and linux.IIRC listdir is not recursive. It would be almost trivial however to create a recursive version that can be passed into foreach like this foreach(string path; AllFiles(rootDir)) { ///stuff } you would need to use the feature where foreach can take a (in this case) "int delegate(int delegate(string))".
Jan 06 2009