PHP 클래스 Backend\Core\Engine\Meta

파일 보기 프로젝트 열기: forkcms/forkcms 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$URL Url The URL-instance
$baseFieldName string The name of the field we should use to generate default-values
$callback array The callback method
$custom boolean Do we need meta custom
$data array The data, when a existing meta-record is loaded
$frm Form The form instance
$id integer The id, when an existing meta-record is loaded

공개 메소드들

메소드 설명
__construct ( Form $form, integer $metaId = null, string $baseFieldName = 'title', boolean $custom = false )
generateURL ( string $url ) : string Generate an url, using the predefined callback.
getData ( ) : array
getDescription ( ) : mixed Get the current value for the meta-description;
getDescriptionOverwrite ( ) : null | boolean Should the description overwrite the default
getId ( ) : null | integer Get the current value for the metaId;
getKeywords ( ) : mixed Get the current value for the meta-keywords;
getKeywordsOverwrite ( ) : null | boolean Should the keywords overwrite the default
getMetaEntity ( ) : Meta
getTitle ( ) : mixed Get the current value for the page title;
getTitleOverwrite ( ) : null | boolean Should the title overwrite the default
getURL ( ) : null | string Return the current value for an URL
getURLOverwrite ( ) : null | boolean Should the URL overwrite the default
save ( boolean $update = false ) : integer Saves the meta object
setURLCallback ( string $className, string $methodName, array $parameters = [] ) Set the callback to calculate an unique URL REMARK: this method has to be public and static REMARK: if you specify arguments they will be appended
validate ( ) Validates the form It checks if there is a value when a checkbox is checked

보호된 메소드들

메소드 설명
loadForm ( ) Add all element into the form
loadMeta ( integer $id ) Load a specific meta-record

메소드 상세

__construct() 공개 메소드

public __construct ( Form $form, integer $metaId = null, string $baseFieldName = 'title', boolean $custom = false )
$form Form An instance of Form, the elements will be parsed in here.
$metaId integer The metaID to load.
$baseFieldName string The field where the URL should be based on.
$custom boolean Add/show custom-meta.

generateURL() 공개 메소드

Generate an url, using the predefined callback.
사용 중단: use the generateUrl method on the meta repository
public generateURL ( string $url ) : string
$url string The base-url to start from.
리턴 string

getData() 공개 메소드

public getData ( ) : array
리턴 array

getDescription() 공개 메소드

Get the current value for the meta-description;
public getDescription ( ) : mixed
리턴 mixed

getDescriptionOverwrite() 공개 메소드

Should the description overwrite the default
public getDescriptionOverwrite ( ) : null | boolean
리턴 null | boolean

getId() 공개 메소드

Get the current value for the metaId;
public getId ( ) : null | integer
리턴 null | integer

getKeywords() 공개 메소드

Get the current value for the meta-keywords;
public getKeywords ( ) : mixed
리턴 mixed

getKeywordsOverwrite() 공개 메소드

Should the keywords overwrite the default
public getKeywordsOverwrite ( ) : null | boolean
리턴 null | boolean

getMetaEntity() 공개 메소드

public getMetaEntity ( ) : Meta
리턴 Common\Doctrine\Entity\Meta

getTitle() 공개 메소드

Get the current value for the page title;
public getTitle ( ) : mixed
리턴 mixed

getTitleOverwrite() 공개 메소드

Should the title overwrite the default
public getTitleOverwrite ( ) : null | boolean
리턴 null | boolean

getURL() 공개 메소드

Return the current value for an URL
public getURL ( ) : null | string
리턴 null | string

getURLOverwrite() 공개 메소드

Should the URL overwrite the default
public getURLOverwrite ( ) : null | boolean
리턴 null | boolean

loadForm() 보호된 메소드

Add all element into the form
protected loadForm ( )

loadMeta() 보호된 메소드

Load a specific meta-record
protected loadMeta ( integer $id )
$id integer The id of the record to load.

save() 공개 메소드

Saves the meta object
사용 중단: just use the entity for doctrine
public save ( boolean $update = false ) : integer
$update boolean Should we update the record or insert a new one.
리턴 integer

setURLCallback() 공개 메소드

Set the callback to calculate an unique URL REMARK: this method has to be public and static REMARK: if you specify arguments they will be appended
public setURLCallback ( string $className, string $methodName, array $parameters = [] )
$className string Name of the class to use.
$methodName string Name of the method to use.
$parameters array Parameters to parse, they will be passed after ours.

validate() 공개 메소드

Validates the form It checks if there is a value when a checkbox is checked
public validate ( )

프로퍼티 상세

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

The URL-instance
protected Url,Backend\Core\Engine $URL
리턴 Url

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

The name of the field we should use to generate default-values
protected string $baseFieldName
리턴 string

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

The callback method
protected array $callback
리턴 array

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

Do we need meta custom
protected bool $custom
리턴 boolean

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

The data, when a existing meta-record is loaded
protected array $data
리턴 array

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

The form instance
protected Form,Backend\Core\Engine $frm
리턴 Form

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

The id, when an existing meta-record is loaded
protected int $id
리턴 integer