It's not possible to override directory's related methods for a file.