public function __construct($directory, $host, $options = array())
{
if (!extension_loaded('ftp')) {
throw new \RuntimeException('Unable to use Gaufrette\\Adapter\\Ftp as the FTP extension is not available.');
}
$this->directory = (string) $directory;
$this->host = $host;
$this->port = isset($options['port']) ? $options['port'] : 21;
$this->username = isset($options['username']) ? $options['username'] : null;
$this->password = isset($options['password']) ? $options['password'] : null;
$this->passive = isset($options['passive']) ? $options['passive'] : false;
$this->create = isset($options['create']) ? $options['create'] : false;
$this->mode = isset($options['mode']) ? $options['mode'] : FTP_BINARY;
$this->ssl = isset($options['ssl']) ? $options['ssl'] : false;
$this->utf8 = isset($options['utf8']) ? $options['utf8'] : false;
}