def __init__(self, filename=None):
        self.filename = None
        if filename:
            self.load(filename)
def serialize(self, value, display=False):
        if value is None:
            return ""
        return encode(value)