features: add vm.features.items() function

Make it behave more like a dict.
Bu işleme şunda yer alıyor:
Marek Marczykowski-Górecki 2017-05-22 03:10:34 +02:00
ebeveyn c826378579
işleme 17ca883c7c
Veri tabanında bu imza için bilinen anahtar bulunamadı
GPG Anahtar Kimliği: 063938BA42CFA724

Dosyayı Görüntüle

@ -60,6 +60,11 @@ class Features(object):
keys = __iter__ keys = __iter__
def items(self):
'''Return iterable of pairs (feature, value)'''
for key in self:
yield key, self[key]
_NO_DEFAULT = object() _NO_DEFAULT = object()
def check_with_template(self, feature, default=_NO_DEFAULT): def check_with_template(self, feature, default=_NO_DEFAULT):