示例#1
0
 /**
  * Получить тип контента по url
  *
  * @param string $sUrl
  *
  * @return ModuleTopic_EntityContentType|null
  */
 public function GetContentTypeByUrl($sUrl)
 {
     if (false === ($data = E::ModuleCache()->Get("content_type_{$sUrl}"))) {
         $data = $this->oMapper->getContentTypeByUrl($sUrl);
         E::ModuleCache()->Set($data, "content_type_{$sUrl}", array('content_update', 'content_new'), 'P1D');
     }
     return $data;
 }