49 lines
1.8 KiB
YAML
49 lines
1.8 KiB
YAML
name: CreatesPotentiallyTranslatedStrings
|
|
class_comment: null
|
|
dependencies: []
|
|
properties:
|
|
- name: destructor
|
|
visibility: protected
|
|
comment: "# * Create a pending potentially translated string.\n# *\n# * @param \
|
|
\ string $attribute\n# * @param string|null $message\n# * @return \\Illuminate\\\
|
|
Translation\\PotentiallyTranslatedString\n# */\n# protected function pendingPotentiallyTranslatedString($attribute,\
|
|
\ $message)\n# {\n# $destructor = $message === null\n# ? fn ($message) => $this->messages[]\
|
|
\ = $message\n# : fn ($message) => $this->messages[$attribute] = $message;\n#\
|
|
\ \n# return new class($message ?? $attribute, $this->validator->getTranslator(),\
|
|
\ $destructor) extends PotentiallyTranslatedString\n# {\n# /**\n# * The callback\
|
|
\ to call when the object destructs.\n# *\n# * @var \\Closure"
|
|
methods:
|
|
- name: pendingPotentiallyTranslatedString
|
|
visibility: protected
|
|
parameters:
|
|
- name: attribute
|
|
- name: message
|
|
comment: '# * Create a pending potentially translated string.
|
|
|
|
# *
|
|
|
|
# * @param string $attribute
|
|
|
|
# * @param string|null $message
|
|
|
|
# * @return \Illuminate\Translation\PotentiallyTranslatedString'
|
|
- name: __construct
|
|
visibility: public
|
|
parameters:
|
|
- name: message
|
|
- name: translator
|
|
- name: destructor
|
|
comment: "# * The callback to call when the object destructs.\n# *\n# * @var \\\
|
|
Closure\n# */\n# protected $destructor;\n# \n# /**\n# * Create a new pending potentially\
|
|
\ translated string.\n# *\n# * @param string $message\n# * @param \\Illuminate\\\
|
|
Contracts\\Translation\\Translator $translator\n# * @param \\Closure $destructor"
|
|
- name: __destruct
|
|
visibility: public
|
|
parameters: []
|
|
comment: '# * Handle the object''s destruction.
|
|
|
|
# *
|
|
|
|
# * @return void'
|
|
traits: []
|
|
interfaces: []
|