MCPcopy Create free account
hub / github.com/NCAR/wrf-python / viewkeys

Function viewkeys

src/wrf/py3compat.py:26–41  ·  view source on GitHub ↗

Return either the keys or viewkeys method for a dictionary. Args: d (:obj:`dict`): A dictionary. Returns: view method: Either the keys or viewkeys method.

(d)

Source from the content-addressed store, hash-verified

24
25
26def viewkeys(d):
27 """Return either the keys or viewkeys method for a dictionary.
28
29 Args:
30
31 d (:obj:`dict`): A dictionary.
32
33 Returns:
34
35 view method: Either the keys or viewkeys method.
36
37 """
38 func = getattr(d, "viewkeys", None)
39 if func is None:
40 func = d.keys
41 return func()
42
43
44def viewvalues(d):

Callers 13

_llxy_mappingFunction · 0.85
_get_proj_paramsFunction · 0.85
_set_cross_metaFunction · 0.85
_set_line_metaFunction · 0.85
_check_kargsFunction · 0.85
latlon_coordvarsFunction · 0.85
__call__Method · 0.85
is_moving_domainFunction · 0.85
extract_global_attrsFunction · 0.85
extract_dimFunction · 0.85
_combine_dictFunction · 0.85
_get_coord_namesFunction · 0.85

Calls 1

funcFunction · 0.70

Tested by

no test coverage detected