use Symfony\Component\Filesystem\Filesystem; $fs = new Filesystem(); $path1 = '/var/www/html/myproject'; // absolute path $path2 = '../myproject'; // relative path $isAbsolute1 = $fs->isAbsolutePath($path1); // returns true $isAbsolute2 = $fs->isAbsolutePath($path2); // returns falseIn this example, we create an instance of Filesystem and use it to check if `$path1` and `$path2` are absolute paths. `$isAbsolute1` will be true, while `$isAbsolute2` will be false. Since the class belongs to the `Symfony\Component\Filesystem` namespace, we can determine that it is part of the Symfony Filesystem component library.