public function isValid()
    {
        try {
            $this->validateName($this->name);
            $this->validateValue($this->value);
            $this->validateMaxAge($this->maxAge);
        } catch (\InvalidArgumentException $e) {
            return false;
        }

        return true;
    }
public function isValid()
    {
        try {
            $this->validateName($this->name);
            $this->validateValue($this->value);
            $this->validateMaxAge($this->maxAge);
        } catch (\InvalidArgumentException $e) {
            return false;
        }

        return true;
    }
public function isValid ( ) { try { $ this -> validateName ( $ this -> name ) ; $ this -> validateValue ( $ this -> value ) ; $ this -> validateMaxAge ( $ this -> maxAge ) ; } catch ( \ InvalidArgumentException $ e ) { return false ; } return true ; }
Validates cookie attributes.

@return bool
Validates cookie attributes .