return of uint QDir::count () const
Suppose i have one folder and inside that another two files are there ..
But when i am using uint QDir::count () const, it gives me 4 instead of 2 . the extra 2 is for “.” and “..” .i dont understand what is this “.” and “..”
Did you see the QDir explanation? [qt-project.org]
On the command prompt “.” represents the current (working) directory and “..” the parent directory.
Suppose the directory structure is as follows a->b,c and A->a then in this case if i apply the above function , then “.” represents a since it holds b and c , whereas “..” represents A which holds a . Am i right ????
Yes, those are simply some representations. There are some more explanations on how using and handling of those special cases in Qt docs e.g. relativeFilePath [qt-project.org]