Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / ndp / clr / src / BCL / System / Runtime / InteropServices / ExtensibleClassFactory.cs / 1 / ExtensibleClassFactory.cs
// ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== /*============================================================================== ** ** Class: ExtensibleClassFactory ** ** ** Purpose: Methods used to customize the creation of managed objects that ** extend from unmanaged objects. ** ** =============================================================================*/ namespace System.Runtime.InteropServices { using System.Runtime.InteropServices; using System.Runtime.Remoting; using System.Runtime.CompilerServices; using System; [System.Runtime.InteropServices.ComVisible(true)] public sealed class ExtensibleClassFactory { // Prevent instantiation. private ExtensibleClassFactory() {} // Register a delegate that will be called whenever an instance of a managed // type that extends from an unmanaged type needs to allocate the aggregated // unmanaged object. This delegate is expected to allocate and aggregate the // unmanaged object and is called in place of a CoCreateInstance. This // routine must be called in the context of the static initializer for the // class for which the callbacks will be made. // It is not legal to register this callback from a class that has any // parents that have already registered a callback. [MethodImplAttribute(MethodImplOptions.InternalCall)] public static extern void RegisterObjectCreationCallback(ObjectCreationDelegate callback); } }
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- DateTimeConverter2.cs
- TimerEventSubscription.cs
- TypeDelegator.cs
- ThrowHelper.cs
- ObjectDataSourceMethodEditor.cs
- ResourcesBuildProvider.cs
- InternalsVisibleToAttribute.cs
- AnonymousIdentificationSection.cs
- ConsumerConnectionPointCollection.cs
- RepeaterDataBoundAdapter.cs
- XmlSchemaSimpleContentExtension.cs
- InputElement.cs
- InputGestureCollection.cs
- CollectionChangedEventManager.cs
- GuidelineCollection.cs
- StdValidatorsAndConverters.cs
- ExpressionPrefixAttribute.cs
- WebControl.cs
- SystemParameters.cs
- ExtractorMetadata.cs
- TcpHostedTransportConfiguration.cs
- ToolStripDropDownClosedEventArgs.cs
- ListDictionary.cs
- SolidColorBrush.cs
- Slider.cs
- ZipIOCentralDirectoryFileHeader.cs
- Event.cs
- JsonServiceDocumentSerializer.cs
- Drawing.cs
- XmlWhitespace.cs
- ByteViewer.cs
- CircleHotSpot.cs
- PixelShader.cs
- AssociationTypeEmitter.cs
- ACE.cs
- ObjectConverter.cs
- BaseTemplateBuildProvider.cs
- securestring.cs
- ViewDesigner.cs
- PowerModeChangedEventArgs.cs
- Trigger.cs
- QueryableDataSource.cs
- XhtmlBasicListAdapter.cs
- XNodeNavigator.cs
- CannotUnloadAppDomainException.cs
- ObjectQueryProvider.cs
- TypeConverterHelper.cs
- UICuesEvent.cs
- ConfigurationStrings.cs
- PerformanceCounterPermissionEntry.cs
- XmlSerializerVersionAttribute.cs
- StorageEntityTypeMapping.cs
- _emptywebproxy.cs
- UserPreferenceChangingEventArgs.cs
- NativeMethodsOther.cs
- ListViewItem.cs
- PenThread.cs
- BinaryParser.cs
- XmlToDatasetMap.cs
- InstallerTypeAttribute.cs
- ToolboxItemLoader.cs
- FactoryGenerator.cs
- TextDecoration.cs
- PrintDialog.cs
- TextRunProperties.cs
- RSAPKCS1KeyExchangeDeformatter.cs
- DateTimeAutomationPeer.cs
- DoubleMinMaxAggregationOperator.cs
- ThrowHelper.cs
- safelink.cs
- AttributeExtensions.cs
- BinaryFormatter.cs
- PartialClassGenerationTaskInternal.cs
- QilInvoke.cs
- UnionExpr.cs
- BigIntegerStorage.cs
- ContextStaticAttribute.cs
- EventMappingSettings.cs
- GroupBox.cs
- ListChangedEventArgs.cs
- Point4DConverter.cs
- Error.cs
- RowBinding.cs
- Set.cs
- NameValueConfigurationCollection.cs
- Int32Animation.cs
- LeafCellTreeNode.cs
- XPathNodePointer.cs
- MetaTable.cs
- SystemWebExtensionsSectionGroup.cs
- Library.cs
- DataServices.cs
- ToolStripScrollButton.cs
- CurrentChangingEventManager.cs
- XmlTextReaderImpl.cs
- Repeater.cs
- AdornerLayer.cs
- XmlDeclaration.cs
- Compilation.cs
- DisplayMemberTemplateSelector.cs