src/phpDocumentor/Descriptor/Builder/Reflector/FileAssembler.php
protected function addConstants($constants, $fileDescriptor)
    {
        foreach ($constants as $constant) {
            $constantDescriptor = $this->getBuilder()->buildDescriptor($constant);
            if ($constantDescriptor) {
                $constantDescriptor->setLocation($fileDescriptor, $constant->getLineNumber());
                if (count($constantDescriptor->getTags()->get('package', new Collection())) == 0) {
                    $constantDescriptor->getTags()
                        ->set('package', $fileDescriptor->getTags()->get('package', new Collection()));
                }

                $fileDescriptor->getConstants()->set(
                    $constantDescriptor->getFullyQualifiedStructuralElementName(),
                    $constantDescriptor
                );
            }
        }
    }
protected function addConstants($constants, $fileDescriptor)
    {
        foreach ($constants as $constant) {
            $constantDescriptor = $this->getBuilder()->buildDescriptor($constant);
            if ($constantDescriptor) {
                $constantDescriptor->setLocation($fileDescriptor, $constant->getLineNumber());
                if (count($constantDescriptor->getTags()->get('package', new Collection())) == 0) {
                    $constantDescriptor->getTags()
                        ->set('package', $fileDescriptor->getTags()->get('package', new Collection()));
                }

                $fileDescriptor->getConstants()->set(
                    $constantDescriptor->getFullyQualifiedStructuralElementName(),
                    $constantDescriptor
                );
            }
        }
    }
protected function addConstants ( $ constants , $ fileDescriptor ) { foreach ( $ constants as $ constant ) { $ constantDescriptor = $ this -> getBuilder ( ) -> buildDescriptor ( $ constant ) ; if ( $ constantDescriptor ) { $ constantDescriptor -> setLocation ( $ fileDescriptor , $ constant -> getLineNumber ( ) ) ; if ( count ( $ constantDescriptor -> getTags ( ) -> get ( 'package' , new Collection ( ) ) ) == 0 ) { $ constantDescriptor -> getTags ( ) -> set ( 'package' , $ fileDescriptor -> getTags ( ) -> get ( 'package' , new Collection ( ) ) ) ; } $ fileDescriptor -> getConstants ( ) -> set ( $ constantDescriptor -> getFullyQualifiedStructuralElementName ( ) , $ constantDescriptor ) ; } } }
Registers the child constants with the generated File Descriptor.

@param ConstantReflector[] $constants
@param FileDescriptor      $fileDescriptor

@return void
Registers the child constants with the generated File Descriptor .