Get the value of a hash field.
170759
def hget(self, key, field, *, encoding=_NOTSET):
        """"""
        return self.execute(b'HGET', key, field, encoding=encoding)
563703
def get_value(cls, object_version, key):
        """"""
        obj = cls.get(object_version, key)
        return obj.value if obj else None
1320330
def value_from_redis
      if val = Timely.redis.hget(redis_hash_key, redis_value_key)
        val = val.include?(".") ? val.to_f : val.to_i
      else
        val = value_without_caching
        Timely.redis.hset(redis_hash_key, redis_value_key, val)
      end

      val
    end
624111
public int partialHashCode(ITuple tuple, int[] fields) {
		int result = 0;
		for(int field : fields) {
			Object o = tuple.get(field);
			if(o == null) { // nulls don't account for hashcode
				continue;
			}
			int hashCode;
			if(o instanceof String) { // since String.hashCode() != Utf8.hashCode()
				HELPER_UTF8.set((String) o);
				hashCode = HELPER_UTF8.hashCode();
			} else if(o instanceof Text) {
				HELPER_UTF8.set((Text) o);
				hashCode = HELPER_UTF8.hashCode();
			} else if(o instanceof byte[]){
				hashCode = hashBytes((byte[])o,0,((byte[]) o).length);
			} else if(o instanceof ByteBuffer){
				ByteBuffer buffer = (ByteBuffer)o;
				int offset =  buffer.arrayOffset() + buffer.position();
        int length = buffer.limit() - buffer.position();
				hashCode = hashBytes(buffer.array(),offset,length);
			} else {
				hashCode = o.hashCode();
			}
			result = result * 31 + hashCode;
		}
		return result;
	}
1176283
def record_value(record, property)
      case record
        when Hash
          record.fetch(property, record[property.field])
        when Resource
          property.get!(record)
      end
    end
526946
def get_value(self):
        """"""

        if self.data_type == self.BOOLEAN_TYPE:
            return self.value_boolean
        elif self.data_type == self.NUMBER_TYPE:
            return self.value_number
        elif self.data_type == self.SSH_KEY_TYPE:
            return self.value_ssh_key.private_key_file._get_path()
        else:
            return self.value
510774
def get_vals(self, field, goids=None):
        """"""
        go2nt = self.go2nt
        if goids is None:
            goids = set(go2nt)
        return [getattr(go2nt[go], field) for go in goids]
664583
def to_hash
      result = {}

      @values.keys.each do |field_name|
        value = __send__(field_name)
        hashed_value = value.respond_to?(:to_hash_value) ? value.to_hash_value : value
        result.merge!(field_name => hashed_value)
      end

      result
    end
1031570
def hashone(self):
    ""
    rs = self.one()
    if not rs: 
      return {}
    else:
      finds = " ".join(self._find).split(' ')
      return dict(zip((x.replace('?','') for x in finds), rs))
1204284
def hash_data(obj):
    """"""
    collect = sha1()
    for text in bytes_iter(obj):
        if isinstance(text, six.text_type):
            text = text.encode('utf-8')
        collect.update(text)
    return collect.hexdigest()
1140694
def hsetnx(self, key, field, value):
        """"""
        return self.execute(b'HSETNX', key, field, value)
233384
def get_hash_for_filename(filename, hashfile_path):
    """"""
    filehash = ''
    with open(hashfile_path, 'r') as stream:
        for _cnt, line in enumerate(stream):
            if line.rstrip().endswith(filename):
                filehash = re.match(r'^[A-Za-z0-9]*', line).group(0)
                break
    if filehash:
        return filehash
    raise AttributeError("Filename %s not found in hash file" % filename)
258819
def hash(self):
        """"""
        if not hasattr(self, '_hash'):
            self._hash = conf.lib.clang_hashCursor(self)

        return self._hash
932579
private V get(K key, int hash) {
    if (hash == this.hash && key.equals(this.key)) {
      return this.value;
    }
    int bucket = bucket(hash);
    int bucketMask = 1 << bucket;
    return (mask & bucketMask) != 0 ? children[index(bucketMask)].get(key, shift(hash)) : null;
  }
1374492
function hget(key, field, req) {
  // get at db level
  var val = this.getKey(key, req);
  if(!val) return null;
  // get at hash level
  val = val.getKey(field)
  if(!val) return null;
  return val;
}
346621
@SuppressWarnings("unchecked")
  protected int hashFields(int hash, Map<FieldDescriptor, Object> map) {
    for (Map.Entry<FieldDescriptor, Object> entry : map.entrySet()) {
      FieldDescriptor field = entry.getKey();
      Object value = entry.getValue();
      hash = (37 * hash) + field.getNumber();
      if (field.getType() != FieldDescriptor.Type.ENUM){
        hash = (53 * hash) + value.hashCode();
      } else if (field.isRepeated()) {
        List<? extends EnumLite> list = (List<? extends EnumLite>) value;
        hash = (53 * hash) + hashEnumList(list);
      } else {
        hash = (53 * hash) + hashEnum((EnumLite) value);
      }
    }
    return hash;
  }
1286330
def get_value_matched_by_regex(field_name, regex_matches, string):
    """"""
    try:
        value = regex_matches.group(field_name)
        if value is not None:
            return value
    except IndexError:
        pass

    raise MissingFieldError(string, field_name)