Export (0) Print
Expand All

IContract Interface

Represents the base interface for all contracts that are used for communication between components that are updated independently.

Namespace:  System.AddIn.Contract
Assembly:  System.AddIn.Contract (in System.AddIn.Contract.dll)

public interface IContract

The IContract type exposes the following members.

  NameDescription
Public methodAcquireLifetimeTokenSpecifies that the contract is accessible to a client until the client revokes the contract.
Public methodGetRemoteHashCodeReturns a hash code for the IContract.
Public methodQueryContractReturns a contract that is implemented by this contract.
Public methodRemoteEqualsIndicates whether the specified contract is equal to this IContract.
Public methodRemoteToStringReturns a string representation of the current IContract.
Public methodRevokeLifetimeTokenSpecifies that the contract is no longer accessible to a client.
Top

The IContract interface defines a contract that independently updated components, such as an application and an add-in, can use to communicate. Components can use IContract to communicate across process or application domain boundaries, or to communicate with other components in the same process or application domain. IContract serves a similar purpose for components created using the .NET Framework as the IUnknown interface serves for components created using COM. To determine whether an object implements a particular contract, use the QueryContract method.

.NET Framework

Supported in: 4.6, 4.5, 4, 3.5

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Show:
© 2014 Microsoft