public function __construct($name, $value, $expires = null, $path = null, $domain = '', $secure = false, $httponly = true, $encodedValue = false)
{
if ($encodedValue) {
$this->value = urldecode($value);
$this->rawValue = $value;
} else {
$this->value = $value;
$this->rawValue = urlencode($value);
}
$this->name = $name;
$this->expires = null === $expires ? null : (integer) $expires;
$this->path = empty($path) ? null : $path;
$this->domain = $domain;
$this->secure = (Boolean) $secure;
$this->httponly = (Boolean) $httponly;
}