/** * Add a constant to an entity. * * @param ReflectionConstant $constant */ public function addConstant(ReflectionConstant $constant) { $this->constants[$constant->getShortName()] = $constant; $constant->setDeclaringClassLike($this); $constant->setFilename($this->getFileName()); return $this; }