private static MockHistoryObject BuildObject( HistoryId id, IEnumerable <Tuple <byte, IStoreTimelineValues> > members, params object[] constructorArguments) { IVariableTimeline <int> someValue = null; IListTimelineStorage <int> lotsOfValues = null; foreach (var pair in members) { if (pair.Item1 == MockHistoryObject.SomeValueIndex) { someValue = pair.Item2 as IVariableTimeline <int>; continue; } if (pair.Item1 == MockHistoryObject.LotsOfValuesIndex) { lotsOfValues = pair.Item2 as IListTimelineStorage <int>; continue; } } return(new MockHistoryObject(id, someValue, lotsOfValues)); }
public MockHistoryObject(HistoryId id, IVariableTimeline <int> valueStorage, IListTimelineStorage <int> collectionStorage) { m_Id = id; m_SomeValue = valueStorage; m_LotsOfValues = collectionStorage; }