From 887ac0d8e5f7a0bd11bff2ea0451ef60c654301c Mon Sep 17 00:00:00 2001 From: Faiyaz Ahmed Date: Wed, 4 Mar 2009 19:25:51 +0000 Subject: [PATCH] Added comments. --- geni/util/specdict.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/geni/util/specdict.py b/geni/util/specdict.py index 6c4eb862..2036977b 100644 --- a/geni/util/specdict.py +++ b/geni/util/specdict.py @@ -48,7 +48,12 @@ class SpecDict(dict): value = [expected(value) for value in spec_dict[plc_field]] spec[field] = value return {self.type: spec} - + +# +# fields = { geni_field: type. Could be class for nested classes, otherwise prob str} +# plc_fields = {geni_field : plc_field} +# + class IfSpecDict(SpecDict): type = 'IfSpec' fields = {'name': '', @@ -59,7 +64,7 @@ class IfSpecDict(SpecDict): 'max_rate': '', 'max_kbyte': '', 'ip_spoof': ''} - plc_fields = {'name': 'is_primary', + plc_fields = {'name': 'is_primary', # XXX needs munging to return name instead of True or False 'addr': 'ip', 'type': 'type'} -- 2.43.0