Neos\Flow\Http\Cookie::setValue PHP Method

setValue() public method

Sets the value of this cookie
public setValue ( mixed $value ) : void
$value mixed The new value
return void
    public function setValue($value)
    {
        $this->value = $value;
    }

Usage Example

 /**
  * @test
  */
 public function getValueReturnsTheSetValue()
 {
     $cookie = new Cookie('foo', 'bar');
     $this->assertEquals('bar', $cookie->getValue());
     $cookie = new Cookie('foo', 'bar');
     $cookie->setValue('baz');
     $this->assertEquals('baz', $cookie->getValue());
     $cookie = new Cookie('foo', true);
     $this->assertSame(true, $cookie->getValue());
     $uri = new Uri('http://localhost');
     $cookie = new Cookie('foo', $uri);
     $this->assertSame($uri, $cookie->getValue());
 }
All Usage Examples Of Neos\Flow\Http\Cookie::setValue