Return a list of values for the given key.

        If `type` is not None, all values will be converted by calling `type`
        with the value as argument. if type() raises `ValueError`, the value
        will not appear in the result list.
431278
def getall(self, key, type=None):
        
        values = []
        for k, v in self._items:
            if k == key:
                if type is not None:
                    try:
                        values.append(type(v))
                    except ValueError:
                        pass
                else:
                    values.append(v)
        return values
406217
def maybe_cast_list(value, types):
    
    if not isinstance(value, list):
        return value

    if type(types) not in (list, tuple):
        types = (types,)

    for list_type in types:
        if issubclass(list_type, list):
            try:
                return list_type(value)
            except (TypeError, ValueError):
                pass
    return value
193516
def values_list(self, *args, **kwargs):
        
        flat = kwargs.pop('flat', False)
        assert flat is True
        assert len(args) == 1
        assert args[0] == self.model._meta.pk.name
        return self.pks
283505
def get_all_for(self, key):
        
        if not isinstance(key, _string_type):
            raise TypeError("Key needs to be a string.")
        return [self[(idx, key)] for idx in _range(self.__kcount[key])]
802644
@SuppressWarnings("rawtypes")
	public List hvals(Object key) {
		Jedis jedis = getJedis();
		try {
			List<byte[]> data = jedis.hvals(keyToBytes(key));
			return valueListFromBytesList(data);
		}
		finally {close(jedis);}
	}
426499
def value_type(value):
    
    try:
        keys = list(value.keys())
    except AttributeError:
        return "simple"
    if keys in [["lookup"], ["re_lookup"], ["interval"]]:
        return keys[0]
    raise ValueError("Type of `value` could not be determined")
271414
def values(self):
        
        return dict((k, getattr(self, k)) for k in self._keys)
199408
def values(self):
        
        logger.debug('call values')
        return [self.get(key) for key in self.keys()]
74470
def values(self) -> typing.Dict[str, str]:
        """"""
        return {k: v for k, v in self._items if v is not None}
703800
def get(expr, key, default=None):
    
    return ops.MapValueOrDefaultForKey(expr, key, default).to_expr()
744685
def get(self, key):
        

        match = self._get_match(key=key)

        if not match:
            return None

        return self._get_value_from_match(key=key, match=match)
862394
def getlist(self, key, default=[]):
        
        if key in self:
            return [node.value for node in self._map[key]]
        return default
350247
def gets(self, key):
        ""
        result_list = []
        if key in self.keys():
            result_list.append(self[key])
        for v in self.values():
            if isinstance(v, self.__class__):
                sub_res_list = v.gets(key)
                for res in sub_res_list:
                    result_list.append(res)
            elif isinstance(v, dict):
                if key in v.keys():
                    result_list.append(v[key])
        return result_list
425987
def read_val(self, key:str) -> Union[List[float],Tuple[List[float],List[float]]]:
        ""
        val = [pg[key] for pg in self.opt.param_groups[::2]]
        if is_tuple(val[0]): val = [o[0] for o in val], [o[1] for o in val]
        return val
605100
def _get_by(key, val, l):
    
    return [x for x in l if _check_value_recursively(key, val, x)]
366303
def getone(self, key):
        
        v = self.getall(key)
        if not v:
            raise KeyError('Key not found: %r' % key)
        if len(v) > 1:
            raise KeyError('Multiple values match %r: %r' % (key, v))
        return v[0]
819841
def values(self):
        
        r = []
        for key in self._safe_keys():
            try:
                r.append(self[key])
            except KeyError:
                pass
        return r