Return a list of fields with a prop key defined

        Each list item will be a tuple of field name containing
        the prop key & the value of that prop key.

        :param prop_key: key name
        :return: list of tuples
180074
def get_fields_with_prop(cls, prop_key):
        

        ret = []

        for key, val in getattr(cls, '_fields').items():
            if hasattr(val, prop_key):
                ret.append((key, getattr(val, prop_key)))
        return ret
1351395
def pick(self, *props):
        
        result = Parameters()
        for prop in props:
            if self.contains_key(prop):
                result.put(prop, self.get(prop))
        return result
830865
def _fields_list_to_dict(fields, option_name):
    
    if isinstance(fields, collections.Mapping):
        return fields

    if isinstance(fields, collections.Sequence):
        if not all(isinstance(field, string_type) for field in fields):
            raise TypeError("%s must be a list of key names, each an "
                            "instance of %s" % (option_name,
                                                string_type.__name__))
        return dict.fromkeys(fields, 1)

    raise TypeError("%s must be a mapping or "
                    "list of key names" % (option_name,))
250478
def getall(self, key):
        
        result = []
        for k, v in self._items:
            if key == k:
                result.append(v)
        return result
1263701
def get_deploy_hosts_list(cwd, key=None, file="propel.yml"):
    
    config = propel_deploy_config(cwd=cwd, file=file)["hosts"]
    return config[key] if key else [v for k, l in config.items() for v in l]
1265090
def property_as_list(self, property_name):
        
        try:
            res = self._a_tags[property_name]
        except KeyError:
            return []

        if type(res) == list:
            return res
        else:
            return [res]
697854
def property_schema(self, key):
        
        schema = self.__class__.SCHEMA

        # first try plain properties
        plain_schema = schema.get("properties", {}).get(key)
        if plain_schema is not None:
            return plain_schema
        # then try pattern properties
        pattern_properties = schema.get("patternProperties", {})
        for pattern, pattern_schema in pattern_properties.items():
            if match(pattern, key):
                return pattern_schema
        # finally try additional properties (defaults to true per JSON Schema)
        return schema.get("additionalProperties", True)
272782
def Items(self, key):
    
    with self._mutex:
      if key not in self._buckets:
        raise KeyError('Key %s was not found in Reservoir' % key)
      bucket = self._buckets[key]
    return bucket.Items()
588426
def _get_prop_infos(self, prop):
        
        info_dict = self.get_info_field(prop)
        main_infos = info_dict.get('export', {}).copy()
        infos = main_infos.get(self.config_key, {})
        main_infos['label'] = self._get_title(prop, main_infos, info_dict)
        main_infos['name'] = prop.key
        main_infos['key'] = prop.key
        main_infos.update(infos)
        main_infos['__col__'] = prop
        return main_infos
1177427
def get_list_key(self, data, key, header_lines=2):
        
        return super(NumpydocTools, self).get_list_key(data, key, header_lines=header_lines)
846033
def get_nested_fields(schema, model_field=False):
    

    nested_fields = []
    for (key, value) in schema._declared_fields.items():
        if isinstance(value, List) and isinstance(value.container, Nested):
            nested_fields.append(key)
        elif isinstance(value, Nested):
            nested_fields.append(key)

    if model_field is True:
        nested_fields = [get_model_field(schema, key) for key in nested_fields]

    return nested_fields
706378
def get_natural_key_fields(cls):
        
        natural_key = []
        for name, rel_to in cls.get_natural_key_info():
            if not rel_to:
                natural_key.append(name)
            else:
                nested_key = rel_to.get_natural_key_fields()
                natural_key.extend([
                    name + '__' + nname
                    for nname in nested_key
                ])
        return natural_key
892990
def get_keys(self, models, key=None):
        
        return list(set(map(lambda value: value.get_attribute(key) if key else value.get_key(), models)))
883811
def _list_fields(self):
        
        opts = {'model': self.__proxy__, 'model_name': self.__name__}
        response = _turicreate.extensions._nearest_neighbors.list_fields(opts)

        return sorted(response.keys())
1038405
def _get_fields_for_model(model):
    
    fields = []
    for name in model._sa_class_manager:
        prop = getattr(model, name)
        if isinstance(prop.property, RelationshipProperty):
            for pk in prop.property.mapper.primary_key:
                fields.append('{0}.{1}'.format(name, pk.name))
        else:
            fields.append(name)
    return tuple(fields)
1272674
def get_keys(self, lst):
        
        pk_name = self.get_pk_name()
        return [getattr(item, pk_name) for item in lst]
134061
def get_field_mapping(self):
        
        fields = {}
        values = {}
        for tab in self.tabs:
            parameter_values = tab.get_parameter_value()
            fields.update(parameter_values['fields'])
            values.update(parameter_values['values'])
        return {
            'fields': fields,
            'values': values
        }