PHP Class Newscoop\NewscoopBundle\Services\SystemPreferencesService

Mostrar archivo Open project: sourcefabric/newscoop Class Usage Examples

Protected Properties

Property Type Description
$em Doctrine\ORM\EntityManager
$preferences

Public Methods

Method Description
__construct ( EntityManager $em )
__get ( $property ) : string | null Magic function to get property value
__set ( $property, $value ) : void Magic function to set given value for given property
delete ( string $varname ) : void Delete system preference by varname
findOneBy ( string $property ) : array Find one preference by matching criteria from object Works like caching
get ( $property, $default = null ) : string Get value for given property
getAllPreferences ( ) : array Get all available preferences
set ( $property, $value ) : void Set given value for given property

Method Details

__construct() public method

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

__get() public method

Magic function to get property value
public __get ( $property ) : string | null
$property Given property
return string | null

__set() public method

Magic function to set given value for given property
public __set ( $property, $value ) : void
$property Given property
$value Value for given property
return void

delete() public method

Delete system preference by varname
public delete ( string $varname ) : void
$varname string System preference varname
return void

findOneBy() public method

Find one preference by matching criteria from object Works like caching
public findOneBy ( string $property ) : array
$property string Property name
return array

get() public method

Get value for given property
public get ( $property, $default = null ) : string
$property Given property
return string

getAllPreferences() public method

Get all available preferences
public getAllPreferences ( ) : array
return array

set() public method

Set given value for given property
public set ( $property, $value ) : void
$property Given property
$value Value for given property
return void

Property Details

$em protected_oe property

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

$preferences protected_oe property

protected $preferences