public static ScoringApplicationResponse CreateEmpty(IEnumerable <ScoringApplicationQuestion> questions, Project project)
        {
            var partitions  = CreatePartitions(questions);
            var projectInfo = ProjectApplicationInfoResponse.CreateFrom(project);

            return(new ScoringApplicationResponse
            {
                ProjectInfo = projectInfo,
                Partitions = partitions,
                IsSubmitted = false
            });
        }
        public static ScoringApplicationResponse InitializeFromApplication(IEnumerable <ScoringApplicationQuestion> questions, ScoringApplication application)
        {
            var partitions  = CreatePartitions(questions);
            var projectInfo = ProjectApplicationInfoResponse.CreateFrom(application);
            var blank       = new ScoringApplicationResponse
            {
                ProjectInfo = projectInfo,
                Partitions  = partitions,
                Created     = application.Created,
                Saved       = application.Saved
            };

            blank.SetAnswersFromApplication(application);
            blank.IsSubmitted = application.IsSubmitted;
            return(blank);
        }