InstanceContext.Extensions Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets the extension collection, if any, associated with the service instance.
public:
property System::ServiceModel::IExtensionCollection<System::ServiceModel::InstanceContext ^> ^ Extensions { System::ServiceModel::IExtensionCollection<System::ServiceModel::InstanceContext ^> ^ get(); };
public System.ServiceModel.IExtensionCollection<System.ServiceModel.InstanceContext> Extensions { get; }
member this.Extensions : System.ServiceModel.IExtensionCollection<System.ServiceModel.InstanceContext>
Public ReadOnly Property Extensions As IExtensionCollection(Of InstanceContext)
Property Value
The IExtensionCollection<T> of type InstanceContext that contains the instance contexts for the extensions of the service instance.
Implements
Exceptions
The service instance associated with this context is closed, but was not aborted.
The service instance associated with this context is in a faulted state.
Examples
The following code shows how to access the Extensions property:
Uri baseAddress = new Uri("http://localhost:8000/ServiceModelSamples/service");
CalculatorService service = new CalculatorService();
ServiceHost serviceHost = new ServiceHost(service, baseAddress);
InstanceContext instanceContext = new InstanceContext(serviceHost, service);
IExtensionCollection<InstanceContext> extensions = instanceContext.Extensions;
Applies to
GitHub에서 Microsoft와 공동 작업
이 콘텐츠의 원본은 GitHub에서 찾을 수 있으며, 여기서 문제와 끌어오기 요청을 만들고 검토할 수도 있습니다. 자세한 내용은 참여자 가이드를 참조하세요.
.NET