@Override public Boolean hExists(byte[] key, byte[] field) { Assert.notNull(key, "Key must not be null!"); Assert.notNull(field, "Field must not be null!"); try { return connection.getCluster().hexists(key, field); } catch (Exception ex) { throw convertJedisAccessException(ex); } }
/** * 查看哈希表 key 中,给定域 field 是否存在 * @param key * @param field * @return 如果哈希表含有给定域,返回 1,如果哈希表不含有给定域,或 key 不存在,返回 0 */ public Boolean hexists(String key,String field){ return jedisCluster.hexists(key, field); } /**
@Override public Boolean hexists(byte[] bytes, byte[] bytes1) { return cluster.hexists(bytes, bytes1); }
public Boolean hexists(String key, String field) { return jedisCluster.hexists(key, field); }
public Boolean hexists(byte[] key, byte[] field) { return jedisCluster.hexists(key, field); }
@Override public Boolean hExists(byte[] key, byte[] field) { Assert.notNull(key, "Key must not be null!"); Assert.notNull(field, "Field must not be null!"); try { return connection.getCluster().hexists(key, field); } catch (Exception ex) { throw convertJedisAccessException(ex); } }
@Override public Boolean hExists(byte[] key, byte[] field) { Assert.notNull(key, "Key must not be null!"); Assert.notNull(field, "Field must not be null!"); try { return connection.getCluster().hexists(key, field); } catch (Exception ex) { throw convertJedisAccessException(ex); } }
/** * 查看哈希表 key 中,给定域 field 是否存在。 */ public boolean hexists(Object key, Object field) { return jedisCluster.hexists(keyToBytes(key), valueToBytes(field)); }
@Override public boolean hexists(final String key, final String field) { Assert.hasText(key); Assert.hasText(field); try { return cluster.hexists(key, field); } catch (final Throwable e) { throw new RedisClientException(e.getMessage(), e); } }
/** * 判断哈希表 key 中,指定 field 是否存在。 */ public boolean hexists(Object key, Object field) { if (null == key || null == field) { return false; } if (cluster) { return jedisCluster.hexists(serializeKey(key), serializeKey(field)); } else { return jedisOperator.hexists(serializeKey(key), serializeKey(field)); } }