Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / xsp / System / Web / UI / WebParts / ConsumerConnectionPoint.cs / 1 / ConsumerConnectionPoint.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls.WebParts { using System; using System.Reflection; using System.Security.Permissions; using System.Web; using System.Web.Util; [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] [AspNetHostingPermission(SecurityAction.InheritanceDemand, Level=AspNetHostingPermissionLevel.Minimal)] public class ConsumerConnectionPoint : ConnectionPoint { // Used by WebPartManager to verify the custom ConnectionPoint type has // the correct constructor signature. internal static readonly Type[] ConstructorTypes; static ConsumerConnectionPoint() { ConstructorInfo constructor = typeof(ConsumerConnectionPoint).GetConstructors()[0]; ConstructorTypes = WebPartUtil.GetTypesForConstructor(constructor); } public ConsumerConnectionPoint(MethodInfo callbackMethod, Type interfaceType, Type controlType, string displayName, string id, bool allowsMultipleConnections) : base( callbackMethod, interfaceType, controlType, displayName, id, allowsMultipleConnections) { } public virtual void SetObject(Control control, object data) { if (control == null) { throw new ArgumentNullException("control"); } CallbackMethod.Invoke(control, new object[] {data}); } ////// Base implementation returns true, can be overridden by subclasses to return /// true or false conditionally based on the available secondary interfaces and the state /// of the consumer WebPart passed in. /// public virtual bool SupportsConnection(Control control, ConnectionInterfaceCollection secondaryInterfaces) { return true; } } }
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- RadioButtonRenderer.cs
- ConvertEvent.cs
- ResourcePermissionBaseEntry.cs
- OperandQuery.cs
- CodeArrayIndexerExpression.cs
- TraceSection.cs
- XmlSerializableServices.cs
- Point4D.cs
- FileNotFoundException.cs
- Int32Storage.cs
- InheritedPropertyDescriptor.cs
- Helper.cs
- Invariant.cs
- ServiceNotStartedException.cs
- ColorMap.cs
- BindingContext.cs
- XmlExtensionFunction.cs
- InputQueue.cs
- SafeArrayTypeMismatchException.cs
- SubpageParagraph.cs
- XAMLParseException.cs
- MasterPageCodeDomTreeGenerator.cs
- ScrollItemPattern.cs
- CodeTypeDelegate.cs
- UpdateCommand.cs
- Timer.cs
- PropertyCondition.cs
- CodeNamespaceCollection.cs
- GridItemProviderWrapper.cs
- UrlSyndicationContent.cs
- BmpBitmapEncoder.cs
- EmptyEnumerable.cs
- DateTimeFormat.cs
- XmlSchemaComplexContentRestriction.cs
- CoreSwitches.cs
- ObjectContextServiceProvider.cs
- TemplateField.cs
- TextContainerHelper.cs
- StringValueConverter.cs
- ObjectConverter.cs
- ValidateNames.cs
- ActiveXHost.cs
- CalendarTable.cs
- DefaultTextStore.cs
- HttpContextWrapper.cs
- UnsafeNativeMethods.cs
- SingleAnimationUsingKeyFrames.cs
- ModuleConfigurationInfo.cs
- XomlCompilerError.cs
- ProjectionPath.cs
- GeometryModel3D.cs
- DynamicScriptObject.cs
- UpdateCommandGenerator.cs
- ZipIOLocalFileHeader.cs
- assertwrapper.cs
- X509ChainPolicy.cs
- MaterialCollection.cs
- SecurityTokenTypes.cs
- XmlAtomErrorReader.cs
- ArgumentDesigner.xaml.cs
- WebPartCancelEventArgs.cs
- ExternalCalls.cs
- SeekStoryboard.cs
- DataMisalignedException.cs
- ParallelDesigner.cs
- DataGridGeneralPage.cs
- ConfigurationStrings.cs
- VariantWrapper.cs
- Repeater.cs
- ArrayTypeMismatchException.cs
- initElementDictionary.cs
- SettingsBindableAttribute.cs
- _DisconnectOverlappedAsyncResult.cs
- CodeAttributeArgumentCollection.cs
- XmlQueryRuntime.cs
- DeliveryStrategy.cs
- DesignerHelpers.cs
- AutomationProperty.cs
- InfiniteIntConverter.cs
- ToolStripMenuItem.cs
- MetaDataInfo.cs
- SSmlParser.cs
- ReadOnlyNameValueCollection.cs
- DecoderReplacementFallback.cs
- KeyToListMap.cs
- ChangeDirector.cs
- EventDescriptorCollection.cs
- ReferenceConverter.cs
- XmlQueryTypeFactory.cs
- SizeKeyFrameCollection.cs
- SamlAuthorizationDecisionStatement.cs
- AdCreatedEventArgs.cs
- ECDiffieHellmanCngPublicKey.cs
- ActivityScheduledRecord.cs
- ObjectHandle.cs
- MatrixTransform.cs
- RTLAwareMessageBox.cs
- ContainerVisual.cs
- XmlNodeChangedEventArgs.cs
- ToolStripPanelRenderEventArgs.cs