此方法由生成引擎调用以开始执行任务。This method is called by the build engine to begin task execution. 任务使用返回值来指示是否成功。A task uses the return value to indicate whether it was successful. 如果任务在此方法中引发异常，则引擎将自动假定任务已失败。If a task throws an exception out of this method, the engine will automatically assume that the task has failed.
public: bool Execute();
public bool Execute ();
abstract member Execute : unit -> bool
Public Function Execute () As Boolean
如果成功，则为 truetrue, if successful
此方法由生成引擎调用以执行任务。This method is called by the build engine to execute a task. 此方法终止后，任务应指示执行是否成功。Upon termination of this method, a task should indicate if the execution was successful. 如果任务从此方法引发异常，则引擎将假定该任务失败。If a task throws an exception from this method, the engine assumes that the task has failed.