ContractBase 類別

定義

提供成員的預設實作 IContract

public ref class ContractBase : MarshalByRefObject, System::AddIn::Contract::IContract, System::Runtime::Remoting::Lifetime::ISponsor
public class ContractBase : MarshalByRefObject, System.AddIn.Contract.IContract, System.Runtime.Remoting.Lifetime.ISponsor
type ContractBase = class
    inherit MarshalByRefObject
    interface IContract
    interface ISponsor
Public Class ContractBase
Inherits MarshalByRefObject
Implements IContract, ISponsor
繼承
ContractBase
實作

備註

合約定義了主機與外掛所使用的類型與方法。 所有契約必須由 衍生出 IContract。 此類別提供成員的 IContract 預設實作。

建構函式

名稱 Description
ContractBase()

初始化 ContractBase 類別的新執行個體。

方法

名稱 Description
AcquireLifetimeToken()

獲得終身代幣。

CreateObjRef(Type)

建立物件,其中包含產生用來與遠端物件通訊之 Proxy 所需的所有相關信息。

(繼承來源 MarshalByRefObject)
Equals(Object)

判斷指定的 物件是否等於目前的物件。

(繼承來源 Object)
GetHashCode()

做為預設雜湊函式。

(繼承來源 Object)
GetLifetimeService()
已淘汰.

取得目前控制此實例生命週期政策的終身服務物件。

(繼承來源 MarshalByRefObject)
GetRemoteHashCode()

取得目前 ContractBase 物件的雜湊碼。

GetType()

取得目前實例的 Type

(繼承來源 Object)
InitializeLifetimeService()
已淘汰.

取得一個終身服務物件以控制此實例的終身政策。

(繼承來源 MarshalByRefObject)
MemberwiseClone()

建立目前 Object的淺層複本。

(繼承來源 Object)
MemberwiseClone(Boolean)

建立一個 MarshalByRefObject 目前物件的淺層複製品。

(繼承來源 MarshalByRefObject)
OnFinalRevoke()

當在附加介面卡中覆寫時,會釋放該介面卡所保留的原生資源。

QueryContract(String)

它會反映在合約的實例上,若當前物件實作該合約,則回傳 this 指標。

RemoteEquals(IContract)

比較一個物件與遠端物件以達到相等。

RemoteToString()

會得到一個字串來識別遠端物件。

Renewal(ILease)

請求贊助客戶續約指定物件的租約。

RevokeLifetimeToken(Int32)

將指定的代幣從未完成的終身代幣列表中移除。

ToString()

傳回表示目前 物件的字串。

(繼承來源 Object)

適用於