Code:
/ WCF / WCF / 3.5.30729.1 / untmp / Orcas / SP / ndp / cdf / src / WCF / ServiceModel / System / ServiceModel / Channels / ChannelPool.cs / 1 / ChannelPool.cs
//------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------- namespace System.ServiceModel.Channels { using System.Collections.Generic; using System.ServiceModel; using System.Runtime.Serialization; using System.Xml; using System.ServiceModel.Description; using System.ServiceModel.Security; using System.Text; ////// Pool of channels used by OneWayChannelFactories /// class ChannelPool: IdlingCommunicationPool where TChannel : class, IChannel { public ChannelPool(ChannelPoolSettings settings) : base(settings.MaxOutboundChannelsPerEndpoint, settings.IdleTimeout, settings.LeaseTimeout) { } protected override void AbortItem(TChannel item) { item.Abort(); } protected override void CloseItem(TChannel item, TimeSpan timeout) { item.Close(timeout); } protected override ChannelPoolKey GetPoolKey(EndpointAddress address, Uri via) { return new ChannelPoolKey(address, via); } } class ChannelPoolKey : IEquatable { EndpointAddress address; Uri via; public ChannelPoolKey(EndpointAddress address, Uri via) { this.address = address; this.via = via; } public override int GetHashCode() { return address.GetHashCode() + via.GetHashCode(); } public bool Equals(ChannelPoolKey other) { return address.EndpointEquals(other.address) && via.Equals(other.via); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- GeneratedContractType.cs
- BuildProviderCollection.cs
- XsltArgumentList.cs
- SmtpException.cs
- SqlConnectionPoolProviderInfo.cs
- CodeTypeConstructor.cs
- HideDisabledControlAdapter.cs
- MimeObjectFactory.cs
- SecurityPolicySection.cs
- WebDisplayNameAttribute.cs
- PhysicalAddress.cs
- WebCategoryAttribute.cs
- ClaimSet.cs
- MessageRpc.cs
- ByteRangeDownloader.cs
- UnsafeNativeMethodsCLR.cs
- Border.cs
- Keywords.cs
- AudioLevelUpdatedEventArgs.cs
- SmiEventSink_DeferedProcessing.cs
- UnicastIPAddressInformationCollection.cs
- WebBrowserDocumentCompletedEventHandler.cs
- EntityViewGenerationConstants.cs
- CatalogPartChrome.cs
- DesignerTextBoxAdapter.cs
- SessionStateUtil.cs
- DataGridViewControlCollection.cs
- RuleAttributes.cs
- StrokeCollectionDefaultValueFactory.cs
- ApplicationDirectory.cs
- CodePageUtils.cs
- HttpListenerException.cs
- SoapHeaders.cs
- WindowsClaimSet.cs
- SharedUtils.cs
- Color.cs
- DbModificationClause.cs
- SafeNativeMethods.cs
- Emitter.cs
- Environment.cs
- DataRow.cs
- ClientSession.cs
- LogExtentCollection.cs
- TargetControlTypeCache.cs
- ConstructorExpr.cs
- StyleHelper.cs
- MarkerProperties.cs
- Activator.cs
- HtmlMobileTextWriter.cs
- EntityDataSourceWizardForm.cs
- FloaterBaseParagraph.cs
- StringSource.cs
- HtmlContainerControl.cs
- Visual3DCollection.cs
- Attributes.cs
- DoubleAverageAggregationOperator.cs
- InternalConfigEventArgs.cs
- UITypeEditors.cs
- StringConcat.cs
- StringConverter.cs
- StringHandle.cs
- PropertyItem.cs
- DataExpression.cs
- AuthenticationService.cs
- WebPartVerbCollection.cs
- WaitHandle.cs
- FileRecordSequence.cs
- CmsInterop.cs
- ProfessionalColors.cs
- NameValueConfigurationCollection.cs
- RegexParser.cs
- ArcSegment.cs
- Metadata.cs
- CatalogPart.cs
- TextFormatterHost.cs
- RevocationPoint.cs
- SafeCryptoHandles.cs
- ObjectStateManager.cs
- ExpressionBindings.cs
- Transform3DGroup.cs
- CodeTypeReferenceExpression.cs
- DetailsViewCommandEventArgs.cs
- SEHException.cs
- CodeMethodInvokeExpression.cs
- AnnotationAdorner.cs
- CodeConstructor.cs
- FontDriver.cs
- ConfigXmlComment.cs
- WorkflowPageSetupDialog.cs
- ModelPropertyCollectionImpl.cs
- TemplatePropertyEntry.cs
- StaticContext.cs
- LogManagementAsyncResult.cs
- AppDomainUnloadedException.cs
- PointAnimationUsingKeyFrames.cs
- ZipIOCentralDirectoryBlock.cs
- securitycriticaldataClass.cs
- TagNameToTypeMapper.cs
- DependencyObjectPropertyDescriptor.cs
- safemediahandle.cs