public void Write(BioStateTaskList taskList) { Write(taskList.InstanceVersion); Write(taskList.TaskEvals.Count); foreach (var taskEval in taskList.TaskEvals) { Write(taskEval); } }
public BioStateTaskList ReadStateTaskList() { var list = new BioStateTaskList { InstanceVersion = ReadInt32() }; var taskEvalsCount = ReadInt32(); list.TaskEvals = new List <BioTaskEval>(); for (var i = 0; i < taskEvalsCount; i++) { list.TaskEvals.Add(ReadTaskEval()); } return(list); }
/// <summary> /// </summary> /// <param name="other"></param> public BioStateTaskList(BioStateTaskList other) : base(other) { TaskEvals = other.TaskEvals != null?other.TaskEvals.Select(eval => new BioTaskEval(eval)).ToList() : new List <BioTaskEval>(); }
/// <summary> /// </summary> /// <param name="other"></param> public BioStateTaskList(BioStateTaskList other) : base(other) { TaskEvals = other.TaskEvals != null ? other.TaskEvals.Select(eval => new BioTaskEval(eval)).ToList() : new List<BioTaskEval>(); }
public void Write(BioStateTaskList taskList) { Write(taskList.InstanceVersion); Write(taskList.TaskEvals.Count); foreach (var taskEval in taskList.TaskEvals) { Write(taskEval); } }
public BioStateTaskList ReadStateTaskList() { var list = new BioStateTaskList { InstanceVersion = ReadInt32() }; var taskEvalsCount = ReadInt32(); list.TaskEvals = new List<BioTaskEval>(); for (var i = 0; i < taskEvalsCount; i++) { list.TaskEvals.Add(ReadTaskEval()); } return list; }