original_string: public function buildAttribute(BuildAttributeEvent $event)
      {
          $attribute = $event->getAttribute();
          if (!($attribute instanceof File) || !$attribute->get('file_multiple')) {
              return;
          }
  
          $container  = $event->getContainer();
          $properties = $container->getPropertiesDefinition();
          $name       = $attribute->getColName();
          $nameSort   = \sprintf('%s__sort', $name);
  
          if ($properties->hasProperty($nameSort)) {
              $this->addAttributeToDefinition($container, $name);
              $properties->getProperty($name . '__sort')->setWidgetType('fileTreeOrder');
  
              return;
          }
  
          $properties->addProperty($property = new DefaultProperty($name . '__sort'));
          $property->setWidgetType('fileTreeOrder');
  
          $this->addAttributeToDefinition($container, $name);
      }
code: public function buildAttribute(BuildAttributeEvent $event)
      {
          $attribute = $event->getAttribute();
          if (!($attribute instanceof File) || !$attribute->get('file_multiple')) {
              return;
          }
  
          $container  = $event->getContainer();
          $properties = $container->getPropertiesDefinition();
          $name       = $attribute->getColName();
          $nameSort   = \sprintf('%s__sort', $name);
  
          if ($properties->hasProperty($nameSort)) {
              $this->addAttributeToDefinition($container, $name);
              $properties->getProperty($name . '__sort')->setWidgetType('fileTreeOrder');
  
              return;
          }
  
          $properties->addProperty($property = new DefaultProperty($name . '__sort'));
          $property->setWidgetType('fileTreeOrder');
  
          $this->addAttributeToDefinition($container, $name);
      }
code_tokens: public function buildAttribute ( BuildAttributeEvent $ event ) { $ attribute = $ event -> getAttribute ( ) ; if ( ! ( $ attribute instanceof File ) || ! $ attribute -> get ( 'file_multiple' ) ) { return ; } $ container = $ event -> getContainer ( ) ; $ properties = $ container -> getPropertiesDefinition ( ) ; $ name = $ attribute -> getColName ( ) ; $ nameSort = \ sprintf ( '%s__sort' , $ name ) ; if ( $ properties -> hasProperty ( $ nameSort ) ) { $ this -> addAttributeToDefinition ( $ container , $ name ) ; $ properties -> getProperty ( $ name . '__sort' ) -> setWidgetType ( 'fileTreeOrder' ) ; return ; } $ properties -> addProperty ( $ property = new DefaultProperty ( $ name . '__sort' ) ) ; $ property -> setWidgetType ( 'fileTreeOrder' ) ; $ this -> addAttributeToDefinition ( $ container , $ name ) ; }
docstring: This builds the dc-general property information for the virtual file order attribute.
  
  @param BuildAttributeEvent $event The event being processed.
  
  @return void
docstring_tokens: This builds the dc - general property information for the virtual file order attribute .