Protobuf\WriteContext::getWriter PHP Method

getWriter() public method

public getWriter ( ) : StreamWriter
return Protobuf\Binary\StreamWriter
    public function getWriter()
    {
        return $this->writer;
    }

Usage Example

 /**
  * {@inheritdoc}
  */
 public function writeTo(\Protobuf\WriteContext $context)
 {
     $stream = $context->getStream();
     $writer = $context->getWriter();
     $sizeContext = $context->getComputeSizeContext();
     if ($this->extensions !== null) {
         $this->extensions->writeTo($context);
     }
     return $stream;
 }
All Usage Examples Of Protobuf\WriteContext::getWriter