Services/MediaService.php
public function create($context)
    {
        $providerManager = $this->providerService->getProviderManager($context);

        $media = $this->mediaManager->createMedia($context);

        $mediaProvider = $providerManager->getMediaProviderManager()->createMediaProvider();
        $mediaProvider->setMedia($media);

        return $mediaProvider;
    }
public function create($context)
    {
        $providerManager = $this->providerService->getProviderManager($context);

        $media = $this->mediaManager->createMedia($context);

        $mediaProvider = $providerManager->getMediaProviderManager()->createMediaProvider();
        $mediaProvider->setMedia($media);

        return $mediaProvider;
    }
public function create ( $ context ) { $ providerManager = $ this -> providerService -> getProviderManager ( $ context ) ; $ media = $ this -> mediaManager -> createMedia ( $ context ) ; $ mediaProvider = $ providerManager -> getMediaProviderManager ( ) -> createMediaProvider ( ) ; $ mediaProvider -> setMedia ( $ media ) ; return $ mediaProvider ; }
Create an empty instance of the MediaProvider by the context

@param $context
@return MediaProviderInterface
Create an empty instance of the MediaProvider by the context