/**
  * @param accessControl $accessControl
  */
 public function __construct(accessControl $accessControl = null)
 {
     $scope = null;
     if ($accessControl) {
         $this->accessControl = $accessControl;
         $scope = $accessControl->getScope();
     }
     parent::__construct($scope);
     $contexts = array(ContextType::PLAY, ContextType::DOWNLOAD);
     $partnerId = $accessControl ? $accessControl->getPartnerId() : kCurrentContext::$ks_partner_id;
     $partner = PartnerPeer::retrieveByPK($partnerId);
     if ($partner) {
         if ($partner->getRestrictThumbnailByKs()) {
             $contexts[] = ContextType::THUMBNAIL;
         }
         if ($partner->getShouldApplyAccessControlOnEntryMetadata()) {
             $contexts[] = ContextType::METADATA;
         }
     }
     $this->setContexts($contexts);
 }