Skip to content

Commit dda293b

Browse files
committed
[data] corrected function names in docstring examples
1 parent c43b30e commit dda293b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/geocompy/data.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -122,9 +122,9 @@ def get_enum(e: type[_E], value: _E | str) -> _E:
122122
... ONE = 1
123123
... TWO = 2
124124
>>>
125-
>>> gc.data.toenum(MyEnum, 'ONE')
125+
>>> gc.data.get_enum(MyEnum, 'ONE')
126126
<MyEnum.ONE: 1>
127-
>>> gc.data.toenum(MyEnum, MyEnum.TWO)
127+
>>> gc.data.get_enum(MyEnum, MyEnum.TWO)
128128
<MyEnum.TWO: 2>
129129
"""
130130
if isinstance(value, str):
@@ -164,7 +164,7 @@ def get_enum_parser(e: type[_E]) -> Callable[[str], _E]:
164164
... ONE = 1
165165
... TWO = 2
166166
>>>
167-
>>> parser = gc.data.enumparser(MyEnum)
167+
>>> parser = gc.data.get_enum_parser(MyEnum)
168168
>>> parser('1')
169169
<MyEnum.ONE: 1>
170170

0 commit comments

Comments
 (0)