1.詞匯
- delegate type 委托類型
- delegate instance 委托實(shí)例
- invoke 調(diào)用
2.例句
-
We’ll start our tour of delegates with the four absolute basics, without which none of the rest would make sense.
在開始我們的委托之旅之前,我們需要先了解4個基本條件,它們?nèi)币徊豢伞?/strong>
-
In order for a delegate to do anything, four things need to happen:
(1)The delegate type needs to be declared.
(2) The code to be executed must be contained in a method.
(3) A delegate instance must be created.
(4) The delegate instance must be invoked.要實(shí)現(xiàn)委托,需要做4件事:
(1)委托類型需要先聲明;
(2)要執(zhí)行的代碼需要包含在一個方法內(nèi);
(3)需要創(chuàng)建委托實(shí)例;
(4)委托實(shí)例需要被調(diào)用。