[fpc-pascal]directory tree in memory
Drslump at btopenworld.com
Mon Oct 15 02:29:59 CEST 2001
Maybe it's a bit off-topic, sorry for any incovenience.
In my library I need to have a repressentation of a directorty tree in memory, to search for files etc.
I'm using a tList like this :
pMyDirsItem = ^mydirsitem;
info :tFileInfo; //name, size, time/date ...
What I do is store the file/directory name and the like in DirsItem.info and if it's a directory "sub" points to another tList with the contents of that directory.
It works but I would like to know if someone have a better solution for this problem. I'm not very happy with the performance when I have to find a file in it.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the fpc-pascal