Webmozart\Console\UI\Component\LabeledParagraph::__construct PHP Method

__construct() public method

Creates a new labeled paragraph.
public __construct ( string $label, string $text, integer $padding = 2, boolean $aligned = true )
$label string The label.
$text string The text.
$padding integer The padding between the text and label in number of spaces.
$aligned boolean Whether the paragraph should be aligned with the other paragraph in its alignment (if one is set).
    public function __construct($label, $text, $padding = 2, $aligned = true)
    {
        $this->label = $label;
        $this->padding = $padding;
        $this->text = $text;
        $this->aligned = $aligned;
    }