Class Password

Summary

Fully Qualified Name: Zend\Console\Prompt\Password
Extends: AbstractPrompt

Description

Methods

Name Description Defined By
__construct() Ask the user for a password Password
getConsole() Return console adapter to use when showing prompt. AbstractPrompt
getLastResponse() Return last answer to this prompt. AbstractPrompt
prompt() Create an instance of this prompt, show it and return response. AbstractPrompt
setConsole() Set console adapter to use when showing prompt. AbstractPrompt
show() Show the prompt to user and return a string. Password

Method Details

__construct()

Ask the user for a password

Parameter Name Type Description
$promptText string The
$echo bool Display

Returns:

getConsole()

Return console adapter to use when showing prompt.

Returns: \ConsoleAdapter

getLastResponse()

Return last answer to this prompt.

Returns: mixed

prompt()

Create an instance of this prompt, show it and return response.

This is a convenience method for creating statically creating prompts, i.e.:

$name = Zend\Console\Prompt\Line::prompt("Enter your name: ");

Returns: mixed

setConsole()

Set console adapter to use when showing prompt.

Parameter Name Type Description
$adapter \ConsoleAdapter

Returns:

show()

Show the prompt to user and return a string.

Returns: string

Top