SccBackgroundGet 函式SccBackgroundGet function
此函式會從原始檔控制每個指定的檔案,而不是使用者互動。This function retrieves from source control each of the specified files with no user interaction.
語法Syntax
SCCRTN SccBackgroundGet(
LPVOID pContext,
LONG nFiles,
LPCSTR* lpFileNames,
LONG dwFlags,
LONG dwBackgroundOperationID
);
參數Parameters
pContextpContext
在原始檔控制外掛程式內容指標。[in] The source control plug-in context pointer.
nFilesnFiles
在陣列中指定的檔案數目 lpFileNames
。[in] Number of files specified in the lpFileNames
array.
lpFileNameslpFileNames
[in,out]要抓取之檔案的名稱陣列。[in, out] Array of names of files to be retrieved.
注意
這些名稱必須是完整的本機檔案名。The names must be fully qualified local filenames.
dwFlagsdwFlags
在命令旗標 (SCC_GET_ALL
, SCC_GET_RECURSIVE
) 。[in] Command flags (SCC_GET_ALL
, SCC_GET_RECURSIVE
).
dwBackgroundOperationIDdwBackgroundOperationID
在與此作業相關聯的唯一值。[in] A unique value associated with this operation.
傳回值Return value
此函式的原始檔控制外掛程式實作為預期會傳回下列其中一個值:The source control plug-in implementation of this function is expected to return one of the following values:
值Value | 描述Description |
---|---|
SCC_OKSCC_OK | 作業順利完成。Operation completed successfully. |
SCC_E_BACKGROUNDGETINPROGRESSSCC_E_BACKGROUNDGETINPROGRESS | 背景抓取已經在進行中 (當原始檔控制外掛程式不支援) 的並行批次作業時,才應該傳回此功能。A background retrieval is already in progress (the source control plug-in should return this only if it does not support simultaneous batch operations). |
SCC_I_OPERATIONCANCELEDSCC_I_OPERATIONCANCELED | 作業已在完成前取消。Operation was canceled before being completed. |
備註Remarks
這個函式一律會在與載入原始檔控制外掛程式不同的執行緒上呼叫。This function is always called on a thread different from the one that loaded the source control plug-in. 在完成之前,不應傳回此函式。不過,您可以使用多個檔案清單多次呼叫它,而這兩者都是在同一時間進行。This function is not expected to return until it is done; however, it can be called multiple times with multiple lists of files, all at the same time.
使用 dwFlags
引數與 SccGet相同。The use of the dwFlags
argument is the same as the SccGet.