public function ProjectUser(User $oUser) { if (is_array($this->m_aUserProjections)) { // Hit! return $this->m_aUserProjections; } $sExpr = $this->Get('value'); if ($sExpr == '<user>') { $sColumn = $this->Get('attribute'); if (empty($sColumn)) { $aRes = array($oUser->GetKey()); } else { $aRes = array($oUser->Get($sColumn)); } } elseif ($sExpr == '<any>' || $sExpr == '') { $aRes = null; } elseif (strtolower(substr($sExpr, 0, 6)) == 'select') { $sColumn = $this->Get('attribute'); // SELECT... $oValueSetDef = new ValueSetObjects($sExpr, $sColumn, array(), true); $aRes = $oValueSetDef->GetValues(array('user' => $oUser), ''); } else { // Constant value(s) $aRes = explode(';', trim($sExpr)); } $this->m_aUserProjections = $aRes; return $aRes; }