/// <summary> /// It will retrive or create a new Digest for the given Uri. /// </summary> /// <param name="uri"></param> /// <returns></returns> public static Digest GetOrCreate(Uri uri) { lock (Locker) { Digest digest = null; if (!Digests.TryGetValue(uri.Host, out digest)) Digests.Add(uri.Host, digest = new Digest(uri)); return digest; } }