public function importFromStream($overwrite = true) {
        $target = $this->findDestination($this->_data, $overwrite);
        $input = fopen('php://input', 'r');
        $output = fopen($target, 'w');

        $size = stream_copy_to_stream($input, $output);

        fclose($input);
        fclose($output);

        if ($size <= 0) {
            @unlink($target);

            throw new IoException('No file detected in input stream');
        }

        $this->_file = new File($target);

        return $size;
    }