コード例 #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ExperimentInfo"/> class from a similar item.
 /// </summary>
 /// <param name="pInfo">Another experiment info to copy basic information.</param>
 public ExperimentInfo(ExperimentInfo pInfo)
 {
     this.m_name = pInfo.m_name;
     this.m_author = pInfo.m_author;
     this.m_contributors = pInfo.m_contributors;
     this.m_description = pInfo.m_description;
 }
コード例 #2
0
ファイル: ExperimentInfo.cs プロジェクト: CoEST/TraceLab
        /// <summary>
        /// Initializes a new instance of the <see cref="ExperimentInfo"/> class from a similar item.
        /// </summary>
        /// <param name="pInfo">Another experiment info to copy basic information.</param>
        public ExperimentInfo (ExperimentInfo pInfo)
        {
            this.m_name = pInfo.m_name;
            this.m_author = pInfo.m_author;
            this.m_contributors = pInfo.m_contributors;
            this.m_description = pInfo.m_description;

            //Herzum Sprint 2 - Challenge TLAB-66
            this.m_isChallenge = pInfo.m_isChallenge;
            this.m_tags = pInfo.m_tags;
        }
コード例 #3
0
 public BenchmarkInfo(ExperimentInfo experimentInfo)
 {
     GuidId = experimentInfo.GuidId;
     Name = experimentInfo.Name;
     LayoutName = experimentInfo.LayoutName;
     Author = experimentInfo.Author;
     Contributors = experimentInfo.Contributors;
     Description = experimentInfo.Description;
     FilePath = experimentInfo.FilePath;
     //set default deadline
     Deadline = DateTime.Now;
 }
コード例 #4
0
        public Benchmark(ExperimentInfo experimentInfo, ComponentTemplateMetadata componentTemplate)
        {
            if (experimentInfo == null)
                throw new ArgumentNullException("benchmarkInfo");
            if (String.IsNullOrEmpty(experimentInfo.FilePath))
                throw new ArgumentException("Benchmark file path cannot be null or empty.");
            if (componentTemplate == null)
                throw new ArgumentNullException("componentTemplate");

            BenchmarkInfo = new BenchmarkInfo(experimentInfo);
            ComponentTemplate = componentTemplate;
            IsOnlineContest = false;
        }
コード例 #5
0
        internal ExperimentInfo Clone()
        {
            ExperimentInfo clone = new ExperimentInfo();

            clone.Author = Author;
            clone.Contributors = Contributors;
            clone.Description = Description;
            clone.FilePath = FilePath;
            clone.GuidId = GuidId;
            clone.Id = Id;
            clone.LayoutName = LayoutName;
            clone.Name = Name;

            return clone;
        }
コード例 #6
0
        private void DoAboutExperiment(object param)
        {
            Window parentWindow = param as Window;
            AboutExperimentDialog box = new AboutExperimentDialog(parentWindow);
            ExperimentInfo info = new ExperimentInfo(this.TopLevel.ExperimentInfo);
            box.DataContext = info;

            bool? result = box.ShowDialog();
            if (result == true)
            {
                this.TopLevel.ExperimentInfo.Name = info.Name;
                this.TopLevel.ExperimentInfo.Author = info.Author;
                this.TopLevel.ExperimentInfo.Contributors = info.Contributors;
                this.TopLevel.ExperimentInfo.Description = info.Description;
                this.TopLevel.IsModified = this.TopLevel.ExperimentInfo.IsModified;
            }
        }
コード例 #7
0
ファイル: ExperimentInfo.cs プロジェクト: CoEST/TraceLab
        // HERZUM SPRINT 2.3 TLAB-56 TLAB-57 TLAB-58 TLAB-59
        internal ExperimentInfo CloneWithNewId()
        {
            ExperimentInfo clone = new ExperimentInfo();

            clone.Author = Author;
            clone.Contributors = Contributors;
            clone.Description = Description;
            clone.FilePath = FilePath;
            clone.Id = Guid.NewGuid().ToString();
            clone.LayoutName = LayoutName;
            clone.Name = Name;
            clone.IsChallenge = IsChallenge;
            clone.ChallengePassword = ChallengePassword;
            clone.ExperimentPassword = ExperimentPassword;
            clone.ExperimentResultsUnitname = ExperimentResultsUnitname;
            clone.Deadline = Deadline;
            clone.PublishBaseline = PublishBaseline;
            clone.PublishChallenge = PublishChallenge;
            // HERZUM SPRINT 3: TLAB-86
            clone.ExperimentResultsUnittype = ExperimentResultsUnittype;
            clone.ExperimentResultsUnitvalue = ExperimentResultsUnitvalue;
            // END HERZUM SPRINT 3: TLAB-86
            return clone;
        }