Example #1
0
 def __getitem__(self, key):
     if key not in self.all_attrs.keys():
         raise exception.PowerVMLPARAttributeNotFound(key)
     return self.all_attrs.get(key)
Example #2
0
 def __setitem__(self, key, value):
     if key not in self.all_attrs.keys():
         raise exception.PowerVMLPARAttributeNotFound(key)
     self.all_attrs[key] = value
Example #3
0
 def __delitem__(self, key):
     if key not in self.all_attrs.keys():
         raise exception.PowerVMLPARAttributeNotFound(key)
     # We set to None instead of removing the key...
     self.all_attrs[key] = None