PHP Class PartKeepr\AuthBundle\Entity\UserPreference

User preferences are a simple key => value mechanism, where the developer can specify the key and value himself. Note that values are stored internally as serialized PHP values to keep their type.
Datei anzeigen Open project: partkeepr/PartKeepr Class Usage Examples

Public Methods

Method Description
getPreferenceKey ( ) : string Returns the key of this entry.
getPreferenceValue ( ) : mixed Returns the value for this entry.
getUser ( ) : User Returns the user associated with this entry.
setPreferenceKey ( string $key ) Sets the key for this user preference.
setPreferenceValue ( mixed $value ) Sets the value for this entry.
setUser ( User $user ) Sets the user for this entry.

Method Details

getPreferenceKey() public method

Returns the key of this entry.
public getPreferenceKey ( ) : string
return string

getPreferenceValue() public method

Returns the value for this entry.
public getPreferenceValue ( ) : mixed
return mixed The value

getUser() public method

Returns the user associated with this entry.
public getUser ( ) : User
return User

setPreferenceKey() public method

Sets the key for this user preference.
public setPreferenceKey ( string $key )
$key string The key name

setPreferenceValue() public method

Sets the value for this entry.
public setPreferenceValue ( mixed $value )
$value mixed

setUser() public method

Sets the user for this entry.
public setUser ( User $user )
$user User