src/fs/Temp.php
protected static function registerEntity(entity\EntityInterface $entity)
    {
        if (count(self::$entities) === 0) {
            register_shutdown_function("sndsgd\\fs\\Temp::cleanup");
        }
        self::$entities[$entity->getPath()] = $entity;
    }
protected static function registerEntity(entity\EntityInterface $entity)
    {
        if (count(self::$entities) === 0) {
            register_shutdown_function("sndsgd\\fs\\Temp::cleanup");
        }
        self::$entities[$entity->getPath()] = $entity;
    }
Register an entity to be deleted when the script exits

@param \sndsgd\fs\entity\EntityInterface $entity