Prado\Web\UI\WebControls\TReadOnlyDataSourceView::__construct PHP 메소드

__construct() 공개 메소드

public __construct ( Prado\Web\UI\WebControls\IDataSource $owner, $viewName, $dataSource )
$owner Prado\Web\UI\WebControls\IDataSource
    public function __construct(IDataSource $owner, $viewName, $dataSource)
    {
        parent::__construct($owner, $viewName);
        if ($dataSource === null || is_array($dataSource)) {
            $this->_dataSource = new TMap($dataSource);
        } else {
            if ($dataSource instanceof \Traversable) {
                $this->_dataSource = $dataSource;
            } else {
                throw new TInvalidDataTypeException('readonlydatasourceview_datasource_invalid');
            }
        }
    }
TReadOnlyDataSourceView