Question::__construct PHP 메소드

__construct() 공개 메소드

public __construct ( Strategy $strategy )
$strategy Strategy
    public function __construct(Strategy $strategy)
    {
        $this->_strategy = $strategy;
    }

Usage Example

예제 #1
0
파일: Choice.php 프로젝트: Lofanmi/think
 /**
  * 构造方法
  * @param string $question 问题
  * @param array  $choices  选项
  * @param mixed  $default  默认答案
  */
 public function __construct($question, array $choices, $default = null)
 {
     parent::__construct($question, $default);
     $this->choices = $choices;
     $this->setValidator($this->getDefaultValidator());
     $this->setAutocompleterValues($choices);
 }
All Usage Examples Of Question::__construct