protected function getRelativeFilename(SplFileInfo $file)
    {
        $filename = $file->getPathname();
        $regex = sprintf('#^(%s)/(.+)#', $this->directory);
        $matches = array();

        preg_match(
            $regex,
            $filename,
            $matches
        );

        return $matches[2];
    }