protected function determinePropertyType($method) { $comment = $method->getDocComment(); if (preg_match('/@return\\s+(.*?)\\s+/', $comment, $matches)) { return $matches[1]; } else { return '{unknown}'; } }