I am new to programming and I have a problem. I need to check whether a file is a directory or not, if yes need to do the following :
- check whether it has contents. Contents can be sub-directories or just files.
- need to do the check recursively for every file inside the parent directory
- copy each directory and file to another location, preserving the directory structure.
- Also need to copy the database entries corresponding to every file/directory to another table
along with the actual files