I know it is possible to declare 3 level enums in style of A.B.C
using B as interface and finally C as enum member which implements this interface.
But I'd like to nest several enums to map constant tree structure with fixed number of members. And of course something like Tree.A.Leaf.B.Node.C.Something.D
or simple A.B.C.D
looks nice.
Is it possible? Cannot find any way to implement it.
Thank you.
UPDATE (resulting solution):
- Enums are really bad for this case, thank for everyone convincing me.
- Finally I've build solution based on static classes with private constructors and static fields.
Example code is placed as my own answer to keep question clear. Hope this will help somebody else.