public static function getApplicationFromSession(array $sessionData, $term, Student $student, $applicationType) { $context = new CommandContext(); $context->clearParams(); $context->setParams($sessionData); return ContextApplicationFactory::getApplicationFromContext($context, $term, $student, $applicationType); }