7 instantiations of TypeBuilder
mscorlib (7)
system\reflection\emit\enumbuilder.cs (1)
413
m_typeBuilder = new
TypeBuilder
(name, visibility | TypeAttributes.Sealed, typeof(System.Enum), null, module, PackingSize.Unspecified, TypeBuilder.UnspecifiedTypeSize, null);
system\reflection\emit\methodbuilder.cs (1)
717
m_inst[i] = new GenericTypeParameterBuilder(new
TypeBuilder
(names[i], i, this));
system\reflection\emit\modulebuilder.cs (2)
1219
return new
TypeBuilder
(name, attr, parent, interfaces, this, packingSize, typesize, null); ;
1242
return new
TypeBuilder
(name, attr, parent, null, this, packsize, TypeBuilder.UnspecifiedTypeSize, null);
system\reflection\emit\modulebuilderdata.cs (1)
31
m_globalTypeBuilder = new
TypeBuilder
(module);
system\reflection\emit\typebuilder.cs (2)
1590
m_inst[i] = new GenericTypeParameterBuilder(new
TypeBuilder
(names[i], i, this));
2035
return new
TypeBuilder
(name, attr, parent, interfaces, m_module, packSize, typeSize, this);
208 references to TypeBuilder
mscorlib (152)
system\activator.cs (1)
77
if (type is System.Reflection.Emit.
TypeBuilder
)
system\reflection\emit\assemblybuilder.cs (4)
1674
TypeBuilder
.DefineCustomAttribute(
1779
TypeBuilder
typeBuilder;
1985
typeBuilder = (
TypeBuilder
) type;
2006
TypeBuilder
.DefineCustomAttribute(
system\reflection\emit\assemblybuilderdata.cs (1)
318
internal void CheckTypeNameConflict(String strTypeName,
TypeBuilder
enclosingType)
system\reflection\emit\cominterfaces.cs (1)
275
[TypeLibImportClassAttribute(typeof(System.Reflection.Emit.
TypeBuilder
))]
system\reflection\emit\constructorbuilder.cs (4)
38
Type[] parameterTypes, Type[][] requiredCustomModifiers, Type[][] optionalCustomModifiers, ModuleBuilder mod,
TypeBuilder
type)
56
Type[] parameterTypes, ModuleBuilder mod,
TypeBuilder
type) :
69
private
TypeBuilder
GetTypeBuilder()
249
TypeBuilder
.AddDeclarativeSecurity(GetModuleBuilder().GetNativeHandle(), GetToken().Token, action, blob, blob.Length);
system\reflection\emit\customattributebuilder.cs (7)
205
if (!
TypeBuilder
.IsTypeEqual(namedProperties[i].DeclaringType, con.DeclaringType))
211
if (!(namedProperties[i].DeclaringType is
TypeBuilder
) ||
212
!con.DeclaringType.IsSubclassOf(((
TypeBuilder
)namedProperties[i].DeclaringType).BakedRuntimeType))
257
if (!
TypeBuilder
.IsTypeEqual(namedFields[i].DeclaringType, con.DeclaringType))
263
if (!(namedFields[i].DeclaringType is
TypeBuilder
) ||
264
!con.DeclaringType.IsSubclassOf(((
TypeBuilder
)namedFields[i].DeclaringType).BakedRuntimeType))
554
TypeBuilder
.DefineCustomAttribute(mod, tkOwner, tkAttrib, m_blob, toDisk,
system\reflection\emit\enumbuilder.cs (2)
413
m_typeBuilder = new TypeBuilder(name, visibility | TypeAttributes.Sealed, typeof(System.Enum), null, module, PackingSize.Unspecified,
TypeBuilder
.UnspecifiedTypeSize, null);
447
internal
TypeBuilder
m_typeBuilder;
system\reflection\emit\eventbuilder.cs (4)
46
TypeBuilder
type, // containing type
73
TypeBuilder
.DefineMethodSemantics(
121
TypeBuilder
.DefineCustomAttribute(
170
private
TypeBuilder
m_type;
system\reflection\emit\fieldbuilder.cs (8)
27
private
TypeBuilder
m_typeBuilder;
35
internal FieldBuilder(
TypeBuilder
typeBuilder, String fieldName, Type type,
65
m_fieldTok =
TypeBuilder
.DefineField(m_typeBuilder.GetModuleBuilder().GetNativeHandle(),
80
internal
TypeBuilder
GetTypeBuilder() { return m_typeBuilder; }
195
TypeBuilder
.SetFieldLayoutOffset(m_typeBuilder.GetModuleBuilder().GetNativeHandle(), GetToken().Token, iOffset);
210
TypeBuilder
.SetFieldMarshal(m_typeBuilder.GetModuleBuilder().GetNativeHandle(), GetToken().Token, ubMarshal, ubMarshal.Length);
218
TypeBuilder
.SetConstantValue(m_typeBuilder.GetModuleBuilder(), GetToken().Token, m_fieldType, defaultValue);
241
TypeBuilder
.DefineCustomAttribute(module,
system\reflection\emit\generictypeparameterbuilder.cs (2)
27
internal
TypeBuilder
m_type;
31
internal GenericTypeParameterBuilder(
TypeBuilder
type)
system\reflection\emit\ilgenerator.cs (2)
1210
if (cls is
TypeBuilder
|| cls is EnumBuilder) {
1248
if (cls is
TypeBuilder
|| cls is EnumBuilder) {
system\reflection\emit\methodbuilder.cs (10)
34
internal
TypeBuilder
m_containingType;
73
Type returnType, Type[] parameterTypes, ModuleBuilder mod,
TypeBuilder
type, bool bIsGlobalMethod)
81
ModuleBuilder mod,
TypeBuilder
type, bool bIsGlobalMethod)
92
ModuleBuilder mod,
TypeBuilder
type, bool bIsGlobalMethod)
473
internal
TypeBuilder
GetTypeBuilder()
786
int token =
TypeBuilder
.DefineMethod(m_module.GetNativeHandle(), m_containingType.MetadataTokenInternal, m_strName, sigBytes, sigLength, Attributes);
793
TypeBuilder
.SetMethodImpl(m_module.GetNativeHandle(), token, m_dwMethodImplFlags);
953
TypeBuilder
.AddDeclarativeSecurity(m_module.GetNativeHandle(), MetadataTokenInternal, action, blob, length);
1111
TypeBuilder
.SetMethodImpl(m_module.GetNativeHandle(), MetadataTokenInternal, attributes);
1187
TypeBuilder
.DefineCustomAttribute(m_module, MetadataTokenInternal,
system\reflection\emit\methodrental.cs (3)
77
if (cls is
TypeBuilder
)
80
TypeBuilder
typeBuilder = (
TypeBuilder
) cls;
system\reflection\emit\modulebuilder.cs (34)
409
TypeBuilder
typeBuilder;
412
if (item is
TypeBuilder
)
414
typeBuilder = (
TypeBuilder
)item;
846
TypeBuilder
tmpTypeBldr;
851
tmpTypeBldr = (
TypeBuilder
)builder;
1137
public
TypeBuilder
DefineType(String name)
1139
Contract.Ensures(Contract.Result<
TypeBuilder
>() != null);
1143
return DefineTypeNoLock(name, TypeAttributes.NotPublic, null, null, PackingSize.Unspecified,
TypeBuilder
.UnspecifiedTypeSize);
1148
public
TypeBuilder
DefineType(String name, TypeAttributes attr)
1150
Contract.Ensures(Contract.Result<
TypeBuilder
>() != null);
1154
return DefineTypeNoLock(name, attr, null, null, PackingSize.Unspecified,
TypeBuilder
.UnspecifiedTypeSize);
1159
public
TypeBuilder
DefineType(String name, TypeAttributes attr, Type parent)
1161
Contract.Ensures(Contract.Result<
TypeBuilder
>() != null);
1168
return DefineTypeNoLock(name, attr, parent, null, PackingSize.Unspecified,
TypeBuilder
.UnspecifiedTypeSize);
1177
public
TypeBuilder
DefineType(String name, TypeAttributes attr, Type parent, int typesize)
1179
Contract.Ensures(Contract.Result<
TypeBuilder
>() != null);
1192
public
TypeBuilder
DefineType(String name, TypeAttributes attr, Type parent, PackingSize packingSize, int typesize)
1194
Contract.Ensures(Contract.Result<
TypeBuilder
>() != null);
1204
public
TypeBuilder
DefineType(String name, TypeAttributes attr, Type parent, Type[] interfaces)
1206
Contract.Ensures(Contract.Result<
TypeBuilder
>() != null);
1210
return DefineTypeNoLock(name, attr, parent, interfaces, PackingSize.Unspecified,
TypeBuilder
.UnspecifiedTypeSize);
1215
private
TypeBuilder
DefineTypeNoLock(String name, TypeAttributes attr, Type parent, Type[] interfaces, PackingSize packingSize, int typesize)
1217
Contract.Ensures(Contract.Result<
TypeBuilder
>() != null);
1227
public
TypeBuilder
DefineType(String name, TypeAttributes attr, Type parent, PackingSize packsize)
1229
Contract.Ensures(Contract.Result<
TypeBuilder
>() != null);
1238
private
TypeBuilder
DefineTypeNoLock(String name, TypeAttributes attr, Type parent, PackingSize packsize)
1240
Contract.Ensures(Contract.Result<
TypeBuilder
>() != null);
1242
return new TypeBuilder(name, attr, parent, null, this, packsize,
TypeBuilder
.UnspecifiedTypeSize, null);
1727
TypeBuilder
typeBuilder = null;
1734
typeBuilder = type as
TypeBuilder
;
2010
tk =
TypeBuilder
.DefineMethodSpec(this.GetNativeHandle(), tk, sigBytes, sigLength);
2235
return new SignatureToken(
TypeBuilder
.GetTokenFromSig(GetNativeHandle(), sigBytes, sigLength), this);
2247
return new SignatureToken(
TypeBuilder
.GetTokenFromSig(GetNativeHandle(), localSigBytes, sigLength), this);
2268
TypeBuilder
.DefineCustomAttribute(
system\reflection\emit\modulebuilderdata.cs (1)
100
internal
TypeBuilder
m_globalTypeBuilder;
system\reflection\emit\parameterbuilder.cs (4)
41
TypeBuilder
.SetFieldMarshal(
52
TypeBuilder
.SetConstantValue(
75
TypeBuilder
.DefineCustomAttribute(
113
m_pdToken = new ParameterToken(
TypeBuilder
.SetParamInfo(
system\reflection\emit\propertybuilder.cs (5)
49
TypeBuilder
containingType) // the containing type
77
TypeBuilder
.SetConstantValue(
117
TypeBuilder
.DefineMethodSemantics(
160
TypeBuilder
.DefineCustomAttribute(
305
private
TypeBuilder
m_containingType;
system\reflection\emit\signaturehelper.cs (4)
389
else if (clsArgument is
TypeBuilder
)
391
TypeBuilder
clsBuilder = (
TypeBuilder
)clsArgument;
414
TypeBuilder
clsBuilder = ((EnumBuilder)clsArgument).m_typeBuilder;
system\reflection\emit\typebuilder.cs (40)
85
TypeBuilder
.DefineCustomAttribute(module, token, module.GetConstructorToken(m_con).Token,
99
if (!(type is
TypeBuilder
) && !(type is TypeBuilderInstantiation))
132
if (!(type is
TypeBuilder
) && !(type is TypeBuilderInstantiation))
143
if (type is
TypeBuilder
&& type.IsGenericTypeDefinition)
153
if (!(type is
TypeBuilder
) && !(type is TypeBuilderInstantiation))
164
if (type is
TypeBuilder
&& type.IsGenericTypeDefinition)
367
TypeBuilder
tb1 = null;
368
TypeBuilder
tb2 = null;
373
if (t1 is
TypeBuilder
)
375
tb1 =(
TypeBuilder
)t1;
384
if (t2 is
TypeBuilder
)
386
tb2 =(
TypeBuilder
)t2;
437
TypeBuilder
typeBldr;
447
else if ((typeBldr = destType as
TypeBuilder
) != null)
546
private
TypeBuilder
m_DeclaringType;
558
private
TypeBuilder
m_genTypeDef;
585
private TypeBuilder(string szName, int genParamPos,
TypeBuilder
declType)
610
TypeBuilder
enclosingType)
617
PackingSize iPackingSize, int iTypeSize,
TypeBuilder
enclosingType)
860
TypeBuilder
valueClassType;
881
valueClassType = temp as
TypeBuilder
;
1018
m_ca = new List<
TypeBuilder
.CustAttr>();
1303
if (
TypeBuilder
.IsTypeEqual(c, this))
1307
TypeBuilder
fromTypeBuilder = c as
TypeBuilder
;
1341
if (
TypeBuilder
.IsTypeEqual(interfaces[i], this))
1431
if (
TypeBuilder
.IsTypeEqual(p, c))
1438
if (
TypeBuilder
.IsTypeEqual(p, c))
1807
if (genericTypeDefinition is
TypeBuilder
)
1808
genericTypeDefinition = ((
TypeBuilder
)genericTypeDefinition).m_bakedRuntimeType;
1816
con =
TypeBuilder
.GetConstructor(inst, genericTypeDefinition.GetConstructor(
1953
public
TypeBuilder
DefineNestedType(String name)
1963
public
TypeBuilder
DefineNestedType(String name, TypeAttributes attr, Type parent, Type[] interfaces)
1976
public
TypeBuilder
DefineNestedType(String name, TypeAttributes attr, Type parent)
1985
public
TypeBuilder
DefineNestedType(String name, TypeAttributes attr)
1998
public
TypeBuilder
DefineNestedType(String name, TypeAttributes attr, Type parent, int typeSize)
2011
public
TypeBuilder
DefineNestedType(String name, TypeAttributes attr, Type parent, PackingSize packSize)
2024
public
TypeBuilder
DefineNestedType(String name, TypeAttributes attr, Type parent, PackingSize packSize, int typeSize)
2033
private
TypeBuilder
DefineNestedTypeNoLock(String name, TypeAttributes attr, Type parent, Type[] interfaces, PackingSize packSize, int typeSize)
2605
TypeBuilder
.DefineCustomAttribute(m_module, m_tdType.Token, ((ModuleBuilder)m_module).GetConstructorToken(con).Token,
system\rttype.cs (1)
3728
if (c is System.Reflection.Emit.
TypeBuilder
)
system\runtime\interopservices\tceadaptergen\eventproviderwriter.cs (7)
34
TypeBuilder
OutputTypeBuilder = m_OutputModule.DefineType(
94
private MethodBuilder DefineAddEventMethod(
TypeBuilder
OutputTypeBuilder, MethodInfo SrcItfMethod, Type SinkHelperClass, FieldBuilder fbSinkHelperArray, FieldBuilder fbEventCP, MethodBuilder mbInitSrcItf )
237
private MethodBuilder DefineRemoveEventMethod(
TypeBuilder
OutputTypeBuilder, MethodInfo SrcItfMethod, Type SinkHelperClass, FieldBuilder fbSinkHelperArray, FieldBuilder fbEventCP )
463
private MethodBuilder DefineInitSrcItfMethod(
TypeBuilder
OutputTypeBuilder, Type SourceInterface, FieldBuilder fbSinkHelperArray, FieldBuilder fbEventCP, FieldBuilder fbCPC )
553
private void DefineConstructor(
TypeBuilder
OutputTypeBuilder, FieldBuilder fbCPC )
584
private MethodBuilder DefineFinalizeMethod(
TypeBuilder
OutputTypeBuilder, Type SinkHelperClass, FieldBuilder fbSinkHelper, FieldBuilder fbEventCP )
743
private void DefineDisposeMethod(
TypeBuilder
OutputTypeBuilder, MethodBuilder FinalizeMethod )
system\runtime\interopservices\tceadaptergen\eventsinkhelperwriter.cs (4)
36
TypeBuilder
OutputTypeBuilder = TCEAdapterGenerator.DefineUniqueType(
97
private void DefineBlankMethod(
TypeBuilder
OutputTypeBuilder, MethodInfo Method)
119
private void DefineEventMethod(
TypeBuilder
OutputTypeBuilder, MethodInfo Method, Type DelegateCls, FieldBuilder fbDelegate )
254
private void DefineConstructor(
TypeBuilder
OutputTypeBuilder, FieldBuilder fbCookie, FieldBuilder[] afbDelegates )
system\runtime\interopservices\tceadaptergen\tceadaptergenerator.cs (3)
41
internal static void SetClassInterfaceTypeToNone(
TypeBuilder
tb)
59
internal static
TypeBuilder
DefineUniqueType(String strInitFullName, TypeAttributes attrs, Type BaseType, Type[] aInterfaceTypes, ModuleBuilder mb)
71
internal static void SetHiddenAttribute(
TypeBuilder
tb)
System (1)
regex\system\text\regularexpressions\RegexCompiler.cs (1)
3072
private
TypeBuilder
_typebuilder;
System.Activities (3)
System\Activities\Debugger\StateManager.cs (3)
537
TypeBuilder
typeBuilder = this.dynamicModule.DefineType(typeName, TypeAttributes.Public | TypeAttributes.Class);
574
internal MethodBuilder CreateMethodBuilder(
TypeBuilder
typeBuilder, Type typeIslandArguments, State state, bool withPriming)
637
MethodBuilder CreateIsland(
TypeBuilder
typeBuilder, State state, bool withPrimingTest, Dictionary<string, byte[]>checksumCache)
System.Core (8)
Microsoft\Scripting\Ast\LambdaExpression.cs (2)
173
var
type = method.DeclaringType as
TypeBuilder
;
Microsoft\Scripting\Compiler\AssemblyGen.cs (2)
103
private
TypeBuilder
DefineType(string name, Type parent, TypeAttributes attr) {
123
internal static
TypeBuilder
DefineDelegateType(string name) {
Microsoft\Scripting\Compiler\DelegateHelpers.cs (1)
36
TypeBuilder
builder = AssemblyGen.DefineDelegateType("Delegate" + types.Length);
Microsoft\Scripting\Compiler\ILGen.cs (1)
529
return t is
TypeBuilder
|| t.IsGenericParameter || t.IsVisible;
Microsoft\Scripting\Compiler\LambdaCompiler.cs (2)
51
private readonly
TypeBuilder
_typeBuilder;
140
_typeBuilder = (
TypeBuilder
)method.DeclaringType;
System.Data.Entity (19)
System\Data\Objects\Internal\EntityProxyFactory.cs (19)
611
private
TypeBuilder
_typeBuilder;
700
private
TypeBuilder
TypeBuilder
734
private void EmitBaseGetter(
TypeBuilder
typeBuilder, PropertyBuilder propertyBuilder, PropertyInfo baseProperty)
754
private void EmitBaseSetter(
TypeBuilder
typeBuilder, PropertyBuilder propertyBuilder, PropertyInfo baseProperty)
860
public void Implement(
TypeBuilder
typeBuilder, Action<FieldBuilder, bool> registerField)
870
public bool EmitMember(
TypeBuilder
typeBuilder, EdmMember member, PropertyBuilder propertyBuilder, PropertyInfo baseProperty, BaseProxyImplementor baseImplementor)
889
MethodInfo interceptorInvoke =
TypeBuilder
.GetMethod(interceptorType, typeof(Func<,,>).GetMethod("Invoke"));
967
public void Implement(
TypeBuilder
typeBuilder, Action<FieldBuilder, bool> registerField)
982
private void ImplementBaseGetter(
TypeBuilder
typeBuilder)
1005
private void ImplementBaseSetter(
TypeBuilder
typeBuilder)
1130
public void Implement(
TypeBuilder
typeBuilder, Action<FieldBuilder, bool> registerField)
1197
public bool EmitMember(
TypeBuilder
typeBuilder, EdmMember member, PropertyBuilder propertyBuilder, PropertyInfo baseProperty, BaseProxyImplementor baseImplementor)
1224
private void EmitScalarSetter(
TypeBuilder
typeBuilder, PropertyBuilder propertyBuilder, PropertyInfo baseProperty, bool isKeyMember)
1345
private void EmitReferenceProperty(
TypeBuilder
typeBuilder, PropertyBuilder propertyBuilder, PropertyInfo baseProperty, NavigationProperty navProperty)
1369
private void EmitCollectionProperty(
TypeBuilder
typeBuilder, PropertyBuilder propertyBuilder, PropertyInfo baseProperty, NavigationProperty navProperty)
1401
private void ImplementIEntityWithChangeTracker(
TypeBuilder
typeBuilder, Action<FieldBuilder, bool> registerField)
1444
private void ImplementIEntityWithRelationships(
TypeBuilder
typeBuilder, Action<FieldBuilder, bool> registerField)
1534
internal void Implement(
TypeBuilder
typeBuilder, Action<FieldBuilder, bool> registerField)
1609
internal void Implement(
TypeBuilder
typeBuilder, IEnumerable<FieldBuilder> serializedFields)
System.Data.SqlXml (3)
System\Xml\Xsl\IlGen\XmlILModule.cs (2)
33
private
TypeBuilder
typeBldr;
77
public XmlILModule(
TypeBuilder
typeBldr) {
System\Xml\Xsl\XmlIlGenerator.cs (1)
77
public XmlILCommand Generate(QilExpression query,
TypeBuilder
typeBldr) {
System.ServiceModel (1)
System\ServiceModel\ComIntegration\EmitterCache.cs (1)
78
TypeBuilder
typeBuilder = DynamicModule.DefineType(interfaceType.Name + "MarshalByRefObject", TypeAttributes.Public | TypeAttributes.Class | TypeAttributes.Abstract,
System.Web (2)
Util\FactoryGenerator.cs (1)
145
TypeBuilder
factoryTypeBuilder = _dynamicModule.DefineType("T_" + typeName,
Util\FastPropertyAccessor.cs (1)
113
TypeBuilder
accessorTypeBuilder = _dynamicModule.DefineType("T_" + typeName,
System.Web.Extensions (4)
UI\WebControls\Dynamic.cs (4)
319
TypeBuilder
tb = this.module.DefineType(typeName, TypeAttributes.Class |
335
FieldInfo[] GenerateProperties(
TypeBuilder
tb, DynamicProperty[] properties) {
363
void GenerateEquals(
TypeBuilder
tb, FieldInfo[] fields) {
398
void GenerateGetHashCode(
TypeBuilder
tb, FieldInfo[] fields) {
System.Web.Mobile (1)
UI\MobileControls\FactoryGenerator.cs (1)
160
TypeBuilder
factoryTypeBuilder = _dynamicModule.DefineType("T_" + typeName,
System.Xml (14)
System\Xml\Serialization\CodeGenerator.cs (3)
47
TypeBuilder
typeBuilder;
58
internal CodeGenerator(
TypeBuilder
typeBuilder) {
1774
static internal
TypeBuilder
CreateTypeBuilder(ModuleBuilder moduleBuilder, string name, TypeAttributes attributes, Type parent, Type[] interfaces) {
System\Xml\Serialization\XmlSerializationILGen.cs (10)
35
protected
TypeBuilder
typeBuilder;
77
internal MethodBuilder EnsureMethodBuilder(
TypeBuilder
typeBuilder, string methodName,
127
internal FieldBuilder GenerateHashtableGetBegin(string privateName, string publicName,
TypeBuilder
serializerContractTypeBuilder) {
188
internal FieldBuilder GeneratePublicMethods(string privateName, string publicName, string[] methods, XmlMapping[] xmlMappings,
TypeBuilder
serializerContractTypeBuilder) {
211
internal void GenerateSupportedTypes(Type[] types,
TypeBuilder
serializerContractTypeBuilder) {
251
TypeBuilder
baseSerializerTypeBuilder = CodeGenerator.CreateTypeBuilder(
299
TypeBuilder
typedSerializerTypeBuilder = CodeGenerator.CreateTypeBuilder(
391
FieldBuilder GenerateTypedSerializers(Hashtable serializers,
TypeBuilder
serializerContractTypeBuilder) {
419
void GenerateGetSerializer(Hashtable serializers, XmlMapping[] xmlMappings,
TypeBuilder
serializerContractTypeBuilder) {
464
TypeBuilder
serializerContractTypeBuilder = CodeGenerator.CreateTypeBuilder(
System\Xml\Xslt\XslCompiledTransform.cs (1)
219
public static CompilerErrorCollection CompileToType(XmlReader stylesheet, XsltSettings settings, XmlResolver stylesheetResolver, bool debug,
TypeBuilder
typeBuilder, string scriptAssemblyPath) {