Code:
/ WCF / WCF / 3.5.30729.1 / untmp / Orcas / SP / ndp / cdf / src / WCF / SMSvcHost / System / ServiceModel / Activation / ListenerSingletonConnectionReader.cs / 1 / ListenerSingletonConnectionReader.cs
//------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
//-----------------------------------------------------------
namespace System.ServiceModel.Activation
{
using System.ServiceModel.Channels;
class ListenerSingletonConnectionReader : DupHandleConnectionReader
{
ServerSingletonDecoder decoder;
public ListenerSingletonConnectionReader(IConnection connection,
ItemDequeuedCallback connectionDequeuedCallback, TransportType transportType,
long streamPosition, int offset, int size,
ConnectionClosedCallback closedCallback, ViaDecodedCallback viaDecodedCallback)
: base(connection, connectionDequeuedCallback, transportType, offset, size, closedCallback, viaDecodedCallback)
{
this.decoder = new ServerSingletonDecoder(streamPosition, ListenerConstants.MaxUriSize, ListenerConstants.SharedMaxContentTypeSize);
}
protected override bool CanDupHandle(out Uri via)
{
if (decoder.CurrentState == ServerSingletonDecoder.State.ReadingContentTypeRecord)
{
via = decoder.Via;
return true;
}
else
{
via = null;
return false;
}
}
protected override int Decode(byte[] buffer, int offset, int size)
{
return decoder.Decode(buffer, offset, size);
}
protected override Exception CreatePrematureEOFException()
{
return decoder.CreatePrematureEOFException();
}
}
}
// 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
- SessionStateContainer.cs
- Message.cs
- ObfuscateAssemblyAttribute.cs
- mil_sdk_version.cs
- Stack.cs
- InternalCache.cs
- DataGridViewRowConverter.cs
- DescendantQuery.cs
- TextDpi.cs
- StringCollection.cs
- ServiceReference.cs
- SSmlParser.cs
- Camera.cs
- NotFiniteNumberException.cs
- MultiSelector.cs
- ListDesigner.cs
- prefixendpointaddressmessagefilter.cs
- DesignerLoader.cs
- ProvidersHelper.cs
- UnmanagedBitmapWrapper.cs
- SQLInt64Storage.cs
- AutoCompleteStringCollection.cs
- IERequestCache.cs
- WindowsPrincipal.cs
- streamingZipPartStream.cs
- GridItem.cs
- SourceInterpreter.cs
- SafeRightsManagementSessionHandle.cs
- ClientSideProviderDescription.cs
- PhysicalFontFamily.cs
- Aes.cs
- DirectoryInfo.cs
- GeometryDrawing.cs
- Version.cs
- WindowsHyperlink.cs
- WebPartAuthorizationEventArgs.cs
- Property.cs
- ComPlusThreadInitializer.cs
- MethodCallConverter.cs
- CodeTypeParameter.cs
- PreviewKeyDownEventArgs.cs
- StreamUpdate.cs
- DocumentReferenceCollection.cs
- ControlBuilder.cs
- TextViewSelectionProcessor.cs
- StylusPlugin.cs
- TCEAdapterGenerator.cs
- ViewKeyConstraint.cs
- ExpandSegment.cs
- HtmlInputText.cs
- TextProperties.cs
- CFStream.cs
- MiniConstructorInfo.cs
- HostedBindingBehavior.cs
- mda.cs
- WSSecurityOneDotOneReceiveSecurityHeader.cs
- CircleHotSpot.cs
- FormViewCommandEventArgs.cs
- SHA1.cs
- Rotation3DKeyFrameCollection.cs
- TextParaClient.cs
- graph.cs
- ExtensibleClassFactory.cs
- IssuanceLicense.cs
- WebPartHeaderCloseVerb.cs
- RegularExpressionValidator.cs
- FileLevelControlBuilderAttribute.cs
- QuaternionValueSerializer.cs
- SQLBytes.cs
- ChangeBlockUndoRecord.cs
- ComPlusAuthorization.cs
- RoamingStoreFile.cs
- MetaModel.cs
- ProcessProtocolHandler.cs
- TableTextElementCollectionInternal.cs
- StringSorter.cs
- SpeechSeg.cs
- ClientData.cs
- EditCommandColumn.cs
- DataGridViewRowPrePaintEventArgs.cs
- DesignerPainter.cs
- WebPartMenu.cs
- StandardOleMarshalObject.cs
- __Filters.cs
- ResponseBodyWriter.cs
- InputDevice.cs
- XmlSchemaExternal.cs
- ImageFormat.cs
- Method.cs
- DataGridViewColumnStateChangedEventArgs.cs
- ZipPackagePart.cs
- InfoCardRSAOAEPKeyExchangeFormatter.cs
- DataBoundLiteralControl.cs
- ZipIOLocalFileBlock.cs
- ServiceDesigner.xaml.cs
- EntityFrameworkVersions.cs
- ZipIOZip64EndOfCentralDirectoryBlock.cs
- TextServicesCompartment.cs
- MasterPage.cs
- OleDbPropertySetGuid.cs