Tim Van Wassenhove

Passionate geek, interested in Technology. Proud father of two

19 May 2008

Presenting a generic EffectivityManager

I’ve already presented a Generic Effectivity. Offcourse, managing all these effectivities (versions of data) can be handled in a generic way too. A bit of experience mixed with Patterns for things that change with time allowed me to come up with the following interface

public interface IEffectivityManager<T> : IList<ieffectivity<T>>
{
	IEffectivity<T> Add(T t, DateTime begin);
	IEffectivity<T> GetSnapshot(DateTime validityDate);
	bool TryGetSnapshot(DateTime validityDate, out IEffectivity<T> effectivity);
}

Feel free to download IEffectivityManager.txt, EffectivityManager.txt and EffectivityManagerTester.txt.