126 lines
3.7 KiB
YAML
126 lines
3.7 KiB
YAML
|
name: CompletionInput
|
||
|
class_comment: null
|
||
|
dependencies:
|
||
|
- name: RuntimeException
|
||
|
type: class
|
||
|
source: Symfony\Component\Console\Exception\RuntimeException
|
||
|
- name: ArgvInput
|
||
|
type: class
|
||
|
source: Symfony\Component\Console\Input\ArgvInput
|
||
|
- name: InputDefinition
|
||
|
type: class
|
||
|
source: Symfony\Component\Console\Input\InputDefinition
|
||
|
- name: InputOption
|
||
|
type: class
|
||
|
source: Symfony\Component\Console\Input\InputOption
|
||
|
properties: []
|
||
|
methods:
|
||
|
- name: fromString
|
||
|
visibility: public
|
||
|
parameters:
|
||
|
- name: inputStr
|
||
|
- name: currentIndex
|
||
|
comment: "# * An input specialized for shell completion.\n# *\n# * This input allows\
|
||
|
\ unfinished option names or values and exposes what kind of\n# * completion is\
|
||
|
\ expected.\n# *\n# * @author Wouter de Jong <wouter@wouterj.nl>\n# */\n# final\
|
||
|
\ class CompletionInput extends ArgvInput\n# {\n# public const TYPE_ARGUMENT_VALUE\
|
||
|
\ = 'argument_value';\n# public const TYPE_OPTION_VALUE = 'option_value';\n# public\
|
||
|
\ const TYPE_OPTION_NAME = 'option_name';\n# public const TYPE_NONE = 'none';\n\
|
||
|
# \n# private array $tokens;\n# private int $currentIndex;\n# private string $completionType;\n\
|
||
|
# private ?string $completionName = null;\n# private string $completionValue =\
|
||
|
\ '';\n# \n# /**\n# * Converts a terminal string into tokens.\n# *\n# * This is\
|
||
|
\ required for shell completions without COMP_WORDS support."
|
||
|
- name: fromTokens
|
||
|
visibility: public
|
||
|
parameters:
|
||
|
- name: tokens
|
||
|
- name: currentIndex
|
||
|
comment: '# * Create an input based on an COMP_WORDS token list.
|
||
|
|
||
|
# *
|
||
|
|
||
|
# * @param string[] $tokens the set of split tokens (e.g. COMP_WORDS or
|
||
|
argv)
|
||
|
|
||
|
# * @param int $currentIndex the index of the cursor (e.g. COMP_CWORD)'
|
||
|
- name: bind
|
||
|
visibility: public
|
||
|
parameters:
|
||
|
- name: definition
|
||
|
comment: null
|
||
|
- name: getCompletionType
|
||
|
visibility: public
|
||
|
parameters: []
|
||
|
comment: '# * Returns the type of completion required.
|
||
|
|
||
|
# *
|
||
|
|
||
|
# * TYPE_ARGUMENT_VALUE when completing the value of an input argument
|
||
|
|
||
|
# * TYPE_OPTION_VALUE when completing the value of an input option
|
||
|
|
||
|
# * TYPE_OPTION_NAME when completing the name of an input option
|
||
|
|
||
|
# * TYPE_NONE when nothing should be completed
|
||
|
|
||
|
# *
|
||
|
|
||
|
# * TYPE_OPTION_NAME and TYPE_NONE are already implemented by the Console component.
|
||
|
|
||
|
# *
|
||
|
|
||
|
# * @return self::TYPE_*'
|
||
|
- name: getCompletionName
|
||
|
visibility: public
|
||
|
parameters: []
|
||
|
comment: '# * The name of the input option or argument when completing a value.
|
||
|
|
||
|
# *
|
||
|
|
||
|
# * @return string|null returns null when completing an option name'
|
||
|
- name: getCompletionValue
|
||
|
visibility: public
|
||
|
parameters: []
|
||
|
comment: '# * The value already typed by the user (or empty string).'
|
||
|
- name: mustSuggestOptionValuesFor
|
||
|
visibility: public
|
||
|
parameters:
|
||
|
- name: optionName
|
||
|
comment: null
|
||
|
- name: mustSuggestArgumentValuesFor
|
||
|
visibility: public
|
||
|
parameters:
|
||
|
- name: argumentName
|
||
|
comment: null
|
||
|
- name: parseToken
|
||
|
visibility: protected
|
||
|
parameters:
|
||
|
- name: token
|
||
|
- name: parseOptions
|
||
|
comment: null
|
||
|
- name: getOptionFromToken
|
||
|
visibility: private
|
||
|
parameters:
|
||
|
- name: optionToken
|
||
|
comment: null
|
||
|
- name: getRelevantToken
|
||
|
visibility: private
|
||
|
parameters: []
|
||
|
comment: '# * The token of the cursor, or the last token if the cursor is at the
|
||
|
end of the input.'
|
||
|
- name: isCursorFree
|
||
|
visibility: private
|
||
|
parameters: []
|
||
|
comment: '# * Whether the cursor is "free" (i.e. at the end of the input preceded
|
||
|
by a space).'
|
||
|
- name: __toString
|
||
|
visibility: public
|
||
|
parameters: []
|
||
|
comment: null
|
||
|
traits:
|
||
|
- Symfony\Component\Console\Exception\RuntimeException
|
||
|
- Symfony\Component\Console\Input\ArgvInput
|
||
|
- Symfony\Component\Console\Input\InputDefinition
|
||
|
- Symfony\Component\Console\Input\InputOption
|
||
|
interfaces: []
|