(PECL yar >= 1.1.0)
Yar_Client::getOpt — Read a client option
Returns the value previously set with
Yar_Client::setOpt(), or with the
options parameter of
Yar_Client::__construct().
name
One of the YAR_OPT_* constants, see
Yar_Client::setOpt().
The option value, or false if the option has not been set on this
client or the option name is unknown.
Örnek 1 Yar_Client::getOpt() example
<?php
$client = new Yar_Client("http://host/api/");
$client->setOpt(YAR_OPT_TIMEOUT, 1000);
var_dump($client->getOpt(YAR_OPT_TIMEOUT));
var_dump($client->getOpt(YAR_OPT_PACKAGER));
?>Yukarıdaki örnek şuna benzer bir çıktı üretir:
int(1000) bool(false)