Implemented overridden equals and hash codes for TreeFileHandler subclasses