Convenient, consistent access to a sub-set of all keys.
549881
def keyspace(self, keyspace):
        
        if FORMAT_SPEC.search(keyspace):
            return KeyspacedProxy(self, keyspace)
        else:
            return KeyspacedProxy(self, self._keyspaces[keyspace])
662290
def keys(self):
        ""
        return tuple(set(self.new.keys()).union(self.old.keys()))
1005286
def cluster_get_keys_in_slots(self, slot, count, *, encoding):
        """"""
        return self.execute(b'CLUSTER', b'GETKEYSINSLOT', slot, count,
                            encoding=encoding)
165688
def iterkeys(self):
        """"""
        patterns = self.patterns
        replace = self.replace
        seen = set()
        for key in six.iterkeys(self.base):
            for pattern in patterns:
                m = pattern.match(key)
                if m:
                    ret = m.group('key') if replace else m.group()
                    if ret not in seen:
                        seen.add(ret)
                        yield ret
                    break
        for key in DictMethods.iterkeys(self):
            if key not in seen:
                yield key
875606
def all_keys(self):
        '''
        
        '''
        keys = self.list_keys()
        keys.update(self.local_keys())
        return keys
880542
def _normalized_keys(self, section, items):
        # type: (str, Iterable[Tuple[str, Any]]) -> Dict[str, Any]
        
        normalized = {}
        for name, val in items:
            key = section + "." + _normalize_name(name)
            normalized[key] = val
        return normalized
434861
def keys(self):
        """"""
        s = set()
        for config in self.__configs:
            s |= config.keys()
        return s
860466
def displayNewKey(key):
    """"""

    if key.keyring:
        gpg.keyring = key.keyring
    if key.secring:
        gpg.secring = key.secring

    # Using '--fingerprint' twice will display subkey fingerprints too:
    gpg.options = ['--fingerprint', '--fingerprint']
    keylist = gpg.list_keys(secret=True)

    # `result` is a `gnupg._parsers.ListKeys`, which is list-like, so iterate
    # over all the keys and display their info:
    for gpgkey in keylist:
        for k, v in gpgkey.items():
            log.info("%s: %s" % (k.capitalize(), v))

    return keylist
463639
def massage_keys(keys):
    """"""
    m_keys = []
    for key in keys:
        if key.startswith('keybase:'):
            m_keys.append(cryptorito.key_from_keybase(key[8:])['fingerprint'])
        else:
            m_keys.append(key)

    return m_keys
646006
def updateAllKeys(self):
        """"""
        for kf, key in zip(self.kf_list, self.sorted_key_list()):
            kf.update(key, self.dct[key])
682945
def keys(self, namespace, prefix=None, limit=None, offset=None):
        """"""
        params = [namespace]
        query = 'SELECT key FROM gauged_keys WHERE namespace = %s'
        if prefix is not None:
            query += ' AND key LIKE %s'
            params.append(prefix + '%')
        if limit is not None:
            query += ' LIMIT %s'
            params.append(limit)
        if offset is not None:
            query += ' OFFSET %s'
            params.append(offset)
        cursor = self.cursor
        cursor.execute(query, params)
        return [key for key, in cursor]
867264
def keys_at(self, x):
		
		return [key for key, segs in self.items() if x in segs]
907497
function discoverKey(arr, discoverableKeys, defaultKey) {
  if (arr.length === 0) return defaultKey;
  if (arr.length === 1) return arr[0];
  for (var i = 0; i < arr.length; i++) {
    if (discoverableKeys[arr[i]]) return arr[i];
  }
  return defaultKey;
}
1094319
def private_keys(self):
        """"""
        return dict([(a, e) for a, e in self.entries.items()
                     if isinstance(e, PrivateKeyEntry)])
177034
def all_unique(keys, axis=semantics.axis_default):
    """"""
    index = as_index(keys, axis)
    return index.groups == index.size
994257
def keys(cls, section=None):
        """"""
        section = section or cls._default_sect
        if section not in cls._conf:
            cls._load(section=section)
        return cls._conf[section].keys()
1002094
def subdict(super_dict, keys):
    
    sub_dict = {}
    valid_keys = super_dict.keys()
    for key in keys:
        if key in valid_keys:
            sub_dict[key] = super_dict[key]

    return sub_dict