Esempio n. 1
0
        /// <summary>
        /// Populates <see cref="SessionsAvailable"/> from the list of <see cref="Session"/>s available
        /// </summary>
        /// <param name="sessions">
        /// The sessions.
        /// </param>
        private void PopulateSessionsRowViewModel(IEnumerable <ISession> sessions)
        {
            foreach (var session in sessions)
            {
                this.SessionsAvailable.Add(new ModelSelectionSessionRowViewModel(session.RetrieveSiteDirectory(), session));
            }

            this.SelectedRowSession = this.SessionsAvailable.FirstOrDefault();

            var modelSelectionSessionRowViewModel = this.SelectedRowSession;

            if (modelSelectionSessionRowViewModel != null)
            {
                this.SelectedEngineeringModelSetup = modelSelectionSessionRowViewModel.EngineeringModelSetupRowViewModels.FirstOrDefault();
            }
        }
        /// <summary>
        /// Add a <see cref="EngineeringModelSetupRowViewModel"/> to the list of <see cref="EngineeringModelSetup"/>s
        /// </summary>
        /// <param name="model">The <see cref="EngineeringModelSetup"/> that is to be added</param>
        private void AddModelRowViewModel(EngineeringModelSetup model)
        {
            var row = new ModelSelectionEngineeringModelSetupRowViewModel(model, this.Session);

            this.EngineeringModelSetupRowViewModels.Add(row);
        }