Declaring an enum as a class member

Posted by Rire1979 on Stack Overflow See other posts from Stack Overflow or by Rire1979
Published on 2010-04-05T14:58:39Z Indexed on 2010/04/05 15:03 UTC
Read the original article Hit count: 521

Filed under:
|

Is there any mechanism in C# that allows one to define and declare an Enum variable in the same line like so:

public class ClassWithEnumMember
{
    public Enum Type { TYPE1, TYPE2, TYPE3 } = TYPE1;
}

© Stack Overflow or respective owner

Related posts about c#

Related posts about enums