public function flush($seconds = 0)
    {
        if (! (is_float($seconds) || is_int($seconds)) || $seconds < 0) {
            throw new InvalidArgumentException('Seconds must be a number greater than or equal to 0');
        }

        if (is_int($seconds)) {
            sleep($seconds);
        } else {
            usleep($seconds * 1000000);
        }

        clearstatcache();
        gc_collect_cycles();
    }
public function flush($seconds = 0)
    {
        if (! (is_float($seconds) || is_int($seconds)) || $seconds < 0) {
            throw new InvalidArgumentException('Seconds must be a number greater than or equal to 0');
        }

        if (is_int($seconds)) {
            sleep($seconds);
        } else {
            usleep($seconds * 1000000);
        }

        clearstatcache();
        gc_collect_cycles();
    }
public function flush ( $ seconds = 0 ) { if ( ! ( is_float ( $ seconds ) || is_int ( $ seconds ) ) || $ seconds < 0 ) { throw new InvalidArgumentException ( 'Seconds must be a number greater than or equal to 0' ) ; } if ( is_int ( $ seconds ) ) { sleep ( $ seconds ) ; } else { usleep ( $ seconds * 1000000 ) ; } clearstatcache ( ) ; gc_collect_cycles ( ) ; }
Try to flush current process memory.

- Delays the program execution
- Clears file status cache
- Forces collection of any existing garbage cycles


@param float|int $seconds Seconds to sleep (can be 0.5)

@throws InvalidArgumentException When $seconds is not a valid value.
Try to flush current process memory .