Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[sapphire-dev] Best way to model enum

One of the schema that I'm trying to model is an element named "destination" in which the valid values are "stdout", "stderr", "jdk", "log4j", or a file name. I have modeled this element by an enum with CustomXmlValueBinding as a switch panel, with a file name. Now in a later version, a new valid value "slf4j" is introduced. What is the best way to model this change? Obviously I would like to avoid big if blocks.

Thanks,
Ling


Back to the top