Beispiel #1
0
 /// <summary>
 /// Creates a <see cref="CacheEntry"/> from a *non-empty* array of all referenced content.
 /// The first array member is designated as the <see cref="MetadataHash"/>; the (possibly empty)
 /// remainder is used as the <see cref="ReferencedContent"/>
 /// </summary>
 public static CacheEntry FromArray(ReadOnlyArray <ContentHash> metadataAndReferencedContent, string originatingCache)
 {
     Contract.Requires(metadataAndReferencedContent.Length > 0);
     return(new CacheEntry(
                metadataAndReferencedContent[0],
                originatingCache,
                metadataAndReferencedContent.GetSubView(1)));
 }