C#: What’s with Enums anyways?

c#snow1

Well, I’ll tell you.  You can define your own strings with Enums using reflection.  You can also use the type-safe-enum pattern if reflection seems slow to you.  And do you know you can use Enums to represent bit flags?

Associating Enums with strings in C# shows you how to define your own strings with Enums using reflection.  For type-safe-enum pattern implementation, check it out hereThe ins and outs of C# enums shows you how to use Enums to represent bit flags.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s