PHP Interface FOF30\Render\RenderInterface

Afficher le fichier Open project: akeeba/fof

Méthodes publiques

Méthode Description
__construct ( Container $container ) Public constructor
getInformation ( ) : object Returns the information about this renderer
getOption ( string $key, mixed $default = null ) : mixed Get the value of a renderer option
isTabFieldset ( SimpleXMLElement $fieldset ) : boolean Checks if the fieldset defines a tab pane
postRender ( string $view, string $task ) : void Echoes any HTML to show after the view template
preRender ( string $view, string $task ) : void Echoes any HTML to show before the view template
renderCategoryLinkbar ( ) : void Renders the submenu (link bar) for a category view when it is used in a extension
renderFieldset ( stdClass &$fieldset, Form &$form, DataModel $model, string $formType, boolean $showHeader = true ) : string Renders a raw fieldset of a F0FForm and returns the corresponding HTML
renderFieldsetLabel ( object $field, Form &$form, string $title ) : string Renders a label for a fieldset.
renderForm ( Form &$form, DataModel $model, string $formType = null, boolean $raw = false ) : string Renders a Form and returns the corresponding HTML
renderFormBrowse ( Form &$form, DataModel $model ) : string Renders a F0FForm for a Browse view and returns the corresponding HTML
renderFormEdit ( Form &$form, DataModel $model ) : string Renders a F0FForm for an Edit view and returns the corresponding HTML
renderFormRaw ( Form &$form, DataModel $model, string $formType = null ) : string Renders a F0FForm for an Edit view and returns the corresponding HTML
renderFormRead ( Form &$form, DataModel $model ) : string Renders a F0FForm for a Read view and returns the corresponding HTML
setOption ( string $key, string $value ) : void Set a renderer option (depends on the renderer)
setOptions ( array $options ) : void Set multiple renderer options at once (depends on the renderer)

Method Details

__construct() public méthode

Public constructor
public __construct ( Container $container )
$container FOF30\Container\Container The container we are attached to

getInformation() public méthode

Returns the information about this renderer
public getInformation ( ) : object
Résultat object

getOption() public méthode

Get the value of a renderer option
public getOption ( string $key, mixed $default = null ) : mixed
$key string The name of the parameter
$default mixed The default value to return if the parameter is not set
Résultat mixed The parameter value

isTabFieldset() public méthode

Checks if the fieldset defines a tab pane
public isTabFieldset ( SimpleXMLElement $fieldset ) : boolean
$fieldset SimpleXMLElement
Résultat boolean

postRender() public méthode

Echoes any HTML to show after the view template
public postRender ( string $view, string $task ) : void
$view string The current view
$task string The current task
Résultat void

preRender() public méthode

Echoes any HTML to show before the view template
public preRender ( string $view, string $task ) : void
$view string The current view
$task string The current task
Résultat void

renderFieldset() public méthode

Renders a raw fieldset of a F0FForm and returns the corresponding HTML
public renderFieldset ( stdClass &$fieldset, Form &$form, DataModel $model, string $formType, boolean $showHeader = true ) : string
$fieldset stdClass
$form FOF30\Form\Form
$model FOF30\Model\DataModel The model providing our data
$formType string The form type e.g. 'edit' or 'read'
$showHeader boolean Should I render the fieldset's header?
Résultat string The HTML rendering of the fieldset

renderFieldsetLabel() public méthode

Renders a label for a fieldset.
public renderFieldsetLabel ( object $field, Form &$form, string $title ) : string
$field object The field of the label to render
$form FOF30\Form\Form
$title string The title of the label
Résultat string The rendered label

renderForm() public méthode

Renders a Form and returns the corresponding HTML
public renderForm ( Form &$form, DataModel $model, string $formType = null, boolean $raw = false ) : string
$form FOF30\Form\Form
$model FOF30\Model\DataModel The model providing our data
$formType string The form type: edit, browse or read
$raw boolean If true, the raw form fields rendering (without the surrounding form tag) is returned.
Résultat string The HTML rendering of the form

renderFormBrowse() public méthode

Renders a F0FForm for a Browse view and returns the corresponding HTML
public renderFormBrowse ( Form &$form, DataModel $model ) : string
$form FOF30\Form\Form
$model FOF30\Model\DataModel The model providing our data
Résultat string The HTML rendering of the form

renderFormEdit() public méthode

Renders a F0FForm for an Edit view and returns the corresponding HTML
public renderFormEdit ( Form &$form, DataModel $model ) : string
$form FOF30\Form\Form
$model FOF30\Model\DataModel The model providing our data
Résultat string The HTML rendering of the form

renderFormRaw() public méthode

Renders a F0FForm for an Edit view and returns the corresponding HTML
public renderFormRaw ( Form &$form, DataModel $model, string $formType = null ) : string
$form FOF30\Form\Form
$model FOF30\Model\DataModel The model providing our data
$formType string The form type: edit, browse or read
Résultat string The HTML rendering of the form

renderFormRead() public méthode

Renders a F0FForm for a Read view and returns the corresponding HTML
public renderFormRead ( Form &$form, DataModel $model ) : string
$form FOF30\Form\Form
$model FOF30\Model\DataModel The model providing our data
Résultat string The HTML rendering of the form

setOption() public méthode

Set a renderer option (depends on the renderer)
public setOption ( string $key, string $value ) : void
$key string The name of the option to set
$value string The value of the option
Résultat void

setOptions() public méthode

Set multiple renderer options at once (depends on the renderer)
public setOptions ( array $options ) : void
$options array The options to set as key => value pairs
Résultat void