O'Reilly logo

C# in a Nutshell by Peter Drayton, Ted Neward, Ben Albahari

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Name

EnumBuilder

Synopsis

This class represents a dynamically created enumeration. Enumerations are created at module scope using the ModuleBuilder.DefineEnum() method. Before using a dynamically created enumeration, you must use the CreateType() method to complete it.

public sealed class EnumBuilder : Type {
// Public Instance Properties
   public override field Assembly Assembly{get; }               // overrides Type
   public override field string AssemblyQualifiedName{get; }    // overrides Type
   public override field Type BaseType{get; }                   // overrides Type
   public override field Type DeclaringType{get; }              // overrides Type
   public override field string FullName{get; }                 // overrides Type
   public override field Guid GUID{get; }                       // overrides Type
   public override field Module Module{get; }                   // overrides Type
   public override field string Name{get; }          // overrides System.Reflection.MemberInfo
   public override field string Namespace{get; }                // overrides Type
   public override field Type ReflectedType{get; }              // overrides Type
   public override field RuntimeTypeHandle TypeHandle{get; }    // overrides Type
   public field TypeToken TypeToken{get; } 
   public field FieldBuilder UnderlyingField{get; } 
   public override field Type UnderlyingSystemType{get; }       // overrides Type
                  // Public Instance Methods
   public method Type CreateType();  
   public method FieldBuilder DefineLiteral(
        string literalName, object literalValue);  
   public override method ConstructorInfo[] GetConstructors(   // overrides Type
        System.Reflection.BindingFlags bindingAttr ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required