PHP 클래스 app\models\User

상속: extends yii\db\ActiveRecord, implements yii\web\IdentityInterface
파일 보기 프로젝트 열기: phanan/koel 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$casts
$guarded array The attributes that are protected from mass assign.
$hidden array The attributes excluded from the model's JSON form.
$hiddenPreferences array The preferences that we don't want to show to the client.
$table string The database table used by the model.

공개 메소드들

메소드 설명
connectedToLastfm ( ) : boolean Determine if the user is connected to Last.fm.
deletePreference ( string $key ) Delete a preference.
getLastfmSessionKeyAttribute ( ) : string | null Get the user's Last.fm session key.
getPreference ( string $key ) : string | null Get a preference item of the current user.
getPreferencesAttribute ( string $value ) : array Unserialize the user preferences back to an array before returning.
interactions ( )
playlists ( )
savePreference ( string $key, string $val ) Save a user preference.
setPreference ( $key, $val ) An alias to savePreference().
setPreferencesAttribute ( array $value ) User preferences are stored as a serialized associative array.

메소드 상세

connectedToLastfm() 공개 메소드

Determine if the user is connected to Last.fm.
public connectedToLastfm ( ) : boolean
리턴 boolean

deletePreference() 공개 메소드

Delete a preference.
public deletePreference ( string $key )
$key string

getLastfmSessionKeyAttribute() 공개 메소드

Get the user's Last.fm session key.
public getLastfmSessionKeyAttribute ( ) : string | null
리턴 string | null The key if found, or null if user isn't connected to Last.fm

getPreference() 공개 메소드

Get a preference item of the current user.
public getPreference ( string $key ) : string | null
$key string
리턴 string | null

getPreferencesAttribute() 공개 메소드

Unserialize the user preferences back to an array before returning.
public getPreferencesAttribute ( string $value ) : array
$value string
리턴 array

interactions() 공개 메소드

public interactions ( )

playlists() 공개 메소드

public playlists ( )

savePreference() 공개 메소드

Save a user preference.
public savePreference ( string $key, string $val )
$key string
$val string

setPreference() 공개 메소드

An alias to savePreference().
public setPreference ( $key, $val )
$key
$val

setPreferencesAttribute() 공개 메소드

User preferences are stored as a serialized associative array.
public setPreferencesAttribute ( array $value )
$value array

프로퍼티 상세

$casts 보호되어 있는 프로퍼티

protected $casts

$guarded 보호되어 있는 프로퍼티

The attributes that are protected from mass assign.
protected array $guarded
리턴 array

$hidden 보호되어 있는 프로퍼티

The attributes excluded from the model's JSON form.
protected array $hidden
리턴 array

$hiddenPreferences 보호되어 있는 프로퍼티

The preferences that we don't want to show to the client.
protected array $hiddenPreferences
리턴 array

$table 보호되어 있는 프로퍼티

The database table used by the model.
protected string $table
리턴 string