We have an enum in a class library:
Public Enum FieldType Phone Span Gender DrawPath .... End Enum
which we use with an attribute applied to properties, for multiple scenarios: HTML/CSV rendering, onscreen display formatting among them.
Multiple projects use this class library, and we want to use project-specific values with this enum. The class library could have extension points (e.g.
Public Shared FieldTypeAsHtml As Func(Of FieldType,String)) which specific projects could override.
Each project could have its own additional enums or constants, and the conversions would be automatic (at least in VB.NET which is what we are using; C# would require explicit conversions).
Aside from the obvious -- the intention of this enum is to be "open" and not limited to a specified set of values, therefore no compile-time safety on a given value -- is this a valid design? Are there any downsides? Since there are no partial enums in .NET, what other alternatives might be better, and why?