original_string: private function initTypeExtensions()
      {
          $this->typeExtensions = [];
  
          foreach ($this->loadTypeExtensions() as $extension) {
              if (!$extension instanceof BlockTypeExtensionInterface) {
                  throw new Exception\UnexpectedTypeException(
                      $extension,
                      'Oro\Component\Layout\BlockTypeExtensionInterface'
                  );
              }
  
              $type = $extension->getExtendedType();
  
              $this->typeExtensions[$type][] = $extension;
          }
      }
code: private function initTypeExtensions()
      {
          $this->typeExtensions = [];
  
          foreach ($this->loadTypeExtensions() as $extension) {
              if (!$extension instanceof BlockTypeExtensionInterface) {
                  throw new Exception\UnexpectedTypeException(
                      $extension,
                      'Oro\Component\Layout\BlockTypeExtensionInterface'
                  );
              }
  
              $type = $extension->getExtendedType();
  
              $this->typeExtensions[$type][] = $extension;
          }
      }
code_tokens: private function initTypeExtensions ( ) { $ this -> typeExtensions = [ ] ; foreach ( $ this -> loadTypeExtensions ( ) as $ extension ) { if ( ! $ extension instanceof BlockTypeExtensionInterface ) { throw new Exception \ UnexpectedTypeException ( $ extension , 'Oro\Component\Layout\BlockTypeExtensionInterface' ) ; } $ type = $ extension -> getExtendedType ( ) ; $ this -> typeExtensions [ $ type ] [ ] = $ extension ; } }
docstring: Initializes block type extensions.
  
  @throws Exception\UnexpectedTypeException if any registered block type extension is not
  an instance of BlockTypeExtensionInterface
docstring_tokens: Initializes block type extensions .