api/laravel/Process/FakeProcessSequence.yaml
2024-09-26 02:03:21 -07:00

110 lines
3.2 KiB
YAML

name: FakeProcessSequence
class_comment: null
dependencies:
- name: ProcessResultContract
type: class
source: Illuminate\Contracts\Process\ProcessResult
- name: OutOfBoundsException
type: class
source: OutOfBoundsException
properties:
- name: processes
visibility: protected
comment: '# * The fake process results and descriptions.
# *
# * @var array'
- name: failWhenEmpty
visibility: protected
comment: '# * Indicates that invoking this sequence when it is empty should throw
an exception.
# *
# * @var bool'
- name: emptyProcess
visibility: protected
comment: '# * The response that should be returned when the sequence is empty.
# *
# * @var \Illuminate\Contracts\Process\ProcessResult|\Illuminate\Process\FakeProcessDescription'
methods:
- name: __construct
visibility: public
parameters:
- name: processes
default: '[]'
comment: "# * The fake process results and descriptions.\n# *\n# * @var array\n\
# */\n# protected $processes = [];\n# \n# /**\n# * Indicates that invoking this\
\ sequence when it is empty should throw an exception.\n# *\n# * @var bool\n#\
\ */\n# protected $failWhenEmpty = true;\n# \n# /**\n# * The response that should\
\ be returned when the sequence is empty.\n# *\n# * @var \\Illuminate\\Contracts\\\
Process\\ProcessResult|\\Illuminate\\Process\\FakeProcessDescription\n# */\n#\
\ protected $emptyProcess;\n# \n# /**\n# * Create a new fake process sequence\
\ instance.\n# *\n# * @param array $processes\n# * @return void"
- name: push
visibility: public
parameters:
- name: process
comment: '# * Push a new process result or description onto the sequence.
# *
# * @param \Illuminate\Contracts\Process\ProcessResult|\Illuminate\Process\FakeProcessDescription|array|string $process
# * @return $this'
- name: whenEmpty
visibility: public
parameters:
- name: process
comment: '# * Make the sequence return a default result when it is empty.
# *
# * @param \Illuminate\Contracts\Process\ProcessResult|\Illuminate\Process\FakeProcessDescription|array|string $process
# * @return $this'
- name: toProcessResult
visibility: protected
parameters:
- name: process
comment: '# * Convert the given result into an actual process result or description.
# *
# * @param \Illuminate\Contracts\Process\ProcessResult|\Illuminate\Process\FakeProcessDescription|array|string $process
# * @return \Illuminate\Contracts\Process\ProcessResult|\Illuminate\Process\FakeProcessDescription'
- name: dontFailWhenEmpty
visibility: public
parameters: []
comment: '# * Make the sequence return a default result when it is empty.
# *
# * @return $this'
- name: isEmpty
visibility: public
parameters: []
comment: '# * Indicate that this sequence has depleted all of its process results.
# *
# * @return bool'
- name: __invoke
visibility: public
parameters: []
comment: '# * Get the next process in the sequence.
# *
# * @return \Illuminate\Contracts\Process\ProcessResult|\Illuminate\Process\FakeProcessDescription
# *
# * @throws \OutOfBoundsException'
traits:
- OutOfBoundsException
interfaces: []