/** * {@inheritdoc} */ public function visit(Entity $entity, GeneratorInterface $class) { $class->addProperties($this->generateExtensionFields($entity)); $class->addMethods($this->generateExtensionMethods($entity)); if ($entity->getDescriptor()->hasExtensionList()) { $class->setImplementedInterfaces(['\\Protobuf\\Extension']); } }
/** * {@inheritdoc} */ public function visit(Entity $entity, GeneratorInterface $class) { $class->addProperties($this->generateFields($entity)); $class->addMethods($this->generateAccessorsMethods($entity)); }