PHP Class Newscoop\Subscription\SubscriptionFacade

Datei anzeigen Open project: sourcefabric/newscoop

Protected Properties

Property Type Description
$em Doctrine\ORM\EntityManager
$repository Newscoop\Subscription\SubscriptionRepository

Public Methods

Method Description
__construct ( EntityManager $em )
delete ( $id ) : void Delete subscription
find ( integer $id ) : Newscoop\Subscription\Subscription Find subscription by given id
findByUser ( User | integer $user ) : array Find subscriptions by user
save ( array $values, Subscription $subscription = null ) : Newscoop\Entity\Subscription Save subscription

Method Details

__construct() public method

public __construct ( EntityManager $em )
$em Doctrine\ORM\EntityManager

delete() public method

Delete subscription
public delete ( $id ) : void
return void

find() public method

Find subscription by given id
public find ( integer $id ) : Newscoop\Subscription\Subscription
$id integer
return Newscoop\Subscription\Subscription

findByUser() public method

Find subscriptions by user
public findByUser ( User | integer $user ) : array
$user Newscoop\Entity\User | integer
return array

save() public method

Save subscription
public save ( array $values, Subscription $subscription = null ) : Newscoop\Entity\Subscription
$values array
$subscription Subscription
return Newscoop\Entity\Subscription

Property Details

$em protected_oe property

protected Doctrine\ORM\EntityManager $em
return Doctrine\ORM\EntityManager

$repository protected_oe property

protected Newscoop\Subscription\SubscriptionRepository $repository
return Newscoop\Subscription\SubscriptionRepository