IExtension(T) Interface
TOC
Collapse the table of content
Expand the table of content

IExtension<T> Interface

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

Enables an object to extend another object through aggregation.

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

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

Type Parameters

T

The object that participates in the custom behavior.

The IExtension<T> type exposes the following members.

  NameDescription
Public methodAttachEnables an extension object to find out when it has been aggregated. Called when the extension is added to the IExtensibleObject<T>::Extensions property.
Public methodDetachEnables an object to find out when it is no longer aggregated. Called when an extension is removed from the IExtensibleObject<T>::Extensions property.
Top

Windows Phone allows you to extend System.ServiceModel::IExtensibleObject<T> objects (the System.ServiceModel::IContextChannel class) by adding a new state or behavior by using its extensible object pattern. The extensible object pattern is used in Windows Phone to either extend existing run-time classes with new functionality or to add new state features to an object.

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