Browse Source

[1649] added a few docstrings

Jelte Jansen 13 years ago
parent
commit
1293666c78
1 changed files with 7 additions and 1 deletions
  1. 7 1
      src/lib/python/isc/config/config_data.py

+ 7 - 1
src/lib/python/isc/config/config_data.py

@@ -28,14 +28,20 @@ class ConfigDataError(Exception): pass
 
 
 BIND10_CONFIG_DATA_VERSION = 2
 BIND10_CONFIG_DATA_VERSION = 2
 
 
-# Helper functions (should really refactor this all into classes)
+# Helper functions
 def spec_part_is_list(spec_part):
 def spec_part_is_list(spec_part):
+    """Returns True if the given spec_part is a dict that contains a
+       list specification, and False otherwise."""
     return (type(spec_part) == dict and 'list_item_spec' in spec_part)
     return (type(spec_part) == dict and 'list_item_spec' in spec_part)
 
 
 def spec_part_is_map(spec_part):
 def spec_part_is_map(spec_part):
+    """Returns True if the given spec_part is a dict that contains a
+       map specification, and False otherwise."""
     return (type(spec_part) == dict and 'map_item_spec' in spec_part)
     return (type(spec_part) == dict and 'map_item_spec' in spec_part)
 
 
 def spec_part_is_named_set(spec_part):
 def spec_part_is_named_set(spec_part):
+    """Returns True if the given spec_part is a dict that contains a
+       named_set specification, and False otherwise."""
     return (type(spec_part) == dict and 'named_map_item_spec' in spec_part)
     return (type(spec_part) == dict and 'named_map_item_spec' in spec_part)
 
 
 def check_type(spec_part, value):
 def check_type(spec_part, value):