示例#1
0
    class Cls(properties.Owner):
        value = properties.Enum(required=True)

        def __init__(self, value=None):
            self.value = value
示例#2
0
 class Cls(properties.Owner):
     value = properties.Enum(values=("1", "2", "3"), default="2")
示例#3
0
 class Cls(properties.Owner):
     value = properties.Enum(values=(1, "2", 3.0), default="2")