protected function write($contents, $assetFileName)
    {
        // Derive the filename that we will be writing to
        $directory = $this->getOutputDirectory($assetFileName);

        // Build the file name
        $filename = self::getOutputFileName($assetFileName);

        // The full file path
        $fullpath = $directory.$filename;

        // Make sure that the folder exists
        if(!file_exists($directory))
        {
            // It doesn't, so make it (allow us to write)
            mkdir($directory, 0777, true);
        }

        // Write the file to disk
        file_put_contents($fullpath, $contents);

        // Return the newly created file name
        return $fullpath;
    }