EnumModel Constructors

Namespace
Kampute.DocToolkit.Models
Assembly
  • Kampute.DocToolkit.dll
EnumModel(object, IEnumType)Initializes a new instance of the EnumModel class.
EnumModel(AssemblyModel, IEnumType)Initializes a new instance of the EnumModel class as a top-level type.
EnumModel(TypeModel, IEnumType)Initializes a new instance of the EnumModel class as a nested type.

EnumModel(object, IEnumType)

Initializes a new instance of the EnumModel class.
protected EnumModel(object declaringEntity, IEnumType type)

Parameters

declaringEntity object
The declaring entity of the type, which is either an AssemblyModel for top-level types or a TypeModel for nested types.
type IEnumType
The metadata of the type represented by this instance.

Exceptions

ArgumentNullException
Thrown when declaringEntity or type is null.
ArgumentException
Thrown when declaringEntity is not an instance of AssemblyModel or TypeModel.

EnumModel(AssemblyModel, IEnumType)

Initializes a new instance of the EnumModel class as a top-level type.
public EnumModel(AssemblyModel assembly, IEnumType type)

Parameters

assembly AssemblyModel
The assembly that contains the type.
type IEnumType
The metadata of the type represented by this instance.

Exceptions

ArgumentNullException
Thrown when assembly or type is null.
ArgumentException
Thrown when type is not a top-level type of assembly.

EnumModel(TypeModel, IEnumType)

Initializes a new instance of the EnumModel class as a nested type.
public EnumModel(TypeModel declaringType, IEnumType type)

Parameters

declaringType TypeModel
The type that declares the type.
type IEnumType
The type represented by this instance.

Exceptions

ArgumentNullException
Thrown when declaringType or type is null.
ArgumentException
Thrown when type is not directedly nested within declaringType.