def serializable_property(name, docstring=None):
 def set(obj, value):
  setattr(obj, ('_' + name), value)
  obj._needs_serialization = True
 def get(obj):
  return getattr(obj, ('_' + name))
 return property(get, set, doc=docstring)

def serializable_property ( name , docstring = None ) : def set ( obj , value ) : setattr ( obj , ( '_' + name ) , value ) obj . _needs_serialization = True def get ( obj ) : return getattr ( obj , ( '_' + name ) ) return property ( get , set , doc = docstring )
a property that helps tracking whether serialization is necessary .