예제 #1
0
        public void Remove(PairwiseSubModel childModel)
        {
            if (childModel == null)
            {
                throw new ArgumentNullException("childModel");
            }

            InnerList.Remove(childModel);
        }
예제 #2
0
        public void Insert(int index, PairwiseSubModel childModel)
        {
            if (childModel == null)
            {
                throw new ArgumentNullException("childModel");
            }

            InnerList.Insert(index, childModel);
        }
예제 #3
0
        public int IndexOf(PairwiseSubModel childModel)
        {
            if (childModel == null)
            {
                throw new ArgumentNullException("childModel");
            }

            return(InnerList.IndexOf(childModel));
        }
예제 #4
0
        public bool Contains(PairwiseSubModel childModel)
        {
            if (childModel == null)
            {
                throw new ArgumentNullException("childModel");
            }

            return(InnerList.Contains(childModel));
        }
예제 #5
0
        protected override void OnValidate(object value)
        {
            base.OnValidate(value);

            PairwiseSubModel childModel = value as PairwiseSubModel;

            if (childModel == null)
            {
                throw new ArgumentException("PairwiseSubModel");
            }
        }
예제 #6
0
        public override object Visit(PairwiseSubModel childModel)
        {
            if (childModel.SubModelParameters.Count <= 0)
            {
                throw new InvalidOperationException("Cluster doesn't have more than one parameter: " + childModel.SubModelParameters.Count);
            }

            string s = "{";

            foreach (PairwiseParameter pp in childModel.SubModelParameters)
            {
                s += pp.Name;
                s += context.Settings.SetValueSeparator;
            }

            s = s.Remove(s.Length - context.Settings.SetValueSeparator.Length,
                         context.Settings.SetValueSeparator.Length);
            s += "}";
            s += " @ " + childModel.SubModelOrder;
            return(GetComment(childModel) + s);
        }
예제 #7
0
 public void Add(PairwiseSubModel model)
 {
     this.submodels.Add(model);
 }
예제 #8
0
 public abstract object Visit(PairwiseSubModel childModel);