Package.StageContentGroupsAsync 方法

定義

多載

StageContentGroupsAsync(IIterable<String>)

將套件放在指定的內容群組中,並放入暫存佇列中。

StageContentGroupsAsync(IIterable<String>, Boolean)

將套件放入指定的內容群組中,並放入暫存佇列中;選擇性地將內容群組放在佇列的前端。

StageContentGroupsAsync(IIterable<String>)

將套件放在指定的內容群組中,並放入暫存佇列中。

public:
 virtual IAsyncOperation<IVector<PackageContentGroup ^> ^> ^ StageContentGroupsAsync(IIterable<Platform::String ^> ^ names) = StageContentGroupsAsync;
/// [Windows.Foundation.Metadata.Overload("StageContentGroupsAsync")]
/// [Windows.Foundation.Metadata.RemoteAsync]
IAsyncOperation<IVector<PackageContentGroup>> StageContentGroupsAsync(IIterable<winrt::hstring> const& names);
[Windows.Foundation.Metadata.Overload("StageContentGroupsAsync")]
[Windows.Foundation.Metadata.RemoteAsync]
public IAsyncOperation<IList<PackageContentGroup>> StageContentGroupsAsync(IEnumerable<string> names);
function stageContentGroupsAsync(names)
Public Function StageContentGroupsAsync (names As IEnumerable(Of String)) As IAsyncOperation(Of IList(Of PackageContentGroup))

參數

names

IIterable<String>

IEnumerable<String>

IIterable<Platform::String>

IIterable<winrt::hstring>

要暫存的內容群組名稱。

傳回

name參數所指定之每個內容群組的PackageContentGroup物件清單。

屬性

Windows 需求

裝置系列
Windows 10 Creators Update (已於 10.0.15063.0 引進)
API contract
Windows.Foundation.UniversalApiContract (已於 v4.0 引進)

備註

此函式會在暫存所有要求的群組時完成。 如果該位置中的具名群組不存在,傳回的清單可能會包含 null 元素。 使用 PackageCatalog.PackageContentGroupStaging 來觀察暫存進度。

請務必檢查 PackageContentGroup.State ,以確認群組已成功暫存。 在未完全暫存的群組中參考檔案可能會導致非預期的應用程式行為。 如果暫存作業無法完成,內容群組會返回 PackageContentGroupState.NotStaged 狀態。

適用於

StageContentGroupsAsync(IIterable<String>, Boolean)

將套件放入指定的內容群組中,並放入暫存佇列中;選擇性地將內容群組放在佇列的前端。

public:
 virtual IAsyncOperation<IVector<PackageContentGroup ^> ^> ^ StageContentGroupsAsync(IIterable<Platform::String ^> ^ names, bool moveToHeadOfQueue) = StageContentGroupsAsync;
/// [Windows.Foundation.Metadata.Overload("StageContentGroupsWithPriorityAsync")]
/// [Windows.Foundation.Metadata.RemoteAsync]
IAsyncOperation<IVector<PackageContentGroup>> StageContentGroupsAsync(IIterable<winrt::hstring> const& names, bool const& moveToHeadOfQueue);
[Windows.Foundation.Metadata.Overload("StageContentGroupsWithPriorityAsync")]
[Windows.Foundation.Metadata.RemoteAsync]
public IAsyncOperation<IList<PackageContentGroup>> StageContentGroupsAsync(IEnumerable<string> names, bool moveToHeadOfQueue);
function stageContentGroupsAsync(names, moveToHeadOfQueue)
Public Function StageContentGroupsAsync (names As IEnumerable(Of String), moveToHeadOfQueue As Boolean) As IAsyncOperation(Of IList(Of PackageContentGroup))

參數

names

IIterable<String>

IEnumerable<String>

IIterable<Platform::String>

IIterable<winrt::hstring>

要暫存的內容群組名稱。

moveToHeadOfQueue
Boolean

bool

True 是 表示 將內容群組移至暫存佇列的前端; 否則為 false

傳回

name參數所指定之每個內容群組的PackageContentGroup物件清單。

屬性

Windows 需求

裝置系列
Windows 10 Creators Update (已於 10.0.15063.0 引進)
API contract
Windows.Foundation.UniversalApiContract (已於 v4.0 引進)

備註

此函式會在暫存所有要求的群組時完成。 如果該位置中的具名群組不存在,傳回的清單可能會包含 null 元素。 使用 PackageCatalog.PackageContentGroupStaging 來觀察暫存進度。

請務必檢查 PackageContentGroup.State ,以確認群組已成功暫存。 在未完全暫存的群組中參考檔案可能會導致非預期的應用程式行為。 如果暫存作業無法完成,內容群組會返回 PackageContentGroupState.NotStaged 狀態。

適用於