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
- EventMappingSettingsCollection.cs
- Int32AnimationBase.cs
- ButtonBaseAdapter.cs
- ClonableStack.cs
- ColumnCollection.cs
- MessageLoggingElement.cs
- Hex.cs
- SourceLocationProvider.cs
- GlyphingCache.cs
- Track.cs
- PerformanceCounter.cs
- SmiMetaData.cs
- PasswordRecovery.cs
- ToolStripDesignerUtils.cs
- XmlParserContext.cs
- NameSpaceExtractor.cs
- Propagator.cs
- VersionedStreamOwner.cs
- HttpContextBase.cs
- BezierSegment.cs
- DynamicILGenerator.cs
- Debugger.cs
- ConcurrentQueue.cs
- DataServiceHost.cs
- RegexCharClass.cs
- DoubleAnimationUsingPath.cs
- WebServiceEnumData.cs
- TypeConverterHelper.cs
- DriveInfo.cs
- BamlLocalizabilityResolver.cs
- TemplateModeChangedEventArgs.cs
- LicFileLicenseProvider.cs
- TextRunTypographyProperties.cs
- HttpHandlerAction.cs
- AnimatedTypeHelpers.cs
- Switch.cs
- ByteRangeDownloader.cs
- VisualTreeHelper.cs
- TimeSpanOrInfiniteValidator.cs
- TaskFileService.cs
- WebSysDefaultValueAttribute.cs
- RegexGroup.cs
- XpsSerializerWriter.cs
- SymbolMethod.cs
- AssociationTypeEmitter.cs
- IntegerFacetDescriptionElement.cs
- ExtensionSurface.cs
- XmlDataImplementation.cs
- Win32Exception.cs
- FillRuleValidation.cs
- path.cs
- DynamicUpdateCommand.cs
- BinaryFormatterWriter.cs
- PathSegment.cs
- OdbcError.cs
- EndOfStreamException.cs
- LinkGrep.cs
- EncodingInfo.cs
- SystemWebExtensionsSectionGroup.cs
- DocumentGridContextMenu.cs
- EntitySet.cs
- ModifyActivitiesPropertyDescriptor.cs
- PageClientProxyGenerator.cs
- StructuredTypeEmitter.cs
- DBConcurrencyException.cs
- TransportChannelListener.cs
- FixedPageAutomationPeer.cs
- Misc.cs
- QueryStringHandler.cs
- QilExpression.cs
- StringValueSerializer.cs
- SimpleWebHandlerParser.cs
- Journaling.cs
- UnhandledExceptionEventArgs.cs
- Visitors.cs
- XmlDocumentSurrogate.cs
- BoundingRectTracker.cs
- BitmapDecoder.cs
- WebRequestModuleElementCollection.cs
- CommentAction.cs
- ScrollProperties.cs
- RegexReplacement.cs
- SqlFormatter.cs
- XmlNamespaceMapping.cs
- hresults.cs
- BaseDataListDesigner.cs
- EpmSourcePathSegment.cs
- SrgsElementList.cs
- TableLayoutPanelDesigner.cs
- DPCustomTypeDescriptor.cs
- WindowsTab.cs
- hebrewshape.cs
- RepeaterItem.cs
- DescendentsWalker.cs
- LastQueryOperator.cs
- CodeTypeDelegate.cs
- EdmValidator.cs
- FontConverter.cs
- HtmlProps.cs
- PrtCap_Builder.cs