PHP Class Newscoop\WebcodeFacade

Afficher le fichier Open project: sourcefabric/newscoop

Protected Properties

Свойство Type Description
$em
$random

Méthodes publiques

Méthode Description
__construct ( EntityManager $em, Random $random )
findArticleByWebcode ( string $webcode ) : Newscoop\Entity\Article Find article by webcode
getArticleWebcode ( Article $article ) : string Get article webcode
setArticleWebcode ( Article $article, string $webcode = null ) : void Set article webcode

Private Methods

Méthode Description
generateWebcode ( ) Generate webcode
getRepository ( ) : Doctrine\ORM\EntityRepository Get webcode repository
isUnique ( string $webcode ) : boolean Test if webcode is unique

Method Details

__construct() public méthode

public __construct ( EntityManager $em, Random $random )
$em Doctrine\ORM\EntityManager
$random Random

findArticleByWebcode() public méthode

Find article by webcode
public findArticleByWebcode ( string $webcode ) : Newscoop\Entity\Article
$webcode string
Résultat Newscoop\Entity\Article

getArticleWebcode() public méthode

Get article webcode
public getArticleWebcode ( Article $article ) : string
$article Newscoop\Entity\Article
Résultat string

setArticleWebcode() public méthode

Set article webcode
public setArticleWebcode ( Article $article, string $webcode = null ) : void
$article Newscoop\Entity\Article
$webcode string
Résultat void

Property Details

$em protected_oe property

protected $em

$random protected_oe property

protected $random