Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / clr / src / BCL / System / Runtime / Remoting / DispatchChannelSink.cs / 1 / DispatchChannelSink.cs
// ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== // File: DispatchChannelSink.cs using System; using System.Collections; using System.IO; using System.Runtime.Remoting; using System.Runtime.Remoting.Messaging; namespace System.Runtime.Remoting.Channels { internal class DispatchChannelSinkProvider : IServerChannelSinkProvider { internal DispatchChannelSinkProvider() { } // DispatchChannelSinkProvider public void GetChannelData(IChannelDataStore channelData) { } public IServerChannelSink CreateSink(IChannelReceiver channel) { return new DispatchChannelSink(); } public IServerChannelSinkProvider Next { get { return null; } set { throw new NotSupportedException(); } } } // class DispatchChannelSinkProvider internal class DispatchChannelSink : IServerChannelSink { internal DispatchChannelSink() { } // DispatchChannelSink public ServerProcessing ProcessMessage(IServerChannelSinkStack sinkStack, IMessage requestMsg, ITransportHeaders requestHeaders, Stream requestStream, out IMessage responseMsg, out ITransportHeaders responseHeaders, out Stream responseStream) { if (requestMsg == null) { throw new ArgumentNullException( "requestMsg", Environment.GetResourceString("Remoting_Channel_DispatchSinkMessageMissing")); } // check arguments if (requestStream != null) { throw new RemotingException( Environment.GetResourceString("Remoting_Channel_DispatchSinkWantsNullRequestStream")); } responseHeaders = null; responseStream = null; return ChannelServices.DispatchMessage(sinkStack, requestMsg, out responseMsg); } // ProcessMessage public void AsyncProcessResponse(IServerResponseChannelSinkStack sinkStack, Object state, IMessage msg, ITransportHeaders headers, Stream stream) { // We never push ourselves to the sink stack, so this won't be called. throw new NotSupportedException(); } // AsyncProcessResponse public Stream GetResponseStream(IServerResponseChannelSinkStack sinkStack, Object state, IMessage msg, ITransportHeaders headers) { // We never push ourselves to the sink stack, so this won't be called. throw new NotSupportedException(); } // GetResponseStream public IServerChannelSink NextChannelSink { get { return null; } } public IDictionary Properties { get { return null; } } } // class DispatchChannelSink } // namespace System.Runtime.Remoting.Channels // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== // File: DispatchChannelSink.cs using System; using System.Collections; using System.IO; using System.Runtime.Remoting; using System.Runtime.Remoting.Messaging; namespace System.Runtime.Remoting.Channels { internal class DispatchChannelSinkProvider : IServerChannelSinkProvider { internal DispatchChannelSinkProvider() { } // DispatchChannelSinkProvider public void GetChannelData(IChannelDataStore channelData) { } public IServerChannelSink CreateSink(IChannelReceiver channel) { return new DispatchChannelSink(); } public IServerChannelSinkProvider Next { get { return null; } set { throw new NotSupportedException(); } } } // class DispatchChannelSinkProvider internal class DispatchChannelSink : IServerChannelSink { internal DispatchChannelSink() { } // DispatchChannelSink public ServerProcessing ProcessMessage(IServerChannelSinkStack sinkStack, IMessage requestMsg, ITransportHeaders requestHeaders, Stream requestStream, out IMessage responseMsg, out ITransportHeaders responseHeaders, out Stream responseStream) { if (requestMsg == null) { throw new ArgumentNullException( "requestMsg", Environment.GetResourceString("Remoting_Channel_DispatchSinkMessageMissing")); } // check arguments if (requestStream != null) { throw new RemotingException( Environment.GetResourceString("Remoting_Channel_DispatchSinkWantsNullRequestStream")); } responseHeaders = null; responseStream = null; return ChannelServices.DispatchMessage(sinkStack, requestMsg, out responseMsg); } // ProcessMessage public void AsyncProcessResponse(IServerResponseChannelSinkStack sinkStack, Object state, IMessage msg, ITransportHeaders headers, Stream stream) { // We never push ourselves to the sink stack, so this won't be called. throw new NotSupportedException(); } // AsyncProcessResponse public Stream GetResponseStream(IServerResponseChannelSinkStack sinkStack, Object state, IMessage msg, ITransportHeaders headers) { // We never push ourselves to the sink stack, so this won't be called. throw new NotSupportedException(); } // GetResponseStream public IServerChannelSink NextChannelSink { get { return null; } } public IDictionary Properties { get { return null; } } } // class DispatchChannelSink } // namespace System.Runtime.Remoting.Channels // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- RangeContentEnumerator.cs
- UpdateRecord.cs
- WebPartMenuStyle.cs
- FormViewPageEventArgs.cs
- M3DUtil.cs
- RawKeyboardInputReport.cs
- RuleSetCollection.cs
- WindowsEditBoxRange.cs
- GrammarBuilder.cs
- ProxyHwnd.cs
- WinEventHandler.cs
- Comparer.cs
- Root.cs
- ClientFormsIdentity.cs
- GPPOINT.cs
- IndexedString.cs
- RoutedEventValueSerializer.cs
- XPathNodeIterator.cs
- Aggregates.cs
- DBConnection.cs
- XmlQueryTypeFactory.cs
- XmlILConstructAnalyzer.cs
- CodeTypeMember.cs
- DoubleLinkList.cs
- PathStreamGeometryContext.cs
- DesignerListAdapter.cs
- DefaultAsyncDataDispatcher.cs
- TiffBitmapDecoder.cs
- XmlTextAttribute.cs
- FileUtil.cs
- SessionParameter.cs
- TextComposition.cs
- EnumValAlphaComparer.cs
- AccessText.cs
- SafeTimerHandle.cs
- WebPartConnectionsCloseVerb.cs
- ListViewGroupConverter.cs
- XmlKeywords.cs
- StyleSheet.cs
- FlowDocument.cs
- WebServiceMethodData.cs
- QueryHandler.cs
- DefaultObjectSerializer.cs
- AnnotationAdorner.cs
- ResourcesBuildProvider.cs
- DataTableExtensions.cs
- XhtmlTextWriter.cs
- Script.cs
- SchemaElementDecl.cs
- HWStack.cs
- ForeignKeyConstraint.cs
- PaperSource.cs
- CookieProtection.cs
- FormViewDeletedEventArgs.cs
- BitmapSizeOptions.cs
- Guid.cs
- ComponentTray.cs
- LinkedResourceCollection.cs
- Enum.cs
- NamespaceDecl.cs
- ProfileSection.cs
- ListViewPagedDataSource.cs
- CodeAttachEventStatement.cs
- XmlDocumentSchema.cs
- Domain.cs
- ImageField.cs
- XmlArrayItemAttribute.cs
- UserControlAutomationPeer.cs
- SchemaNotation.cs
- XmlQualifiedName.cs
- SchemaMapping.cs
- RecordConverter.cs
- TableItemStyle.cs
- XslVisitor.cs
- LinearKeyFrames.cs
- XsdBuildProvider.cs
- DispatcherExceptionFilterEventArgs.cs
- GeneralTransform3DTo2DTo3D.cs
- ConnectionPointCookie.cs
- InternalsVisibleToAttribute.cs
- AxisAngleRotation3D.cs
- SmtpClient.cs
- LineServicesCallbacks.cs
- TextTreeExtractElementUndoUnit.cs
- Currency.cs
- CodeIterationStatement.cs
- ListViewContainer.cs
- Frame.cs
- ServiceHttpHandlerFactory.cs
- XmlEntityReference.cs
- ClientUtils.cs
- _IPv6Address.cs
- VisualState.cs
- SapiInterop.cs
- DotExpr.cs
- WebPartDisplayModeCancelEventArgs.cs
- Quack.cs
- SystemIPGlobalProperties.cs
- SymDocumentType.cs
- XmlQualifiedName.cs