Code:
/ WCF / WCF / 3.5.30729.1 / untmp / Orcas / SP / ndp / cdf / src / WCF / ServiceModel / System / ServiceModel / Channels / MsmqInputMessagePool.cs / 1 / MsmqInputMessagePool.cs
//------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------- namespace System.ServiceModel.Channels { interface IMsmqMessagePool : IDisposable { MsmqInputMessage TakeMessage(); void ReturnMessage(MsmqInputMessage message); } sealed class MsmqInputMessagePool : SynchronizedDisposablePool, IMsmqMessagePool { int maxPoolSize; internal MsmqInputMessagePool(int maxPoolSize) : base(maxPoolSize) { this.maxPoolSize = maxPoolSize; } MsmqInputMessage IMsmqMessagePool.TakeMessage() { MsmqInputMessage message = this.Take(); if (null == message) message = new MsmqInputMessage(); return message; } void IMsmqMessagePool.ReturnMessage(MsmqInputMessage message) { if (! this.Return(message)) { MsmqDiagnostics.PoolFull(this.maxPoolSize); message.Dispose(); } } } } // 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
- DataGridViewElement.cs
- ItemsPanelTemplate.cs
- thaishape.cs
- StylusButton.cs
- SspiSafeHandles.cs
- TextEffect.cs
- ComplexBindingPropertiesAttribute.cs
- SqlCharStream.cs
- InvalidPrinterException.cs
- TreeNodeBinding.cs
- WaitHandleCannotBeOpenedException.cs
- DrawingImage.cs
- EntityChangedParams.cs
- OpenTypeCommon.cs
- NavigatingCancelEventArgs.cs
- XamlNamespaceHelper.cs
- HtmlTableRowCollection.cs
- CurrencyManager.cs
- TreeNodeStyle.cs
- RowCache.cs
- AttributeProviderAttribute.cs
- DeflateEmulationStream.cs
- SnapshotChangeTrackingStrategy.cs
- IgnoreFileBuildProvider.cs
- SecurityContext.cs
- WmfPlaceableFileHeader.cs
- AnimationClockResource.cs
- QueryReaderSettings.cs
- ColorDialog.cs
- ImageFormatConverter.cs
- EdmItemCollection.cs
- sortedlist.cs
- DbMetaDataCollectionNames.cs
- HybridWebProxyFinder.cs
- DBBindings.cs
- StylusButton.cs
- FrameworkContentElementAutomationPeer.cs
- _UriSyntax.cs
- Tracer.cs
- FrameSecurityDescriptor.cs
- CrossAppDomainChannel.cs
- XmlAttributeProperties.cs
- SelectionRange.cs
- ExpressionNormalizer.cs
- TypeBrowser.xaml.cs
- SQLRoleProvider.cs
- IssuedTokenClientBehaviorsElement.cs
- Application.cs
- SqlMethodCallConverter.cs
- MessageAction.cs
- SubtreeProcessor.cs
- AnchoredBlock.cs
- DbModificationClause.cs
- XamlToRtfParser.cs
- WCFServiceClientProxyGenerator.cs
- RoleGroupCollection.cs
- KeyManager.cs
- AutomationFocusChangedEventArgs.cs
- ToolStripManager.cs
- SqlGatherProducedAliases.cs
- RequestFactory.cs
- IntegerCollectionEditor.cs
- DataServiceProcessingPipeline.cs
- NativeMethods.cs
- HttpHeaderCollection.cs
- HtmlControl.cs
- ListChangedEventArgs.cs
- SchemaImporterExtension.cs
- FillErrorEventArgs.cs
- SiteMapSection.cs
- NetCodeGroup.cs
- CellLabel.cs
- ListParagraph.cs
- Message.cs
- IPEndPoint.cs
- PerformanceCountersBase.cs
- ProcessHostConfigUtils.cs
- UIHelper.cs
- ValidatedMobileControlConverter.cs
- SapiGrammar.cs
- SecurityCriticalDataForSet.cs
- ExpressionBuilderCollection.cs
- StorageFunctionMapping.cs
- ValidationSummary.cs
- OdbcPermission.cs
- OutputCacheSettings.cs
- ClientBuildManager.cs
- MethodResolver.cs
- NameValuePair.cs
- StringBuilder.cs
- SetMemberBinder.cs
- TextProperties.cs
- DataBinding.cs
- RequestCache.cs
- SymLanguageType.cs
- SingleResultAttribute.cs
- RestClientProxyHandler.cs
- TagPrefixAttribute.cs
- MessageBox.cs
- TcpStreams.cs