Use local classes for entries instead of reusing them -- some functions expect to find filesystemName in entries returned from native. As this is mostly  trivial change, clean up indents for one.