NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

ModuleBuilder.DefineType

Constructs a TypeBuilder.

Overload List

Constructs a TypeBuilder given type name, its attributes, and the type that the defined type extends.

[Visual Basic] Overloads Public Function DefineType(String, TypeAttributes, Type) As TypeBuilder
[C#] public TypeBuilder DefineType(String, TypeAttributes, Type);
[C++] public: TypeBuilder* DefineType(String*, TypeAttributes, Type);
[JScript] public function DefineType(String, TypeAttributes, Type) : TypeBuilder;

Constructs a TypeBuilder given the type name, attributes, the type that the defined type extends, and the interfaces that the defined type implements.

[Visual Basic] Overloads Public Function DefineType(String, TypeAttributes, Type, Type()) As TypeBuilder
[C#] public TypeBuilder DefineType(String, TypeAttributes, Type, Type[]);
[C++] public: TypeBuilder* DefineType(String*, TypeAttributes, Type, Type[]);
[JScript] public function DefineType(String, TypeAttributes, Type, Type[]) : TypeBuilder;

Constructs a TypeBuilder for a type with the specified name.

[Visual Basic] Overloads Public Function DefineType(String) As TypeBuilder
[C#] public TypeBuilder DefineType(String);
[C++] public: TypeBuilder* DefineType(String*);
[JScript] public function DefineType(String) : TypeBuilder;

Constructs a TypeBuilder given the type name and the type attributes.

[Visual Basic] Overloads Public Function DefineType(String, TypeAttributes) As TypeBuilder
[C#] public TypeBuilder DefineType(String, TypeAttributes);
[C++] public: TypeBuilder* DefineType(String*, TypeAttributes);
[JScript] public function DefineType(String, TypeAttributes) : TypeBuilder;

Constructs a TypeBuilder given the type name, the attributes, the type that the defined type extends, and the packing size of the type.

[Visual Basic] Overloads Public Function DefineType(String, TypeAttributes, Type, PackingSize) As TypeBuilder
[C#] public TypeBuilder DefineType(String, TypeAttributes, Type, PackingSize);
[C++] public: TypeBuilder* DefineType(String*, TypeAttributes, Type, PackingSize);
[JScript] public function DefineType(String, TypeAttributes, Type, PackingSize) : TypeBuilder;

Constructs a TypeBuilder given the type name, the attributes, the type that the defined type extends, and the total size of the type.

[Visual Basic] Overloads Public Function DefineType(String, TypeAttributes, Type, Integer) As TypeBuilder
[C#] public TypeBuilder DefineType(String, TypeAttributes, Type, int);
[C++] public: TypeBuilder* DefineType(String*, TypeAttributes, Type, int);
[JScript] public function DefineType(String, TypeAttributes, Type, int) : TypeBuilder;

Constructs a TypeBuilder given the type name, attributes, the type that the defined type extends, the packing size of the defined type, and the total size of the defined type.

[Visual Basic] Overloads Public Function DefineType(String, TypeAttributes, Type, PackingSize, Integer) As TypeBuilder
[C#] public TypeBuilder DefineType(String, TypeAttributes, Type, PackingSize, int);
[C++] public: TypeBuilder* DefineType(String*, TypeAttributes, Type, PackingSize, int);
[JScript] public function DefineType(String, TypeAttributes, Type, PackingSize, int) : TypeBuilder;

Requirements

NGWS Runtime Security:

ReflectionPermission SecurityAction.Demand, ReflectionEmit

See Also

ModuleBuilder Class | ModuleBuilder Members | System.Reflection.Emit Namespace