Example #1
0
 /**
  * 指定された型に基づいてシーケンスの要素をフィルター処理します。
  *
  * @param \ArrayObject $source フィルター処理する要素を含むシーケンス
  * @param string $type シーケンスの要素をフィルター処理する型の名前
  *
  * @return \ArrayObject 入力シーケンスの各要素を指定された型にキャストした要素を格納するシーケンス。
  *                      キャストに失敗した要素は含まれません。
  */
 public function ofTypeOf(\ArrayObject $source, string $type) : \ArrayObject
 {
     $dst = TCollection::emptyList();
     foreach ($source->getIterator() as $key => $value) {
         is_scalar($value) === true && $dst->append(call_user_func(strtolower($type) . "val", $value));
     }
     return $dst;
 }
 /**
  * Constructor.
  * Sets up the datagrid object.
  */
 public function __construct($grid)
 {
     parent::__construct();
     $this->grid = $grid;
 }
 /**
  * Load the allowable callback post data into $_REQUEST array.
  */
 public function loadCallBackPostData()
 {
     $data = $this->getPostData();
     foreach ($data as $k => $v) {
         if ($this->posts->contains($k)) {
             $_REQUEST[$k] = $v;
         }
     }
 }
Example #4
0
 /**
  * Constructor.
  * Initializes the body container.
  */
 public function __construct($control)
 {
     parent::__construct();
     $this->control = $control;
 }
 public function __construct($list)
 {
     parent::__construct();
     $this->list = $list;
 }