I'm using the following code to get the total number of files present at root level in a folder for Dropbox:
public int getFilesCount(@NonNull final String inPath) throws DbxException {
Log.i(LOGGER, "Getting files count for: " + inPath);
ListFolderResult result = mClient.files().listFolder(inPath);
return result.getEntries().size();
}
This code works correctly!
But looks like this code first get the list of all files present under the folder and then gets the count. This takes a significant network time. Is there any faster way to just get the total number of files instead of iterating over the directory?
Using Dropbox version 3.0.3