Skip to content

Commit 6959133

Browse files
committed
Add methods to retrieve configuration keys, values, and items in BaseConfig
1 parent b6a99ec commit 6959133

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

config/config/config.py

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,30 @@ def __iter__(self):
135135
"""
136136
return iter(self._config)
137137

138+
def keys(self):
139+
"""
140+
Get the configuration keys.
141+
142+
:return: Configuration keys.
143+
"""
144+
return self._config.keys()
145+
146+
def values(self):
147+
"""
148+
Get the configuration values.
149+
150+
:return: Configuration values.
151+
"""
152+
return self._config.values()
153+
154+
def items(self):
155+
"""
156+
Get the configuration items.
157+
158+
:return: Configuration items.
159+
"""
160+
return self._config.items()
161+
138162
def __len__(self) -> int:
139163
"""
140164
Get the number of configuration items.

0 commit comments

Comments
 (0)