11 [Guid(
"475E398F-8AFA-43a7-A3BE-F4EF8D6787C9")]
16 private const string strManagedCategoryGuid =
"{62C8FE65-4EBB-45e7-B440-6E39B2CDBF29}";
18 private const string strDocStringPrefix =
"";
20 private const string strManagedTypeThreadingModel =
"Both";
22 private const string strComponentCategorySubKey =
"Component Categories";
24 private const string strManagedCategoryDescription =
".NET Category";
26 private const string strImplementedCategoriesSubKey =
"Implemented Categories";
28 private const string strMsCorEEFileName =
"mscoree.dll";
30 private const string strRecordRootName =
"Record";
32 private const string strClsIdRootName =
"CLSID";
34 private const string strTlbRootName =
"TypeLib";
36 private static Guid s_ManagedCategoryGuid =
new Guid(
"{62C8FE65-4EBB-45e7-B440-6E39B2CDBF29}");
58 RuntimeAssembly runtimeAssembly = assembly as RuntimeAssembly;
59 if (runtimeAssembly ==
null)
71 text = runtimeAssembly.GetCodeBase(copiedName:
false);
78 int num = registrableTypesInAssembly.Length;
79 string strAsmVersion = runtimeAssembly.GetVersion().
ToString();
81 for (
int i = 0; i < num; i++)
83 if (IsRegisteredAsValueType(registrableTypesInAssembly[i]))
85 RegisterValueType(registrableTypesInAssembly[i], fullName, strAsmVersion, text, imageRuntimeVersion);
89 RegisterComImportedType(registrableTypesInAssembly[i], fullName, strAsmVersion, text, imageRuntimeVersion);
93 RegisterManagedType(registrableTypesInAssembly[i], fullName, strAsmVersion, text, imageRuntimeVersion);
95 CallUserDefinedRegistrationMethod(registrableTypesInAssembly[i], bRegister:
true);
98 int num2 = customAttributes.Length;
99 for (
int j = 0; j < num2; j++)
103 if (registrableTypesInAssembly.Length != 0 || num2 > 0)
121 if (assembly ==
null)
129 RuntimeAssembly runtimeAssembly = assembly as RuntimeAssembly;
130 if (runtimeAssembly ==
null)
136 int num = registrableTypesInAssembly.Length;
137 string strAsmVersion = runtimeAssembly.GetVersion().
ToString();
138 for (
int i = 0; i < num; i++)
140 CallUserDefinedRegistrationMethod(registrableTypesInAssembly[i], bRegister:
false);
141 if (IsRegisteredAsValueType(registrableTypesInAssembly[i]))
143 if (!UnregisterValueType(registrableTypesInAssembly[i], strAsmVersion))
150 if (!UnregisterComImportedType(registrableTypesInAssembly[i], strAsmVersion))
155 else if (!UnregisterManagedType(registrableTypesInAssembly[i], strAsmVersion))
161 int num2 = customAttributes.Length;
164 for (
int j = 0; j < num2; j++)
169 if (registrableTypesInAssembly.Length != 0 || num2 > 0)
183 if (assembly ==
null)
187 if (!(assembly is RuntimeAssembly))
192 int num = exportedTypes.Length;
194 for (
int i = 0; i < num; i++)
196 Type type = exportedTypes[i];
228 if (type as RuntimeType ==
null)
236 RegisterTypeForComClientsNative(type, ref g);
243 return s_ManagedCategoryGuid;
253 return TypeRequiresRegistrationHelper(type);
260 [SecuritySafeCritical]
271 Type baseComImportType = GetBaseComImportType(type);
294 if (type as RuntimeType ==
null)
302 return RegisterTypeForComClientsExNative(type, classContext, flags);
311 CoRevokeClassObject(cookie);
315 internal static bool TypeRequiresRegistrationHelper(
Type type)
329 return Marshal.IsTypeVisibleFromCom(type);
333 private void RegisterValueType(Type type,
string strAsmName,
string strAsmVersion,
string strAsmCodeBase,
string strRuntimeVersion)
336 using (
RegistryKey registryKey = Registry.ClassesRoot.CreateSubKey(
"Record"))
338 using (
RegistryKey registryKey2 = registryKey.CreateSubKey(subkey))
340 using (
RegistryKey registryKey3 = registryKey2.CreateSubKey(strAsmVersion))
342 registryKey3.SetValue(
"Class", type.FullName);
343 registryKey3.SetValue(
"Assembly", strAsmName);
344 registryKey3.SetValue(
"RuntimeVersion", strRuntimeVersion);
345 if (strAsmCodeBase !=
null)
347 registryKey3.SetValue(
"CodeBase", strAsmCodeBase);
355 private void RegisterManagedType(Type type,
string strAsmName,
string strAsmVersion,
string strAsmCodeBase,
string strRuntimeVersion)
357 string value = type.FullName ??
"";
360 if (progIdForType !=
string.Empty)
362 using (
RegistryKey registryKey = Registry.ClassesRoot.CreateSubKey(progIdForType))
364 registryKey.SetValue(
"", value);
365 using (
RegistryKey registryKey2 = registryKey.CreateSubKey(
"CLSID"))
367 registryKey2.SetValue(
"", text);
371 using (
RegistryKey registryKey3 = Registry.ClassesRoot.CreateSubKey(
"CLSID"))
373 using (
RegistryKey registryKey4 = registryKey3.CreateSubKey(text))
375 registryKey4.SetValue(
"", value);
376 using (
RegistryKey registryKey5 = registryKey4.CreateSubKey(
"InprocServer32"))
378 registryKey5.SetValue(
"",
"mscoree.dll");
379 registryKey5.SetValue(
"ThreadingModel",
"Both");
380 registryKey5.SetValue(
"Class", type.FullName);
381 registryKey5.SetValue(
"Assembly", strAsmName);
382 registryKey5.SetValue(
"RuntimeVersion", strRuntimeVersion);
383 if (strAsmCodeBase !=
null)
385 registryKey5.SetValue(
"CodeBase", strAsmCodeBase);
387 using (
RegistryKey registryKey6 = registryKey5.CreateSubKey(strAsmVersion))
389 registryKey6.SetValue(
"Class", type.FullName);
390 registryKey6.SetValue(
"Assembly", strAsmName);
391 registryKey6.SetValue(
"RuntimeVersion", strRuntimeVersion);
392 if (strAsmCodeBase !=
null)
394 registryKey6.SetValue(
"CodeBase", strAsmCodeBase);
397 if (progIdForType !=
string.Empty)
399 using (
RegistryKey registryKey7 = registryKey4.CreateSubKey(
"ProgId"))
401 registryKey7.SetValue(
"", progIdForType);
405 using (
RegistryKey registryKey8 = registryKey4.CreateSubKey(
"Implemented Categories"))
407 using (registryKey8.CreateSubKey(
"{62C8FE65-4EBB-45e7-B440-6E39B2CDBF29}"))
413 EnsureManagedCategoryExists();
417 private void RegisterComImportedType(Type type,
string strAsmName,
string strAsmVersion,
string strAsmCodeBase,
string strRuntimeVersion)
420 using (
RegistryKey registryKey = Registry.ClassesRoot.CreateSubKey(
"CLSID"))
422 using (
RegistryKey registryKey2 = registryKey.CreateSubKey(subkey))
424 using (
RegistryKey registryKey3 = registryKey2.CreateSubKey(
"InprocServer32"))
426 registryKey3.SetValue(
"Class", type.FullName);
427 registryKey3.SetValue(
"Assembly", strAsmName);
428 registryKey3.SetValue(
"RuntimeVersion", strRuntimeVersion);
429 if (strAsmCodeBase !=
null)
431 registryKey3.SetValue(
"CodeBase", strAsmCodeBase);
433 using (
RegistryKey registryKey4 = registryKey3.CreateSubKey(strAsmVersion))
435 registryKey4.SetValue(
"Class", type.FullName);
436 registryKey4.SetValue(
"Assembly", strAsmName);
437 registryKey4.SetValue(
"RuntimeVersion", strRuntimeVersion);
438 if (strAsmCodeBase !=
null)
440 registryKey4.SetValue(
"CodeBase", strAsmCodeBase);
449 private bool UnregisterValueType(Type type,
string strAsmVersion)
453 using (
RegistryKey registryKey = Registry.ClassesRoot.OpenSubKey(
"Record", writable:
true))
455 if (registryKey ==
null)
459 using (
RegistryKey registryKey2 = registryKey.OpenSubKey(text, writable:
true))
461 if (registryKey2 !=
null)
463 using (
RegistryKey registryKey3 = registryKey2.OpenSubKey(strAsmVersion, writable:
true))
465 if (registryKey3 !=
null)
467 registryKey3.DeleteValue(
"Assembly", throwOnMissingValue:
false);
468 registryKey3.DeleteValue(
"Class", throwOnMissingValue:
false);
469 registryKey3.DeleteValue(
"CodeBase", throwOnMissingValue:
false);
470 registryKey3.DeleteValue(
"RuntimeVersion", throwOnMissingValue:
false);
471 if (registryKey3.SubKeyCount == 0 && registryKey3.ValueCount == 0)
473 registryKey2.DeleteSubKey(strAsmVersion);
477 if (registryKey2.SubKeyCount != 0)
481 if (registryKey2.SubKeyCount == 0 && registryKey2.ValueCount == 0)
483 registryKey.DeleteSubKey(text);
487 if (registryKey.SubKeyCount != 0)
491 if (registryKey.ValueCount != 0)
495 Registry.ClassesRoot.DeleteSubKey(
"Record");
501 private bool UnregisterManagedType(Type type,
string strAsmVersion)
506 using (
RegistryKey registryKey = Registry.ClassesRoot.OpenSubKey(
"CLSID", writable:
true))
508 if (registryKey !=
null)
510 using (
RegistryKey registryKey2 = registryKey.OpenSubKey(text, writable:
true))
512 if (registryKey2 !=
null)
514 using (
RegistryKey registryKey3 = registryKey2.OpenSubKey(
"InprocServer32", writable:
true))
516 if (registryKey3 !=
null)
518 using (
RegistryKey registryKey4 = registryKey3.OpenSubKey(strAsmVersion, writable:
true))
520 if (registryKey4 !=
null)
522 registryKey4.DeleteValue(
"Assembly", throwOnMissingValue:
false);
523 registryKey4.DeleteValue(
"Class", throwOnMissingValue:
false);
524 registryKey4.DeleteValue(
"RuntimeVersion", throwOnMissingValue:
false);
525 registryKey4.DeleteValue(
"CodeBase", throwOnMissingValue:
false);
526 if (registryKey4.SubKeyCount == 0 && registryKey4.ValueCount == 0)
528 registryKey3.DeleteSubKey(strAsmVersion);
532 if (registryKey3.SubKeyCount != 0)
538 registryKey3.DeleteValue(
"", throwOnMissingValue:
false);
539 registryKey3.DeleteValue(
"ThreadingModel", throwOnMissingValue:
false);
541 registryKey3.DeleteValue(
"Assembly", throwOnMissingValue:
false);
542 registryKey3.DeleteValue(
"Class", throwOnMissingValue:
false);
543 registryKey3.DeleteValue(
"RuntimeVersion", throwOnMissingValue:
false);
544 registryKey3.DeleteValue(
"CodeBase", throwOnMissingValue:
false);
545 if (registryKey3.SubKeyCount == 0 && registryKey3.ValueCount == 0)
547 registryKey2.DeleteSubKey(
"InprocServer32");
553 registryKey2.DeleteValue(
"", throwOnMissingValue:
false);
554 if (progIdForType !=
string.Empty)
556 using (
RegistryKey registryKey5 = registryKey2.OpenSubKey(
"ProgId", writable:
true))
558 if (registryKey5 !=
null)
560 registryKey5.DeleteValue(
"", throwOnMissingValue:
false);
561 if (registryKey5.SubKeyCount == 0 && registryKey5.ValueCount == 0)
563 registryKey2.DeleteSubKey(
"ProgId");
568 using (
RegistryKey registryKey6 = registryKey2.OpenSubKey(
"Implemented Categories", writable:
true))
570 if (registryKey6 !=
null)
572 using (
RegistryKey registryKey7 = registryKey6.OpenSubKey(
"{62C8FE65-4EBB-45e7-B440-6E39B2CDBF29}", writable:
true))
574 if (registryKey7 !=
null && registryKey7.SubKeyCount == 0 && registryKey7.ValueCount == 0)
576 registryKey6.DeleteSubKey(
"{62C8FE65-4EBB-45e7-B440-6E39B2CDBF29}");
579 if (registryKey6.SubKeyCount == 0 && registryKey6.ValueCount == 0)
581 registryKey2.DeleteSubKey(
"Implemented Categories");
586 if (registryKey2.SubKeyCount == 0 && registryKey2.ValueCount == 0)
588 registryKey.DeleteSubKey(text);
592 if (registryKey.SubKeyCount == 0 && registryKey.ValueCount == 0)
594 Registry.ClassesRoot.DeleteSubKey(
"CLSID");
601 if (progIdForType !=
string.Empty)
603 using (
RegistryKey registryKey8 = Registry.ClassesRoot.OpenSubKey(progIdForType, writable:
true))
605 if (registryKey8 ==
null)
609 registryKey8.DeleteValue(
"", throwOnMissingValue:
false);
610 using (
RegistryKey registryKey9 = registryKey8.OpenSubKey(
"CLSID", writable:
true))
612 if (registryKey9 !=
null)
614 registryKey9.DeleteValue(
"", throwOnMissingValue:
false);
615 if (registryKey9.SubKeyCount == 0 && registryKey9.ValueCount == 0)
617 registryKey8.DeleteSubKey(
"CLSID");
621 if (registryKey8.SubKeyCount != 0)
625 if (registryKey8.ValueCount != 0)
629 Registry.ClassesRoot.DeleteSubKey(progIdForType);
638 private bool UnregisterComImportedType(Type type,
string strAsmVersion)
642 using (
RegistryKey registryKey = Registry.ClassesRoot.OpenSubKey(
"CLSID", writable:
true))
644 if (registryKey ==
null)
648 using (
RegistryKey registryKey2 = registryKey.OpenSubKey(text, writable:
true))
650 if (registryKey2 !=
null)
652 using (
RegistryKey registryKey3 = registryKey2.OpenSubKey(
"InprocServer32", writable:
true))
654 if (registryKey3 !=
null)
656 registryKey3.DeleteValue(
"Assembly", throwOnMissingValue:
false);
657 registryKey3.DeleteValue(
"Class", throwOnMissingValue:
false);
658 registryKey3.DeleteValue(
"RuntimeVersion", throwOnMissingValue:
false);
659 registryKey3.DeleteValue(
"CodeBase", throwOnMissingValue:
false);
660 using (
RegistryKey registryKey4 = registryKey3.OpenSubKey(strAsmVersion, writable:
true))
662 if (registryKey4 !=
null)
664 registryKey4.DeleteValue(
"Assembly", throwOnMissingValue:
false);
665 registryKey4.DeleteValue(
"Class", throwOnMissingValue:
false);
666 registryKey4.DeleteValue(
"RuntimeVersion", throwOnMissingValue:
false);
667 registryKey4.DeleteValue(
"CodeBase", throwOnMissingValue:
false);
668 if (registryKey4.SubKeyCount == 0 && registryKey4.ValueCount == 0)
670 registryKey3.DeleteSubKey(strAsmVersion);
674 if (registryKey3.SubKeyCount != 0)
678 if (registryKey3.SubKeyCount == 0 && registryKey3.ValueCount == 0)
680 registryKey2.DeleteSubKey(
"InprocServer32");
684 if (registryKey2.SubKeyCount == 0 && registryKey2.ValueCount == 0)
686 registryKey.DeleteSubKey(text);
690 if (registryKey.SubKeyCount != 0)
694 if (registryKey.ValueCount != 0)
698 Registry.ClassesRoot.DeleteSubKey(
"CLSID");
704 private void RegisterPrimaryInteropAssembly(RuntimeAssembly assembly,
string strAsmCodeBase, PrimaryInteropAssemblyAttribute attr)
706 if (assembly.GetPublicKey().Length == 0)
708 throw new InvalidOperationException(Environment.GetResourceString(
"InvalidOperation_PIAMustBeStrongNamed"));
712 using (
RegistryKey registryKey = Registry.ClassesRoot.CreateSubKey(
"TypeLib"))
714 using (
RegistryKey registryKey2 = registryKey.CreateSubKey(subkey))
716 using (
RegistryKey registryKey3 = registryKey2.CreateSubKey(subkey2))
718 registryKey3.SetValue(
"PrimaryInteropAssemblyName", assembly.FullName);
719 if (strAsmCodeBase !=
null)
721 registryKey3.SetValue(
"PrimaryInteropAssemblyCodeBase", strAsmCodeBase);
729 private void UnregisterPrimaryInteropAssembly(
Assembly assembly, PrimaryInteropAssemblyAttribute attr)
733 using (
RegistryKey registryKey = Registry.ClassesRoot.OpenSubKey(
"TypeLib", writable:
true))
735 if (registryKey !=
null)
737 using (
RegistryKey registryKey2 = registryKey.OpenSubKey(text, writable:
true))
739 if (registryKey2 !=
null)
741 using (
RegistryKey registryKey3 = registryKey2.OpenSubKey(text2, writable:
true))
743 if (registryKey3 !=
null)
745 registryKey3.DeleteValue(
"PrimaryInteropAssemblyName", throwOnMissingValue:
false);
746 registryKey3.DeleteValue(
"PrimaryInteropAssemblyCodeBase", throwOnMissingValue:
false);
747 if (registryKey3.SubKeyCount == 0 && registryKey3.ValueCount == 0)
749 registryKey2.DeleteSubKey(text2);
753 if (registryKey2.SubKeyCount == 0 && registryKey2.ValueCount == 0)
755 registryKey.DeleteSubKey(text);
759 if (registryKey.SubKeyCount == 0 && registryKey.ValueCount == 0)
761 Registry.ClassesRoot.DeleteSubKey(
"TypeLib");
767 private void EnsureManagedCategoryExists()
769 if (!ManagedCategoryExists())
771 using (
RegistryKey registryKey = Registry.ClassesRoot.CreateSubKey(
"Component Categories"))
773 using (
RegistryKey registryKey2 = registryKey.CreateSubKey(
"{62C8FE65-4EBB-45e7-B440-6E39B2CDBF29}"))
775 registryKey2.SetValue(
"0",
".NET Category");
781 private static bool ManagedCategoryExists()
783 using (
RegistryKey registryKey = Registry.ClassesRoot.OpenSubKey(
"Component Categories", RegistryKeyPermissionCheck.ReadSubTree))
785 if (registryKey ==
null)
789 using (
RegistryKey registryKey2 = registryKey.OpenSubKey(
"{62C8FE65-4EBB-45e7-B440-6E39B2CDBF29}", RegistryKeyPermissionCheck.ReadSubTree))
791 if (registryKey2 ==
null)
795 object value = registryKey2.GetValue(
"0");
796 if (value ==
null || value.GetType() != typeof(
string))
800 string a = (string)value;
801 if (a !=
".NET Category")
811 private void CallUserDefinedRegistrationMethod(Type type,
bool bRegister)
815 type2 = ((!bRegister) ? typeof(ComUnregisterFunctionAttribute) : typeof(ComRegisterFunctionAttribute));
817 while (!flag && type3 !=
null)
820 int num = methods.Length;
821 for (
int i = 0; i < num; i++)
832 throw new InvalidOperationException(Environment.GetResourceString(
"InvalidOperation_NonStaticComRegFunction", methodInfo.
Name, type3.Name));
834 throw new InvalidOperationException(Environment.GetResourceString(
"InvalidOperation_NonStaticComUnRegFunction", methodInfo.
Name, type3.Name));
837 if (methodInfo.
ReturnType != typeof(
void) || parameters ==
null || parameters.Length != 1 || (parameters[0].ParameterType != typeof(
string) && parameters[0].ParameterType != typeof(Type)))
841 throw new InvalidOperationException(Environment.GetResourceString(
"InvalidOperation_InvalidComRegFunctionSig", methodInfo.
Name, type3.Name));
843 throw new InvalidOperationException(Environment.GetResourceString(
"InvalidOperation_InvalidComUnRegFunctionSig", methodInfo.
Name, type3.Name));
849 throw new InvalidOperationException(Environment.GetResourceString(
"InvalidOperation_MultipleComRegFunctions", type3.Name));
851 throw new InvalidOperationException(Environment.GetResourceString(
"InvalidOperation_MultipleComUnRegFunctions", type3.Name));
853 object[] array =
new object[1];
854 if (parameters[0].ParameterType == typeof(
string))
856 array[0] =
"HKEY_CLASSES_ROOT\\CLSID\\{" + Marshal.GenerateGuidForType(type).ToString().ToUpper(
CultureInfo.
InvariantCulture) +
"}";
862 methodInfo.Invoke(
null, array);
865 type3 = type3.BaseType;
869 private Type GetBaseComImportType(Type type)
871 while (type !=
null && !type.IsImport)
873 type = type.BaseType;
878 private bool IsRegisteredAsValueType(Type type)
880 if (!type.IsValueType)
889 private static extern void RegisterTypeForComClientsNative(Type type, ref Guid g);
895 [DllImport(
"ole32.dll",
CharSet =
CharSet.Auto, PreserveSig =
false)]
896 private static extern void CoRevokeClassObject(
int cookie);
static CultureInfo InvariantCulture
Gets the T:System.Globalization.CultureInfo object that is culture-independent (invariant).
Discovers the attributes of a parameter and provides access to parameter metadata.
The exception that is thrown when a null reference (Nothing in Visual Basic) is passed to a method th...
virtual bool RegisterAssembly(Assembly assembly, AssemblyRegistrationFlags flags)
Registers the classes in a managed assembly to enable creation from COM.
virtual string ImageRuntimeVersion
Gets a string representing the version of the common language runtime (CLR) saved in the file contain...
Discovers the attributes of a method and provides access to method metadata.
virtual Guid GetManagedCategoryGuid()
Returns the GUID of the COM category that contains the managed classes.
virtual int RegisterTypeForComClients(Type type, RegistrationClassContext classContext, RegistrationConnectionType flags)
Registers the specified type with COM using the specified execution context and connection type.
virtual string FullName
Gets the display name of the assembly.
bool IsImport
Gets a value indicating whether the T:System.Type has a T:System.Runtime.InteropServices....
virtual int Count
Gets the number of elements actually contained in the T:System.Collections.ArrayList.
BindingFlags
Specifies flags that control binding and the way in which the search for members and types is conduct...
virtual Type ReturnType
Gets the return type of this method.
override string ToString()
Returns a String representing the name of the current Type.
static string GenerateProgIdForType(Type type)
Returns a programmatic identifier (ProgID) for the specified type.
virtual string GetProgIdForType(Type type)
Retrieves the COM ProgID for the specified type.
ConstructorInfo GetConstructor(BindingFlags bindingAttr, Binder binder, CallingConventions callConvention, Type[] types, ParameterModifier[] modifiers)
Searches for a constructor whose parameters match the specified argument types and modifiers,...
Indicates that the attributed assembly is a primary interop assembly.
bool IsClass
Gets a value indicating whether the T:System.Type is a class or a delegate; that is,...
virtual object [] GetCustomAttributes(bool inherit)
Gets all the custom attributes for this assembly.
bool IsStatic
Gets a value indicating whether the method is static.
virtual Type [] GetExportedTypes()
Gets the public types defined in this assembly that are visible outside the assembly.
Provides information about, and means to manipulate, the current environment and platform....
Represents a globally unique identifier (GUID).To browse the .NET Framework source code for this type...
Provides a set of services for registering and unregistering managed assemblies for use from COM.
virtual bool TypeRepresentsComType(Type type)
Indicates whether a type is marked with the T:System.Runtime.InteropServices.ComImportAttribute,...
Provides a set of services for registering and unregistering managed assemblies for use from COM.
static Guid GenerateGuidForType(Type type)
Returns the globally unique identifier (GUID) for the specified type, or generates a GUID using the a...
virtual bool UnregisterAssembly(Assembly assembly)
Unregisters the classes in a managed assembly.
Represents an assembly, which is a reusable, versionable, and self-describing building block of a com...
Represents type declarations: class types, interface types, array types, value types,...
Provides a collection of methods for allocating unmanaged memory, copying unmanaged memory blocks,...
bool IsCOMObject
Gets a value indicating whether the T:System.Type is a COM object.
virtual void CopyTo(Array array)
Copies the entire T:System.Collections.ArrayList to a compatible one-dimensional T:System....
MethodImplOptions
Defines the details of how a method is implemented.
CharSet
Dictates which character set marshaled strings should use.
object [] GetCustomAttributes(Type attributeType, bool inherit)
Provides COM objects with version-independent access to the M:System.Reflection.MemberInfo....
bool IsValueType
Gets a value indicating whether the T:System.Type is a value type.
virtual Type [] GetRegistrableTypesInAssembly(Assembly assembly)
Retrieves a list of classes in an assembly that would be registered by a call to M:System....
virtual int Add(object value)
Adds an object to the end of the T:System.Collections.ArrayList.
RegistrationConnectionType
Defines the types of connections to a class object.
virtual void RegisterTypeForComClients(Type type, ref Guid g)
Registers the specified type with COM using the specified GUID.
The exception that is thrown when one of the arguments provided to a method is not valid.
AssemblyRegistrationFlags
Defines a set of flags used when registering assemblies.
virtual bool ReflectionOnly
Gets a T:System.Boolean value indicating whether this assembly was loaded into the reflection-only co...
The exception that is thrown when a method call is invalid for the object's current state.
ClassInterfaceType
Identifies the type of class interface that is generated for a class.
virtual void UnregisterTypeForComClients(int cookie)
Removes references to a type registered with the M:System.Runtime.InteropServices....
string Name
Provides COM objects with version-independent access to the P:System.Reflection.MemberInfo....
bool IsAbstract
Gets a value indicating whether the T:System.Type is abstract and must be overridden.
Provides information about a specific culture (called a locale for unmanaged code development)....
virtual bool TypeRequiresRegistration(Type type)
Determines whether the specified type requires registration.
RegistrationClassContext
Specifies the set of execution contexts in which a class object will be made available for requests t...
abstract ParameterInfo [] GetParameters()
When overridden in a derived class, gets the parameters of the specified method or constructor.
Implements the T:System.Collections.IList interface using an array whose size is dynamically increase...