示例#1
0
        private IQueryable <ContentPathCacheEntry> GetEntryByPathQuery(ContentPath path)
        {
            var pathString = path.ToString();
            var pathHash   = KnuthHash.CalculateHash(pathString);

            var pathCacheEntryQuery = ContentPathCacheEntries
                                      .Where(e => e.Hash == pathHash && e.Path == pathString);

            return(pathCacheEntryQuery);
        }
示例#2
0
 private static void SetPath(ContentPathCacheEntry cacheEntry, string pathString)
 {
     cacheEntry.Path = pathString;
     cacheEntry.Hash = KnuthHash.CalculateHash(pathString);
 }