This gets ahold of an entity in the VFS, so that actions can be performed on it.
If the type of the entity is known in advance, then passing isDir accordingly will
help filter results faster.
The stepCallback, if specified, will be called on each item that is accessed during the recursive
search process, and the supplied AffogatoVFSEntity argument will be the current item of the search. This
is useful for performing side actions during search, such as collecing the paths of parent entities.
However, this method stops once the target entity is found. To exhaustively iterate over all subdirs and files,
use traverseBFS instead.
The method caller is responsible for ensuring that the AffogatoVFSEntity.entityId field of the
provided entity does not have any collisions. This method checks to ensure that there are no conflicting
names of files/directories in the specified location, dir, before inserting the entity.
A similar implementation to deleteEntity, except that the entity cache is not updated
and the directory specified by newDirId gets updated to contain the entity specified by entityId.