Checks if the specified bank contains the specified key.
546854
def contains(bank, key):
    '''
    
    '''
    redis_server = _get_redis_server()
    bank_redis_key = _get_bank_redis_key(bank)
    try:
        return redis_server.sismember(bank_redis_key, key)
    except (RedisConnectionError, RedisResponseError) as rerr:
        mesg = 'Cannot retrieve the Redis cache key {rkey}: {rerr}'.format(rkey=bank_redis_key,
                                                                           rerr=rerr)
        log.error(mesg)
        raise SaltCacheError(mesg)
79665
public boolean containsKey(final int key)
    {
        boolean found = false;
        @DoNotSub final int setNumber = Hashing.hash(key, mask);
        @DoNotSub final int setBeginIndex = setNumber << setSizeShift;

        for (@DoNotSub int i = setBeginIndex, setEndIndex = setBeginIndex + setSize; i < setEndIndex; i++)
        {
            if (null == values[i])
            {
                break;
            }

            if (key == keys[i])
            {
                found = true;
                break;
            }
        }

        return found;
    }
981735
def contains(bank, key):
    '''
    
    '''
    _init_client()
    query = "SELECT COUNT(data) FROM {0} WHERE bank='{1}' " \
        "AND etcd_key='{2}'".format(_table_name, bank, key)
    cur, _ = run_query(client, query)
    r = cur.fetchone()
    cur.close()
    return r[0] == 1
1268869
@Override
  public boolean containsKey(Object o) {
    @SuppressWarnings("unchecked")
    final K key = (K) o;
    return binarySearchInArray(key) >= 0 || overflowEntries.containsKey(key);
  }
442539
public boolean containsKey(String group, String key) {
		group = StrUtil.nullToEmpty(group).trim();
		readLock.lock();
		try {
			final LinkedHashMap<String, String> valueMap = this.get(group);
			if (MapUtil.isNotEmpty(valueMap)) {
				return valueMap.containsKey(key);
			}
		} finally {
			readLock.unlock();
		}
		return false;
	}
947707
public boolean match(SearchKey key) {
		// It will not check if the key does not have the same length
		if (ranges.length != key.length())
			return false;

		// Check one by one
		for (int i = 0; i < ranges.length; i++)
			if (!ranges[i].contains(key.get(i)))
				return false;
		return true;
	}
1315351
public synchronized boolean containsKey(Object key) {
		if(size == 0) {
			return false;
		} else {
			try {
				XAttributeMap map = deserialize();
				return map.containsKey(key);
			} catch (IOException e) {
				e.printStackTrace();
				return false;
			}
		}
	}
570153
@Override
    public boolean containsKey(T key) {
        try {
            if (emulateIsAbsent)
                lock.readLock().lock();

            return compressedEntries.containsKey(key);
        } finally {
            if (emulateIsAbsent)
                lock.readLock().unlock();
        }
    }
989869
public boolean containsKey(Object key) {
	if (key == null) {
	    throw new NullPointerException("key cannot be null");
	}
	else if (key instanceof String) {
	    Node<V> n = lookup((String)key);
	    return n != null && n.isTerminal();
	}
	else {
	    throw new ClassCastException("The provided key does not implement" +
					 " String: " + key);
	}
    }
53810
public boolean contains(final AbstractDynamoDbStore store, final StaticBuffer key, final StaticBuffer column) {
        return expectedValues.containsKey(store)
            && expectedValues.get(store).containsKey(key)
            && expectedValues.get(store).get(key).containsKey(column);
    }
614296
public static boolean containsKey(String key, int length)
    {
        if (!trie.containsKey(key)) return false;
        return key.length() >= length;
    }
843576
public boolean contains(long key) {
		if (size == 0) {
			return false;
		} 
		if (size == 1) {
			int posDiff = compare(key, rootKey);
			if (posDiff == -1) {
				return true;
			}
			return false;
		}
		Node<V> n = root;
		while (true) {
			if (!doesInfixMatch(n, key)) {
				return false;
			}			
			
			//infix matches, so now we check sub-nodes and postfixes
			if (getBit(key, n.posDiff)) {
				if (n.hi != null) {
					n = n.hi;
					continue;
				} 
				return compare(key,  n.hiPost) == -1;
			} else {
				if (n.lo != null) {
					n = n.lo;
					continue;
				}
				return compare(key,  n.loPost) == -1;
			}
			
		}
	}
1222616
public function containsKey($key): bool
    {
        return isset($this->items[$key]) || array_key_exists($key, $this->items);
    }
399720
@Override
  public boolean containsKey(Object key)
  {
    if (key == null) {
      return false;
    }

    K []keys = _keys;

    for (int i = _size - 1 ; i >= 0; i--) {
      K testKey = keys[i];

      if (key.equals(testKey)) {
        return true;
      }
    }

    return false;
  }
378084
def contains(self, key):
        
        n = binascii.crc32(key.encode()) % RING_SIZE
        for start, end in self.ranges:
            if start <= n < end:
                return True
        return False
574254
@SuppressWarnings("unchecked")
    public boolean containsKey(Object key) {
        synchronized( this ) {
            //WeakReference ref;
            SoftReference ref;
            V item;
            
            if( !cache.containsKey(key) ) {
                return false;
            }
            ref = cache.get(key);
            item = (V)ref.get();
            if( item == null ) {
                return false;
            }
            if( item instanceof CachedItem ) {
                CachedItem ci = (CachedItem)item;
                
                if( !ci.isValidForCache() ) {
                    remove(key);
                    return false;
                }
            }
            return true;
        }
    }
1064900
public final BooleanExpression containsKey(Expression<K> key) {
        return Expressions.booleanOperation(Ops.CONTAINS_KEY, mixin, key);
    }