There seems to be a bug in classpathx MBOX handling.
If you pass into the store the URL of the actual MBOX file, then call
getDefaultFolder(), it is named "" empty string, which is correct.
However when you pass this into the store as store.getFolder("") it
passes it to MboxFolder() and then it calls store.getMailRootDir(). In
this function it has the commentary:
// If the url used to contruct the store references a file directly,
// return this file.
However this is not true, because it has the code:
if (!f.isDirectory())
{
f = f.getParentFile();
}
This means the commentary is wrong, and getFolder("") will not return
the default folder, but rather it tries to open the directory and gives
an error.
It seems to me the above lines should be removed. If somebody wants to
treat a directory as a collection of folders, they will pass the
directory in as the URL, and the above code will be unnecessary. And
the
code as it is, is no good because
store.getFolder(store.getDefaultFolder.getFullName()) causes an error
when dealing with the actual MBOX file.