Doctrine\OXM\Tools\XmlEntityGenerator::setGenerateAnnotations PHP Method

setGenerateAnnotations() public method

Set whether or not to generate annotations for the xml-entity
public setGenerateAnnotations ( boolean $bool ) : void
$bool boolean
return void
    public function setGenerateAnnotations($bool)
    {
        $this->generateAnnotations = $bool;
    }

Usage Example

 protected function getXmlEntityGenerator()
 {
     $xmlEntityGenerator = new XmlEntityGenerator();
     $xmlEntityGenerator->setGenerateAnnotations(false);
     $xmlEntityGenerator->setGenerateStubMethods(true);
     $xmlEntityGenerator->setRegenerateXmlEntityIfExists(false);
     $xmlEntityGenerator->setUpdateXmlEntityIfExists(true);
     $xmlEntityGenerator->setNumSpaces(4);
     return $xmlEntityGenerator;
 }