public object Get(string key, CacheGetOptions options)
            {
                Platform.CheckForNullReference(key, "key");
                Platform.CheckForNullReference(options, "options");

                return(GetInternal(key, options));
            }
			public object Get(string key, CacheGetOptions options)
			{
				Platform.CheckForNullReference(key, "key");
				Platform.CheckForNullReference(options, "options");

				return GetInternal(key, options);
			}
Beispiel #3
0
		internal object Get(string cacheId, string key, CacheGetOptions options)
		{
			Platform.CheckForNullReference(key, "key");
			Platform.CheckForNullReference(options, "options");

			var cacheKey = GetItemCacheKey(cacheId, options.Region, key);

			var obj = _cache.Get(cacheKey);
			if (obj == null)
				return null;

			var entry = (DictionaryEntry)obj;
			return key.Equals(entry.Key) ? entry.Value : null;
		}
        internal object Get(string cacheId, string key, CacheGetOptions options)
        {
            Platform.CheckForNullReference(key, "key");
            Platform.CheckForNullReference(options, "options");

            var cacheKey = GetItemCacheKey(cacheId, options.Region, key);

            var obj = _cache.Get(cacheKey);

            if (obj == null)
            {
                return(null);
            }

            var entry = (DictionaryEntry)obj;

            return(key.Equals(entry.Key) ? entry.Value : null);
        }
			public object Get(string key, CacheGetOptions options)
			{
				ValueOptionsPair value;
				return _cache.TryGetValue(key, out value) ? value.Value : null;
			}
 private object GetInternal(string key, CacheGetOptions options)
 {
     return(_logicalCache.GetRegion(options.Region).Get(key));
 }
			private object GetInternal(string key, CacheGetOptions options)
			{
				return _logicalCache.GetRegion(options.Region).Get(key);
			}