# solid-performance/1.9.0/src/Performance/Filesystem/Exceptions/IOException.php

Solid Performance – Your No-Code Caching, Performance, &amp; Page Speed Solution, version 1.9.0. 50 lines.

- Page: https://pluginprobe.com/plugins/solid-performance/1.9.0/code/src/Performance/Filesystem/Exceptions/IOException.php
- Raw: https://pluginprobe.com/plugins/solid-performance/1.9.0/raw/src/Performance/Filesystem/Exceptions/IOException.php
- Modified: 2025-05-09T15:04:50+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/solid-performance/1.9.0/code/src/Performance/Filesystem/Exceptions/IOException.php#L10-L20`.

```php
<?php
/**
 * Exception thrown when a filesystem operation fails.
 *
 * @package SolidWP\Performance
 */

declare( strict_types=1 );

namespace SolidWP\Performance\Filesystem\Exceptions;

use RuntimeException;
use Throwable;

/**
 * Exception thrown when a filesystem operation fails.
 *
 * @package SolidWP\Performance
 */
final class IOException extends RuntimeException {

	/**
	 * The file path.
	 *
	 * @var string|null
	 */
	private ?string $path;

	/**
	 * @param string         $message The exception message.
	 * @param int            $code The error code.
	 * @param Throwable|null $previous The previous exception interface.
	 * @param string|null    $path The file path.
	 */
	public function __construct( string $message, int $code = 0, ?Throwable $previous = null, ?string $path = null ) {
		$this->path = $path;

		parent::__construct( $message, $code, $previous );
	}

	/**
	 * Get the file path associated with exception.
	 *
	 * @return string|null
	 */
	public function get_path(): ?string {
		return $this->path;
	}
}

```
