IContextChannel Interface
TOC
Collapse the table of content
Expand the table of content

IContextChannel Interface

[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]

Defines the interface for the context control of a channel.

Namespace:  System.ServiceModel
Assembly:  System.ServiceModel (in System.ServiceModel.dll)

No code example is currently available or this language may not be supported.

The IContextChannel type exposes the following members.

  NameDescription
Public propertyAllowOutputBatchingGets or sets a value that instructs Windows Phone to store a set of messages before giving the messages to the transport.
Public propertyExtensionsGets a collection of extension objects for this extensible object. (Inherited from IExtensibleObject<T>.)
Public propertyInputSessionGets the input session for the channel.
Public propertyLocalAddressGets the local endpoint for the channel.
Public propertyOperationTimeoutGets or sets the time period within which an operation must complete or an exception is thrown.
Public propertyOutputSessionGets the output session associated with the channel, if any.
Public propertyRemoteAddressGets the remote address associated with the channel.
Public propertySessionIdReturns an identifier for the current session, if any.
Public propertyStateGets the current state of the communication-oriented object. (Inherited from ICommunicationObject.)
Top

  NameDescription
Public methodAbortCauses a communication object to transition immediately from its current state into the closed state. (Inherited from ICommunicationObject.)
Public methodBeginClose(AsyncCallback, Object)Begins an asynchronous operation to close a communication object. (Inherited from ICommunicationObject.)
Public methodBeginClose(TimeSpan, AsyncCallback, Object)Begins an asynchronous operation to close a communication object with a specified time-out. (Inherited from ICommunicationObject.)
Public methodBeginOpen(AsyncCallback, Object)Begins an asynchronous operation to open a communication object. (Inherited from ICommunicationObject.)
Public methodBeginOpen(TimeSpan, AsyncCallback, Object)Begins an asynchronous operation to open a communication object within a specified interval of time. (Inherited from ICommunicationObject.)
Public methodClose()Causes a communication object to transition from its current state into the closed state. (Inherited from ICommunicationObject.)
Public methodClose(TimeSpan)Causes a communication object to transition from its current state into the closed state. (Inherited from ICommunicationObject.)
Public methodEndCloseCompletes an asynchronous operation to close a communication object. (Inherited from ICommunicationObject.)
Public methodEndOpenCompletes an asynchronous operation to open a communication object. (Inherited from ICommunicationObject.)
Public methodGetProperty<T>Returns a typed object requested, if present, from the appropriate layer in the channel stack. (Inherited from IChannel.)
Public methodOpen()Causes a communication object to transition from the created state into the opened state. (Inherited from ICommunicationObject.)
Public methodOpen(TimeSpan)Causes a communication object to transition from the created state into the opened state within a specified interval of time. (Inherited from ICommunicationObject.)
Top

  NameDescription
Public eventClosedOccurs when the communication object completes its transition from the closing state into the closed state. (Inherited from ICommunicationObject.)
Public eventClosingOccurs when the communication object first enters the closing state. (Inherited from ICommunicationObject.)
Public eventFaultedOccurs when the communication object first enters the faulted state. (Inherited from ICommunicationObject.)
Public eventOpenedOccurs when the communication object completes its transition from the opening state into the opened state. (Inherited from ICommunicationObject.)
Public eventOpeningOccurs when the communication object first enters the opening state. (Inherited from ICommunicationObject.)
Top

The IContextChannel defines the controls for the context of a channel. This includes the SessionId, InputSession, OutputSession, and AllowOutputBatching for the channel, and the LocalAddress and RemoteAddress for the endpoints that are participating in the session.

Capabilities

If you use this API in your app, you must specify the following capabilities in the app manifest. Otherwise, your app might not work correctly or it might exit unexpectedly.

ID_CAP_NETWORKING

Windows Phone 8, Windows Phone OS 7.1

For more info, see App capabilities and hardware requirements for Windows Phone 8.

Windows Phone OS

Supported in: 8.1, 8.0, 7.1, 7.0

Windows Phone

Show:
© 2017 Microsoft