public function __construct($aListData = null, $propertyName = null, $dataClassName = null)
{
parent::__construct();
$this->aListData = $aListData === null ? array() : (!is_array($aListData) ? $aListData instanceof self ? $aListData->getComputed() : array($aListData) : $aListData);
$this->dataClassName = $dataClassName;
$this->propertyName = $propertyName;
//It turns strings or arrays into dataClass objects and set appropriate properties.
if ($this->dataClassName != null) {
if (is_array($this->propertyName) && count($this->propertyName) == 0) {
throw new \InvalidArgumentException('Invalid propertyName argument. It must not be empty.');
}
foreach ($this->aListData as $k => $v) {
$t = $this->typeCastData($v);
if ($t !== null) {
$this->aListData[$k] = $t;
unset($t);
}
}
}
}