class \mpf\base\Widget

class \mpf\base\Widget

-no description found-

Attributes
private static mixed $_instances = []

-no description found-

private mixed $_vars = []

-no description found-

private \mpf\translators\Interface; $_translator

-no description found-

public string $translator = "\mpf\translators\None"

-no description found-

Methods

protected static mixed prepareForSerialize (mixed $array)

  • $array

    -no description found-

-no description found-

public static \mpf\base\Widget get (string $config)

  • $config

    -no description found-

Return instance of called class for specific config

protected mixed render (string $filePath, array $variables = [])

  • $filePath

    -no description found-

  • $variables

    -no description found-

Display a template using full path. It will also assign all variables to it.

protected mixed assign (string $name, mixed $value)

  • $name

    -no description found-

  • $value

    -no description found-

Assign value to viewer

public mixed setTranslator (string $class)

  • $class

    -no description found-

Set a new translator. Can be sent as class name or class instance;

public \mpf\interfaces\TranslatorInterface getTranslator ()

Return instance to translator

public mixed translate (mixed $text)

  • $text

    -no description found-

-no description found-