MCPcopy Index your code
hub / github.com/python-visualization/folium / get_feature_id

Method get_feature_id

folium/features.py:921–926  ·  view source on GitHub ↗

Return a value identifying the feature.

(self, feature: dict)

Source from the content-addressed store, hash-verified

919 return mapping
920
921 def get_feature_id(self, feature: dict) -> Union[str, int]:
922 """Return a value identifying the feature."""
923 fields = self.feature_identifier.split(".")[1:]
924 value = functools.reduce(operator.getitem, fields, feature)
925 assert isinstance(value, (str, int))
926 return value
927
928 @staticmethod
929 def _to_key(d: dict) -> str:

Callers 1

_create_mappingMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected