Code:
/ FX-1434 / FX-1434 / 1.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
- TargetParameterCountException.cs
- ConfigurationLockCollection.cs
- SiteMembershipCondition.cs
- TabItem.cs
- Metadata.cs
- Bidi.cs
- ValidationUtility.cs
- WindowsFormsHostAutomationPeer.cs
- SuppressedPackageProperties.cs
- Rect.cs
- OracleConnectionString.cs
- PassportAuthenticationModule.cs
- BamlResourceSerializer.cs
- SoapReflector.cs
- AutoResetEvent.cs
- EntityChangedParams.cs
- FormsAuthenticationUser.cs
- ExpressionStringBuilder.cs
- XPathNodeInfoAtom.cs
- latinshape.cs
- NameValuePair.cs
- TextElement.cs
- RemotingException.cs
- EntityStoreSchemaGenerator.cs
- SoapIncludeAttribute.cs
- BasicViewGenerator.cs
- FontUnitConverter.cs
- OpenTypeCommon.cs
- XPathNode.cs
- RowBinding.cs
- precedingquery.cs
- DisplayNameAttribute.cs
- MetadataPropertyAttribute.cs
- XmlAnyElementAttribute.cs
- XmlHierarchicalDataSourceView.cs
- ParserContext.cs
- DataGridHeaderBorder.cs
- WindowsListBox.cs
- SerializationHelper.cs
- NameValuePair.cs
- ipaddressinformationcollection.cs
- FormViewModeEventArgs.cs
- DataBoundControlAdapter.cs
- ResourceType.cs
- MemberListBinding.cs
- ConnectionPointGlyph.cs
- FieldTemplateFactory.cs
- SortDescriptionCollection.cs
- ServiceOperationHelpers.cs
- OutKeywords.cs
- ImagingCache.cs
- ClientRolePrincipal.cs
- RequiredFieldValidator.cs
- ApplicationBuildProvider.cs
- DialogResultConverter.cs
- SessionPageStateSection.cs
- Code.cs
- _NTAuthentication.cs
- StubHelpers.cs
- RepeaterItem.cs
- Localizer.cs
- RegionData.cs
- Polyline.cs
- ProfessionalColorTable.cs
- LambdaReference.cs
- ConfigurationStrings.cs
- SynchronizationValidator.cs
- SeekableReadStream.cs
- ContainerCodeDomSerializer.cs
- Enum.cs
- Stroke.cs
- XmlSchema.cs
- COAUTHIDENTITY.cs
- LogWriteRestartAreaState.cs
- WebServiceResponseDesigner.cs
- XmlExpressionDumper.cs
- WebPartDeleteVerb.cs
- LinkedResource.cs
- X509RecipientCertificateServiceElement.cs
- NamespaceList.cs
- SafeBitVector32.cs
- TypeLoadException.cs
- SHA1Managed.cs
- TemplateControlBuildProvider.cs
- VariantWrapper.cs
- TypeBuilder.cs
- MetadataPropertyvalue.cs
- GetWinFXPath.cs
- NumericUpDown.cs
- CallbackHandler.cs
- RouteTable.cs
- DictionaryBase.cs
- AdRotator.cs
- ToolStripContentPanelRenderEventArgs.cs
- DocComment.cs
- MsmqPoisonMessageException.cs
- SpeechAudioFormatInfo.cs
- RightsManagementPermission.cs
- XamlGridLengthSerializer.cs
- QualificationDataAttribute.cs