original_string: public function loadClassMetadata(LoadClassMetadataEventArgs $eventArgs)
      {
          /** @var ClassMetadata $classMetadata */
          $classMetadata = $eventArgs->getClassMetadata();
  
          if (null === $classMetadata->getReflectionClass() ||
              false == $this->isModular($classMetadata) ||
              'Harmony\Component\ModularRouting\StaticModule' == $this->getModuleClass() ||
              $classMetadata->hasField('module') || $classMetadata->hasAssociation('module')) {
  
              return;
          }
  
          $classMetadata->mapManyToOne([
              'targetEntity' => $this->getModuleClass(),
              'fieldName'    => 'module',
              'joinColumns'  => [
                  [
                      'name'                 => 'module_id',
                      'referencedColumnName' => 'id',
                  ],
              ],
          ]);
      }
code: public function loadClassMetadata(LoadClassMetadataEventArgs $eventArgs)
      {
          /** @var ClassMetadata $classMetadata */
          $classMetadata = $eventArgs->getClassMetadata();
  
          if (null === $classMetadata->getReflectionClass() ||
              false == $this->isModular($classMetadata) ||
              'Harmony\Component\ModularRouting\StaticModule' == $this->getModuleClass() ||
              $classMetadata->hasField('module') || $classMetadata->hasAssociation('module')) {
  
              return;
          }
  
          $classMetadata->mapManyToOne([
              'targetEntity' => $this->getModuleClass(),
              'fieldName'    => 'module',
              'joinColumns'  => [
                  [
                      'name'                 => 'module_id',
                      'referencedColumnName' => 'id',
                  ],
              ],
          ]);
      }
code_tokens: public function loadClassMetadata ( LoadClassMetadataEventArgs $ eventArgs ) { /** @var ClassMetadata $classMetadata */ $ classMetadata = $ eventArgs -> getClassMetadata ( ) ; if ( null === $ classMetadata -> getReflectionClass ( ) || false == $ this -> isModular ( $ classMetadata ) || 'Harmony\Component\ModularRouting\StaticModule' == $ this -> getModuleClass ( ) || $ classMetadata -> hasField ( 'module' ) || $ classMetadata -> hasAssociation ( 'module' ) ) { return ; } $ classMetadata -> mapManyToOne ( [ 'targetEntity' => $ this -> getModuleClass ( ) , 'fieldName' => 'module' , 'joinColumns' => [ [ 'name' => 'module_id' , 'referencedColumnName' => 'id' , ] , ] , ] ) ; }
docstring: Handles actions when metadata is loaded.
  
  Creates an association for entities that inherit ModularTrait.
  
  @param LoadClassMetadataEventArgs $eventArgs
docstring_tokens: Handles actions when metadata is loaded .